108{
109
110
112
114
119 {
122 }
123 else
124 {
126 proj_A = 1;
127 }
128
129
130
131 G4int targ_Z = target.GetZ_asInt();
132 G4int targ_A = target.GetA_asInt();
134
135
136
137
138
140
141
142
143
144
145
147
148
155 }
156
157
158
159
160
161 G4double bmax_0 = std::sqrt( xs_0 / pi );
162
163
164
165
167
168 std::vector< G4QMDNucleus* > nucleuses;
171
174
177 G4double e1 = std::sqrt( p1*p1 + m1*m1 );
180
182
183 G4double beta_nncm = ( - boostLABtoCM.
beta() + boostLABtoNN.beta() ) / ( 1 - boostLABtoCM.
beta() * boostLABtoNN.beta() ) ;
184
185
186
187
190
191 boostToReac = boostLABtoNN;
192 boostBackToLAB = -boostLABtoNN;
193
194 delete proj_dp;
195
197 G4int icounter_max = 1024;
198 while ( elastic )
199 {
200 icounter++;
201 if ( icounter > icounter_max ) {
202 G4cout <<
"Loop-counter exceeded the threshold value at " << __LINE__ <<
"th line of " << __FILE__ <<
"." <<
G4endl;
203 break;
204 }
205
206
207
208 G4double bmax = envelopF*(bmax_0/fermi);
210
211
212
213
214
215
216
217 G4double plab = projectile.GetTotalMomentum()/GeV;
219
220 calcOffSetOfCollision( b , proj_pd , targ_pd , plab , elab , bmax , boostCMtoNN );
221
222
224
226 if ( projectile.GetDefinition()->GetParticleType() == "nucleus"
227 || projectile.GetDefinition()->GetParticleName() == "proton"
228 || projectile.GetDefinition()->GetParticleName() == "neutron" )
229 {
230
233
235
236
237
240 proj->CalEnergyAndAngularMomentumInCM();
241
242 }
243
244
245
246
247
248 G4int iz = int ( target.GetZ_asInt() );
249 G4int ia = int ( target.GetA_asInt() );
250
252
256
257
258
259
260
261
263 {
264
267
270 , p0.
z() * coulomb_collision_gamma_targ + coulomb_collision_pz_targ );
271
274 , r0.
z() / coulomb_collision_gamma_targ + coulomb_collision_rz_targ );
275
278
279 }
280
283
284
285
286
287 if ( proj_A != 1 )
288 {
289
290
291
292 for (
G4int i = 0 ; i < proj->GetTotalNumberOfParticipant() ; i++ )
293 {
294
297
300 , p0.
z() * coulomb_collision_gamma_proj + coulomb_collision_pz_proj );
301
304 , r0.
z() / coulomb_collision_gamma_proj + coulomb_collision_rz_proj );
305
308 }
309
310 }
311 else
312 {
313
314
315
316
317
319 {
320
322
325
328 , p0.
z() * coulomb_collision_gamma_proj + coulomb_collision_pz_proj );
329
332 , r0.
z() / coulomb_collision_gamma_proj + coulomb_collision_rz_proj );
333
335
337 }
338
339 }
340
341
342 delete targ;
343 delete proj;
344
347
348
349
350
351 for (
G4int i = 0 ; i < maxTime ; i++ )
352 {
353
355
357
358 if ( i / 10 * 10 == i )
359 {
360
361
362 }
363
364 }
365
366
367
368
369
371
372
373
375
382
383 if ( numberOfSecondary == 2 )
384 {
385
386 G4bool elasticLike_system =
false;
387 if ( nucleuses.size() == 2 )
388 {
389
390 sec_a_Z = nucleuses[0]->GetAtomicNumber();
391 sec_a_A = nucleuses[0]->GetMassNumber();
392 sec_b_Z = nucleuses[1]->GetAtomicNumber();
393 sec_b_A = nucleuses[1]->GetMassNumber();
394
395 if ( ( sec_a_Z == proj_Z && sec_a_A == proj_A && sec_b_Z == targ_Z && sec_b_A == targ_A )
396 || ( sec_a_Z == targ_Z && sec_a_A == targ_A && sec_b_Z == proj_Z && sec_b_A == proj_A ) )
397 {
398 elasticLike_system = true;
399 }
400
401 }
402 else if ( nucleuses.size() == 1 )
403 {
404
405 sec_a_Z = nucleuses[0]->GetAtomicNumber();
406 sec_a_A = nucleuses[0]->GetMassNumber();
408
409 if ( ( sec_a_Z == proj_Z && sec_a_A == proj_A && sec_b_pd == targ_pd )
410 || ( sec_a_Z == targ_Z && sec_a_A == targ_A && sec_b_pd == proj_pd ) )
411 {
412 elasticLike_system = true;
413 }
414
415 }
416 else
417 {
418
421
422 if ( ( sec_a_pd == proj_pd && sec_b_pd == targ_pd )
423 || ( sec_a_pd == targ_pd && sec_b_pd == proj_pd ) )
424 {
425 elasticLike_system = true;
426 }
427
428 }
429
430 if ( elasticLike_system == true )
431 {
432
433 G4bool elasticLike_energy =
true;
434
435 for (
G4int i = 0 ; i < int ( nucleuses.size() ) ; i++ )
436 {
437
438
440
441
442
443 if ( nucleuses[i]->GetExcitationEnergy()*GeV > 1.0*MeV ) elasticLike_energy = false;
444
445 }
446
447
448 G4bool withCollision =
true;
450
451
452
453
454
455
456
457
458
459 if ( frag == true )
460 if ( elasticLike_energy ==
false )
elastic =
false;
461
462 if ( elasticLike_energy ==
false && withCollision ==
true )
elastic =
false;
463
464 }
465
466 }
467 else
468 {
469
470
472
473 }
474
475
476
477
478
479 if ( elastic == true )
480 {
481
482 for ( std::vector< G4QMDNucleus* >::iterator
483 it = nucleuses.begin() ; it != nucleuses.end() ; it++ )
484 {
485 delete *it;
486 }
487 nucleuses.clear();
488 }
489
490 }
491
492
493
494
495 for ( std::vector< G4QMDNucleus* >::iterator it
496 = nucleuses.begin() ; it != nucleuses.end() ; it++ )
497 {
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
516
517 if ( (*it)->GetAtomicNumber() == 0
518 || (*it)->GetAtomicNumber() == (*it)->GetMassNumber() )
519 {
520
521 for (
G4int i = 0 ; i < (*it)->GetTotalNumberOfParticipant() ; i++ )
522 {
523 G4QMDParticipant* aP =
new G4QMDParticipant( ( (*it)->GetParticipant( i ) )->GetDefinition() , ( (*it)->GetParticipant( i ) )->GetMomentum() , ( (*it)->GetParticipant( i ) )->GetPosition() );
525 }
526 continue;
527 }
528
530 G4LorentzVector nucleus_p4CM ( (*it)->Get4Momentum().vect() , nucleus_e );
531
532
533
534 G4int ia = (*it)->GetMassNumber();
535 G4int iz = (*it)->GetAtomicNumber();
536
538
540
542 rv = excitationHandler->
BreakItUp( *aFragment );
544 for ( G4ReactionProductVector::iterator itt
545 = rv->begin() ; itt != rv->end() ; itt++ )
546 {
547
548 notBreak = false;
549
551
552 G4LorentzVector p4 ( (*itt)->GetMomentum()/GeV , (*itt)->GetTotalEnergy()/GeV );
555
556
557
558
560 {
561
564 }
565 else
566 {
567
569 randomized_direction = randomized_direction.unit();
573
577
579
583
588 }
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617 }
618 if ( notBreak == true )
619 {
620
622
627
628 }
629
630 for ( G4ReactionProductVector::iterator itt
631 = rv->begin() ; itt != rv->end() ; itt++ )
632 {
633 delete *itt;
634 }
635 delete rv;
636
637 delete aFragment;
638
639 }
640
641
642
644 {
645
646
652
653
654
655
656
657
658
659
660
661 }
662
663 for ( std::vector< G4QMDNucleus* >::iterator it
664 = nucleuses.begin() ; it != nucleuses.end() ; it++ )
665 {
666 delete *it;
667 }
668 nucleuses.clear();
669
671 delete system;
672
674
676 {
677
678
679
681 }
682
684
685}
std::vector< G4ReactionProduct * > G4ReactionProductVector
CLHEP::Hep3Vector G4ThreeVector
G4GLOB_DLL std::ostream G4cout
G4double GetElementCrossSection(const G4DynamicParticle *, G4int Z, const G4Material *mat) final
G4double GetElementCrossSection(const G4DynamicParticle *, G4int Z, const G4Material *mat) final
G4ParticleDefinition * GetDefinition() const
G4LorentzVector Get4Momentum() const
G4ThreeVector GetMomentum() const
G4ReactionProductVector * BreakItUp(const G4Fragment &theInitialState)
void SetStatusChange(G4HadFinalStateStatus aS)
void AddSecondary(G4DynamicParticle *aP, G4int mod=-1)
std::size_t GetNumberOfSecondaries() const
G4HadSecondary * GetSecondary(size_t i)
void SetCreatorModelID(G4int id)
G4HadFinalState theParticleChange
G4ParticleDefinition * GetIon(G4int Z, G4int A, G4int lvl=0)
static G4IonTable * GetIonTable()
G4double GetIonMass(G4int Z, G4int A, G4int nL=0, G4int lvl=0) const
G4int GetAtomicNumber() const
const G4String & GetParticleType() const
G4double GetPDGMass() const
G4int GetAtomicMass() const
G4double GetPDGCharge() const
static G4Pow * GetInstance()
G4double powN(G4double x, G4int n) const
void SetMeanField(G4QMDMeanField *meanfield)
void CalKinematicsOfBinaryCollisions(G4double)
G4double GetTotalPotential()
void SetNucleus(G4QMDNucleus *aSystem)
void DoPropagation(G4double)
std::vector< G4QMDNucleus * > DoClusterJudgment()
void SetSystem(G4QMDSystem *aSystem)
void SetTotalPotential(G4double x)
void CalEnergyAndAngularMomentumInCM()
G4ThreeVector GetPosition()
const G4ParticleDefinition * GetDefinition()
G4LorentzVector Get4Momentum()
G4ThreeVector GetMomentum()
G4QMDParticipant * GetParticipant(G4int i)
G4int GetTotalNumberOfParticipant()
void SetParticipant(G4QMDParticipant *particle)
virtual G4double GetElementCrossSection(const G4DynamicParticle *, G4int Z, const G4Material *mat=nullptr)
HepLorentzVector boostOf(const HepLorentzVector &vec, const Hep3Vector &betaVector)
G4double elastic(Particle const *const p1, Particle const *const p2)