Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4FermiFragmentsPool Class Reference

#include <G4FermiFragmentsPool.hh>

Public Member Functions

 ~G4FermiFragmentsPool ()
 
const std::vector< G4FermiConfiguration * > * GetConfigurationList (G4int Z, G4int A, G4double mass)
 
const G4VFermiFragmentGetFragment (G4int Z, G4int A)
 
G4int GetMaxZ () const
 
G4int GetMaxA () const
 

Static Public Member Functions

static G4FermiFragmentsPoolInstance ()
 

Detailed Description

Definition at line 44 of file G4FermiFragmentsPool.hh.

Constructor & Destructor Documentation

◆ ~G4FermiFragmentsPool()

G4FermiFragmentsPool::~G4FermiFragmentsPool ( )

Definition at line 74 of file G4FermiFragmentsPool.cc.

75{
76 for(size_t i=0; i<17; ++i) {
77 size_t nn = list1[i].size();
78 if(0 < nn) { for(size_t j=0; j<nn; ++j) { delete (list1[i])[j]; }}
79 nn = list2[i].size();
80 if(0 < nn) { for(size_t j=0; j<nn; ++j) { delete (list2[i])[j]; }}
81 nn = list3[i].size();
82 if(0 < nn) { for(size_t j=0; j<nn; ++j) { delete (list3[i])[j]; }}
83 nn = list4[i].size();
84 if(0 < nn) { for(size_t j=0; j<nn; ++j) { delete (list4[i])[j]; }}
85 }
86 size_t nn = listextra.size();
87 if(0 < nn) { for(size_t j=0; j<nn; ++j) { delete listextra[j]; }}
88 nn = fragment_pool.size();
89 if(0 < nn) { for(size_t j=0; j<nn; ++j) { delete fragment_pool[j]; }}
90}

Member Function Documentation

◆ GetConfigurationList()

const std::vector< G4FermiConfiguration * > * G4FermiFragmentsPool::GetConfigurationList ( G4int  Z,
G4int  A,
G4double  mass 
)

Definition at line 450 of file G4FermiFragmentsPool.cc.

451{
452 //JMQ 040511 for printing the total number of configurations for a given A
453 G4int nconf=0;
454
455 std::vector<G4FermiConfiguration*>* v = new std::vector<G4FermiConfiguration*>;
456 if(Z >= maxZ || A >= maxA) { return v; }
457
458 //G4cout << "G4FermiFragmentsPool::GetConfigurationList:"
459 // << " Z= " << Z << " A= " << A << " Mass(GeV)= " << mass/GeV<< G4endl;
460
461 // look into pair list
462 size_t nz = list2[A].size();
463 if(0 < nz) {
464 for(size_t j=0; j<nz; ++j) {
465 G4FermiConfiguration* conf = (list2[A])[j];
466 if(Z == conf->GetZ() && mass >= conf->GetMass()) {
467 v->push_back(conf);
468 ++nconf;
469 }
470 //if(Z == conf->GetZ()) {
471 //G4cout << "Pair dM(MeV)= " << mass - conf->GetMass() << G4endl; }
472 }
473 }
474 // look into triple list
475 nz = list3[A].size();
476 if(0 < nz) {
477 for(size_t j=0; j<nz; ++j) {
478 G4FermiConfiguration* conf = (list3[A])[j];
479 if(Z == conf->GetZ() && mass >= conf->GetMass()) {
480 v->push_back(conf);
481 ++nconf;
482 }
483 //if(Z == conf->GetZ()) {
484 //G4cout << "Triple dM(MeV)= " << mass - conf->GetMass() << G4endl; }
485 }
486 }
487 // look into quartet list
488 nz = list4[A].size();
489 if(0 < nz) {
490 for(size_t j=0; j<nz; ++j) {
491 G4FermiConfiguration* conf = (list4[A])[j];
492 if(Z == conf->GetZ() && mass >= conf->GetMass()) {
493 v->push_back(conf);
494 ++nconf;
495 }
496 //if(Z == conf->GetZ()) {
497 // G4cout << "Quartet dM(MeV)= " << mass - conf->GetMass() << G4endl; }
498 }
499 }
500 // return if vector not empty
501 if(0 < v->size()) {
502 if(verbose > 0) {
504 G4cout<<"Total number of configurations = "<<nconf<<" for A= "
505 <<A<<" Z= "<<Z<<" E*= "<< ExEn<<" MeV"<<G4endl;
506 size_t size_vector_conf = v->size();
507 for(size_t jc=0; jc<size_vector_conf; ++jc) {
508 std::vector<const G4VFermiFragment*> v_frag = (*v)[jc]->GetFragmentList();
509 size_t size_vector_fragments = v_frag.size();
510 G4cout<<size_vector_fragments<<"-body configuration "<<jc+1<<": ";
511 for(size_t jf=0;jf<size_vector_fragments;++jf){
512 G4int af= v_frag[jf]->GetA();
513 G4int zf= v_frag[jf]->GetZ();
514 G4double ex=v_frag[jf]->GetExcitationEnergy();
515 G4cout<<"(a="<<af<<", z="<<zf<<", ex="<<ex<<") ";
516 }
517 G4cout<<G4endl;
518 G4cout<<"-----------------------------------------------------"<<G4endl;
519 }
520 }
521 return v;
522 }
523
524 // search in the pool and if found then return vector with one element
525 nz = list1[A].size();
526 G4FermiConfiguration* conf1 = 0;
527 if(0 < nz) {
528 for(size_t j=0; j<nz; ++j) {
529 G4FermiConfiguration* conf = (list1[A])[j];
530 //if(Z == conf->GetZ()) {
531 // G4cout << "Single dM(MeV)= " << mass - conf->GetMass() << G4endl; }
532
533 if(Z == conf->GetZ() && mass >= conf->GetMass()) {
534 if(!(conf->GetFragmentList())[0]->IsStable()) {
535 ++nconf;
536 v->push_back(conf);
537 if(verbose > 0) {
539 G4cout<<"Total number of configurations = "<<nconf<<" for A= "
540 <<A<<" Z= "<<Z<<" E*= "<< ExEn<<" MeV"<<G4endl;
541 size_t size_vector_conf=v->size();
542 for(size_t jc=0; jc<size_vector_conf; ++jc) {
543 std::vector<const G4VFermiFragment*> v_frag = (*v)[jc]->GetFragmentList();
544 size_t size_vector_fragments=v_frag.size();
545 G4cout<<"1 Fragment configuration "<<jc+1<<": ";
546 for(size_t jf=0;jf<size_vector_fragments;++jf){
547 G4int af= v_frag[jf]->GetA();
548 G4int zf= v_frag[jf]->GetZ();
549 G4double ex=v_frag[jf]->GetExcitationEnergy();
550 G4cout<<"(a="<<af<<", z="<<zf<<", ex="<<ex<<") ";
551 }
552 G4cout<<G4endl;
553 G4cout<<"-----------------------------------------------------"<<G4endl;
554 }
555 }
556 return v;
557 } else {
558 conf1 = conf;
559 break;
560 }
561 }
562 }
563 }
564
565 // search in the list of exotic configurations
566 nz = listextra.size();
567 if(0 < nz) {
568 for(size_t j=0; j<nz; ++j) {
569 G4FermiConfiguration* conf = listextra[j];
570 if(Z == conf->GetZ() && A == conf->GetA() &&
571 mass >= conf->GetMass()) {
572 ++nconf;
573 v->push_back(conf);
574 if(verbose > 0) {
576 G4cout<<"Total number of configurations = "<<nconf<<" for A= "
577 <<A<<" Z= "<<Z<<" E*= "<< ExEn<<" MeV"<<G4endl;
578 size_t size_vector_conf=v->size();
579 for(size_t jc=0; jc<size_vector_conf; ++jc) {
580 std::vector<const G4VFermiFragment*> v_frag = (*v)[jc]->GetFragmentList();
581 size_t size_vector_fragments=v_frag.size();
582 G4cout<<"Found exotic configuration -> configuration "<<jc+1<<": ";
583 for(size_t jf=0;jf<size_vector_fragments;++jf){
584 G4int af= v_frag[jf]->GetA();
585 G4int zf= v_frag[jf]->GetZ();
586 G4double ex=v_frag[jf]->GetExcitationEnergy();
587 G4cout<<"(a="<<af<<", z="<<zf<<", ex="<<ex<<") ";
588 }
589 G4cout<<G4endl;
590 G4cout<<"-----------------------------------------------------"<<G4endl;
591 }
592 }
593 return v;
594 }
595 }
596 }
597 //G4cout << "Explore dM(MeV)= "
598 // << mass - Z*proton_mass_c2 - (A-Z)*neutron_mass_c2 << G4endl;
599
600 // add new exotic configuration
601 if(mass > Z*proton_mass_c2 + (A-Z)*neutron_mass_c2) {
602 std::vector<const G4VFermiFragment*> newvec;
603 G4int idx = 1;
604 for(G4int i=0; i<A; ++i) {
605 if(i == Z) { idx = 0; }
606 newvec.push_back(fragment_pool[idx]);
607 }
608 G4FermiConfiguration* conf = new G4FermiConfiguration(newvec);
609 listextra.push_back(conf);
610 v->push_back(conf);
611 ++nconf;
612 if(verbose > 0) {
613 G4cout<<"Total number of configurations = "<<nconf<<G4cout;
615 G4cout<<"Total number of configurations = "<<nconf<<" for A= "
616 <<A<<" Z= "<<Z<<" E*= "<< ExEn<<" MeV"<<G4endl;
617 size_t size_vector_conf=v->size();
618 for(size_t jc=0; jc<size_vector_conf; ++jc) {
619 std::vector<const G4VFermiFragment*> v_frag = (*v)[jc]->GetFragmentList();
620 size_t size_vector_fragments=v_frag.size();
621 G4cout<<"New exotic configuration -> configuration "<<jc+1<<": ";
622 for(size_t jf=0;jf<size_vector_fragments;++jf){
623 G4int af= v_frag[jf]->GetA();
624 G4int zf= v_frag[jf]->GetZ();
625 G4double ex=v_frag[jf]->GetExcitationEnergy();
626 G4cout<<"(a="<<af<<", z="<<zf<<", ex="<<ex<<") ";
627 }
628 G4cout<<G4endl;
629 G4cout<<"-----------------------------------------------------"<<G4endl;
630 }
631 }
632 return v;
633 }
634
635 // only photon evaporation is possible
636 if(conf1) {
637 v->push_back(conf1);
638 ++nconf;
639 if(verbose > 0) {
640 G4cout<<"Total number of configurations = "<<nconf<<G4endl;
642 G4cout<<"Total number of configurations = "<<nconf<<" for A= "
643 <<A<<" Z= "<<Z<<" E*= "<< ExEn<<" MeV"<<G4endl;
644 size_t size_vector_conf=v->size();
645 for(size_t jc=0; jc<size_vector_conf; ++jc) {
646 std::vector<const G4VFermiFragment*> v_frag = (*v)[jc]->GetFragmentList();
647 size_t size_vector_fragments=v_frag.size();
648 G4cout<<"Only evaporation is possible -> configuration "<<jc+1<<": ";
649 for(size_t jf=0;jf<size_vector_fragments;++jf){
650 G4int af= v_frag[jf]->GetA();
651 G4int zf= v_frag[jf]->GetZ();
652 G4double ex=v_frag[jf]->GetExcitationEnergy();
653 G4cout<<"(a="<<af<<", z="<<zf<<", ex="<<ex<<") ";
654 }
655 G4cout<<G4endl;
656 G4cout<<"-----------------------------------------------------"<<G4endl;
657 }
658 }
659 return v;
660 }
661
662 //failer
663 if(verbose > 0) {
664 G4cout << "G4FermiFragmentsPool::GetConfigurationList: WARNING: not "
665 << "able decay fragment Z= " << Z << " A= " << A
666 << " Mass(GeV)= " << mass/GeV<< G4endl;
667 }
668 return v;
669}
double G4double
Definition: G4Types.hh:64
int G4int
Definition: G4Types.hh:66
#define G4endl
Definition: G4ios.hh:52
G4DLLIMPORT std::ostream G4cout
const std::vector< const G4VFermiFragment * > & GetFragmentList()
static G4double GetNuclearMass(const G4double A, const G4double Z)

◆ GetFragment()

const G4VFermiFragment * G4FermiFragmentsPool::GetFragment ( G4int  Z,
G4int  A 
)

Definition at line 718 of file G4FermiFragmentsPool.cc.

719{
720 const G4VFermiFragment* f = 0;
721 if(Z >= maxZ || A >= maxA) { return f; }
722 size_t nz = list1[A].size();
723 if(0 < nz) {
724 for(size_t j=0; j<nz; ++j) {
725 G4FermiConfiguration* conf = (list1[A])[j];
726 if(Z == conf->GetZ()) { return (conf->GetFragmentList())[0]; }
727 }
728 }
729 return f;
730}

Referenced by G4ExcitationHandler::BreakItUp().

◆ GetMaxA()

G4int G4FermiFragmentsPool::GetMaxA ( ) const
inline

Definition at line 103 of file G4FermiFragmentsPool.hh.

104{
105 return maxA;
106}

◆ GetMaxZ()

G4int G4FermiFragmentsPool::GetMaxZ ( ) const
inline

Definition at line 98 of file G4FermiFragmentsPool.hh.

99{
100 return maxZ;
101}

◆ Instance()

G4FermiFragmentsPool * G4FermiFragmentsPool::Instance ( )
static

Definition at line 57 of file G4FermiFragmentsPool.cc.

58{
59 if(0 == theInstance) {
60 static G4FermiFragmentsPool pool;
61 theInstance = &pool;
62 }
63 return theInstance;
64}

Referenced by G4ExcitationHandler::G4ExcitationHandler(), and G4FermiConfigurationList::G4FermiConfigurationList().


The documentation for this class was generated from the following files: