87         if ( p_proton ) 
return;
 
  103         if ( p_proton ) 
return;
 
  112 #ifdef G4MULTITHREADED 
  119     isIsomerCreated(false),
 
  255       G4cout << 
"G4IonTable::CreateIon() : can not create ion of  "  
  256              << 
" Z =" << Z << 
"  A = " << A 
 
  257              << 
"  because GenericIon is not ready !!" <<   
G4endl;
 
  262                  "Can not create ions because GenericIon is not ready");
 
  282     stable = (life <= 0.) || (decayTable ==0);
 
  289       ed << 
"G4IonTable::CreateIon() : G4IsotopeProperty object was not found for" 
  290          << 
" Z = " << Z << 
" A = " << A << 
" E = " << E/
keV << 
" (keV).\n" 
  291          << 
" Physics quantities such as life are not set for this ion.";
 
  326   ion = 
new G4Ions(   name,            mass,       0.0*
MeV,     charge, 
 
  329                  "nucleus",               0,             A,    encoding,
 
  330                     stable,            life,    decayTable,       
false,
 
  344     G4cout << 
"G4IonTable::CreateIon() : create ion of " << name
 
  345            << 
"  " << Z << 
", " << A
 
  348       G4cout << 
" IsomerLVL=" << lvl
 
  349              << 
" excited energy=" << Eex/
keV << 
"[keV]";
 
  358 #ifdef G4MULTITHREADED 
  362     if(!stable && decayTable)
 
  365       for(
G4int iCh=0;iCh<nCh;iCh++)
 
  391       G4cout << 
"G4IonTable::CreateIon() : can not create ion of  "  
  392              << 
" Z =" << Z << 
"  A = " << A 
 
  393              << 
"  because GenericIon is not ready !!" <<   
G4endl;
 
  397                  "Can not create ions because GenericIon is not ready");
 
  426   ion = 
new G4Ions(   name,            mass,       0.0*
MeV,     charge, 
 
  429                  "nucleus",               0,             A,    encoding,
 
  430                     stable,            life,    decayTable,       
false,
 
  445     G4cout << 
"G4IonTable::CreateIon() : create hyper ion of " << name
 
  446            << 
"  " << Z << 
", " << A << 
", " << LL
 
  449       G4cout << 
" IsomerLVL=" << lvl
 
  450              << 
" excited energy=" << Eex/
keV << 
"[keV]";
 
  467       "Ion cannot be created by an isomer level. Use excitation energy.");
 
  479     ed << 
"Isomer level " << lvl << 
" is unknown for the isotope (Z=" 
  480        << Z << 
", A=" << A << 
", L=" << LL << 
"). Null pointer is returned.";
 
  493   if ( (A<1) || (Z<=0) || (lvl<0) || (A>999) ) {
 
  496       G4cout << 
"G4IonTable::GetIon() : illegal atomic number/mass"  
  497              << 
" Z =" << Z << 
"  A = " << A <<  
"  Lvl = " << lvl << 
G4endl;
 
  506   if ( ion == 0 && lvl == 0 ) 
return GetIon(Z,A,0.0);
 
  509 #ifdef G4MULTITHREADED 
  516       if(ion == 0 && lvl == 0) ion = 
CreateIon(Z,A,lvl);
 
  521     { 
if(lvl == 0) ion = 
CreateIon(Z,A,lvl); }
 
  524   if(ion == 0 && lvl == 0) ion = 
CreateIon(Z, A, lvl);
 
  541   if (LL==0) 
return GetIon(Z,A,lvl);
 
  543   if (A < 2 || Z < 0 || Z > A-LL || LL>A || A>999 ) {
 
  546       G4cout << 
"G4IonTable::GetIon() : illegal atomic number/mass"  
  547              << 
" Z =" << Z << 
"  A = " << A << 
" L = " << LL 
 
  548              <<
"  IsomerLvl = " << lvl << 
G4endl;
 
  555       G4cout << 
"G4IonTable::GetIon() : No boud state for "  
  556              << 
" Z =" << Z << 
"  A = " << A << 
" L = " << LL 
 
  557              <<
"  IsomerLvl = " << lvl << 
G4endl;
 
  569 #ifdef G4MULTITHREADED 
  574         if(ion == 0) ion = 
CreateIon(Z, A, LL, lvl);
 
  599   if ( (A<1) || (Z<=0) || (E<0.0) || (A>999) || (J<0) ) {
 
  602       G4cout << 
"G4IonTable::GetIon() : illegal atomic number/mass"  
  603              << 
" Z =" << Z << 
"  A = " << A <<  
"  E = " << E/
keV << 
G4endl;
 
  613 #ifdef G4MULTITHREADED 
  637   if (LL==0) 
return GetIon(Z,A,E,J);
 
  639   if (A < 2 || Z < 0 || Z > A-LL || LL>A || A>999 ) {
 
  642       G4cout << 
"G4IonTable::GetIon() : illegal atomic number/mass"  
  643              << 
" Z =" << Z << 
"  A = " << A << 
" L = " << LL 
 
  651       G4cout << 
"G4IonTable::GetIon() : No boud state for "  
  652              << 
" Z =" << Z << 
"  A = " << A << 
" L = " << LL 
 
  663 #ifdef G4MULTITHREADED 
  678   if(ion == 0) ion = 
CreateIon(Z, A, LL, E);
 
  692       G4cout << 
"G4IonTable::GetIon() : illegal encoding"  
  693              << 
" CODE:" << encoding << 
G4endl;
 
  701   return GetIon( Z, A, LL, IsoLvl);
 
  707   if ( (A<1) || (Z<=0) || (J<0) || (E<0.0) || (A>999) ) {
 
  710       G4cout << 
"G4IonTable::FindIon() : illegal atomic number/mass or excitation level "  
  711              << 
" Z =" << Z << 
"  A = " << A <<  
"  E = " << E/
keV << 
G4endl;
 
  725   if (ion!=0 && E==0.0) { 
 
  731     G4IonList::iterator i = 
fIonList->find(encoding);
 
  736       G4double anExcitaionEnergy = ((
const G4Ions*)(ion))->GetExcitationEnergy();
 
  755   if (LL==0) 
return FindIon(Z,A,E,J);
 
  757   if (A < 2 || Z < 0 || Z > A-LL || LL>A || A>999 ) {
 
  760       G4cout << 
"G4IonTable::FindIon() : illegal atomic number/mass or excitation level "  
  761              << 
" Z =" << Z << 
"  A = " << A << 
" L = " << LL 
 
  776   G4IonList::iterator i = 
fIonList->find(encoding);
 
  782     G4double anExcitaionEnergy = ((
const G4Ions*)(ion))->GetExcitationEnergy();
 
  800   if ( (A<1) || (Z<=0) || (lvl<0) || (A>999) ) {
 
  803       G4cout << 
"G4IonTable::FindIon() : illegal atomic number/mass or excitation level "  
  804              << 
" Z =" << Z << 
"  A = " << A <<  
"  IsoLvl = " << lvl << 
G4endl;
 
  818   if (ion!=0 && lvl==0) { 
 
  824     G4IonList::iterator i = 
fIonList->find(encoding);
 
  829       if ( ((
const G4Ions*)(ion))->GetIsomerLevel() == lvl) {
 
  840         "Isomer level 9 may be ambiguous.");
 
  852   if (LL==0) 
return FindIon(Z,A,lvl);
 
  854   if (A < 2 || Z < 0 || Z > A-LL || LL>A || A>999 ) {
 
  857       G4cout << 
"G4IonTable::FindIon() : illegal atomic number/mass or excitation level "  
  858              << 
" Z =" << Z << 
"  A = " << A << 
" L = " << LL 
 
  859              <<
"  IsomerLvl = " << lvl << 
G4endl;
 
  872   G4IonList::iterator i = 
fIonList->find(encoding);
 
  878     if ( ((
const G4Ions*)(ion))->GetIsomerLevel() == lvl) {
 
  888         "Isomer level 9 may be ambiguous.");
 
  907   if ( Z==1 && A==1 && E==0.0 ) 
return 2212; 
 
  910   encoding += Z * 10000;
 
  912   if (lvl>0&&lvl<10) encoding +=lvl;       
 
  913   else if (E>0.0) encoding += 9;  
 
  932   encoding += LL*  10000000;
 
  933   if ( Z==1 && A==1 && E==0.0 ) encoding = 3122; 
 
  943   if (encoding <= 0) 
return false; 
 
  945   if (encoding == 2212) {  
 
  951   encoding -= 1000000000;
 
  965   if (encoding <= 0) 
return false; 
 
  967  if (encoding == 3122) {  
 
  968    Z = 1; A = 1; LL = 1;
 
  973   if (encoding % 10 != 0) {
 
  977   if (encoding < 1000000000) {
 
  982   encoding -= 1000000000;
 
  983   LL = encoding/10000000;
 
  984   encoding -= 10000000*
LL;
 
 1002     os = 
new std::ostringstream();
 
 1004     os->setf(std::ios::fixed);
 
 1013     std::ostringstream& oo = *os;
 
 1015     oo<<
'['<<E/
keV << 
']';
 
 1030   for (
int i =0; i<
LL; i++){
 
 1046     os = 
new std::ostringstream();
 
 1048     os->setf(std::ios::fixed);
 
 1056     name = 
"E" + os->str() + 
"-";
 
 1066     std::ostringstream& oo = *os;
 
 1068     oo<<
'['<<lvl << 
']';
 
 1082   for (
int i =0; i<
LL; i++){
 
 1095   static const G4String nucleus(
"nucleus");
 
 1120   static const G4String anti_nucleus(
"anti_nucleus");
 
 1121   static const G4String anti_proton(
"anti_proton");
 
 1140 #include <algorithm> 
 1144   static const std::string names[] = { 
"proton", 
"alpha", 
"deuteron",
 
 1148   return std::find(names, names+5, particle->
GetParticleName())!=names+5;
 
 1153   static const std::string names[] = { 
"anti_proton", 
"anti_alpha", 
"anti_deuteron",
 
 1154                            "anti_triton", 
"anti_He3"};
 
 1157   return std::find(names, names+5, particle->
GetParticleName())!=names+5;
 
 1166 #ifndef G4MULTITHREADED 
 1170     if ( (Z==1)&&(A==1) ) {
 
 1172     } 
else if ( (Z==1)&&(A==2) ) {
 
 1174     } 
else if ( (Z==1)&&(A==3) ) {
 
 1176     } 
else if ( (Z==2)&&(A==4) ) {
 
 1178     } 
else if ( (Z==2)&&(A==3) ) {
 
 1191 #ifndef G4MULTITHREADED 
 1195     if ( (Z==1)&&(A==1) ) {
 
 1197     } 
else if ( (Z==1)&&(A==2) ) {
 
 1199     } 
else if ( (Z==1)&&(A==3) ) {
 
 1201     } 
else if ( (Z==2)&&(A==4) ) {
 
 1203     } 
else if ( (Z==2)&&(A==3) ) {
 
 1216   if ( (A<1)  || (Z<0) || (LL<0) || (lvl<0) || (lvl>9) ){
 
 1219       G4cout << 
"G4IonTable::GetNucleusMass() : illegal atomic number/mass "  
 1220              << 
" Z =" << Z << 
"  A = " << A  
 
 1221              << 
" L = " << LL << 
" lvl = " << lvl << 
G4endl;
 
 1224     G4Exception( 
"G4IonTable::GetNucleusMass()",
"PART107",
 
 1245       G4IonList::iterator i = 
fIonList->find(encoding);
 
 1247       for( ;i != 
fIonList->end() ; i++) {
 
 1251         if ( ((
const G4Ions*)(ion))->GetIsomerLevel() == lvl) {
 
 1262         if (fProperty !=0 ) mass += fProperty->
GetEnergy();
 
 1294                 "No effects because readyToUse is true.");    
 
 1300       G4cout << 
"G4IonTable::Clear() : number of Ion regsitered =  "; 
 
 1309   if (!
IsIon(particle)) 
return;
 
 1318   fIonListShadow->insert( std::pair<const G4int, const G4ParticleDefinition*>(encoding, particle) );
 
 1324   if(!particle) 
return;
 
 1331   if (encoding !=0 ) {
 
 1332     G4IonList::iterator i = 
fIonList->find(encoding);
 
 1333     for( ;i != 
fIonList->end() ; i++) {
 
 1334       if (particle == i->second ) {
 
 1343   fIonList->insert( std::pair<const G4int, const G4ParticleDefinition*>(encoding, particle) );
 
 1350   if(!particle) 
return;
 
 1351 #ifdef G4MULTITHREADED 
 1355        << 
" is ignored as it is invoked from a worker thread.";
 
 1364       G4String msg = 
"Request of removing ";
 
 1366       msg += 
" has No effects other than Pre_Init";
 
 1374                << 
" will be removed from the IonTable " << 
G4endl;
 
 1380   if (
IsIon(particle)) {
 
 1385     if (encoding !=0 ) {
 
 1388         if (particle == i->second) {
 
 1398              << 
" is not ions" << 
G4endl; 
 
 1413   G4IonList::iterator idx;
 
 1416     if (( particle_name == 
"ALL" ) || (particle_name == 
"all")){
 
 1427   "Li", 
"Be",                                                             
"B",  
"C",  
"N",  
"O", 
"F", 
"Ne", 
 
 1428   "Na", 
"Mg",                                                             
"Al", 
"Si", 
"P", 
"S", 
"Cl", 
"Ar", 
 
 1429   "K", 
"Ca", 
"Sc", 
"Ti", 
"V", 
"Cr", 
"Mn", 
"Fe", 
"Co", 
"Ni", 
"Cu", 
"Zn", 
"Ga", 
"Ge", 
"As", 
"Se", 
"Br", 
"Kr", 
 
 1430   "Rb", 
"Sr", 
"Y", 
"Zr", 
"Nb", 
"Mo",
"Tc", 
"Ru", 
"Rh", 
"Pd", 
"Ag", 
"Cd", 
"In", 
"Sn", 
"Sb", 
"Te", 
"I",  
"Xe", 
 
 1432               "La", 
"Ce", 
"Pr", 
"Nd", 
"Pm", 
"Sm", 
"Eu", 
"Gd", 
"Tb", 
"Dy", 
"Ho", 
"Er", 
"Tm", 
"Yb", 
"Lu", 
 
 1433                    "Hf", 
"Ta", 
"W", 
"Re", 
"Os", 
"Ir", 
"Pt", 
"Au", 
"Hg", 
"Tl", 
"Pb", 
"Bi", 
"Po", 
"At", 
"Rn", 
 
 1435               "Ac", 
"Th", 
"Pa",  
"U", 
"Np", 
"Pu", 
"Am", 
"Cm", 
"Bk", 
"Cf", 
"Es", 
"Fm", 
"Md", 
"No", 
"Lr",
 
 1436               "Rf", 
"Db", 
"Sg", 
"Bh", 
"Hs", 
"Mt", 
"Ds", 
"Rg", 
 
 1437               "Cp", 
"Uut", 
"Fl",
"Uup",
"Lv",
"Uus",
"Uuo" 
 1472     G4cout << 
"G4IonTable::AddProcessManager() : can not create ion of  "  
 1474            << 
"  because GenericIon is not available!!" <<   
G4endl;
 
 1476                  "Can not create ions because GenericIon is not available");
 
 1493     if (name == fIsotopeTable->
GetName()) 
return;
 
 1504    if ( index < fIsotopeTableList->
size() ) {
 
 1505      fIsotopeTable = (*fIsotopeTableList)[index];
 
 1507    return fIsotopeTable;
 
 1540     property = fIsotopeTable->
GetIsotope(Z,A,lvl);
 
 1588   if ( (index >=0) && (index < 
Entries()) ) {
 
 1589     G4IonList::iterator idx = 
fIonList->begin();
 
 1592       if ( counter == index ) {
 
 1601     G4cout << 
" G4IonTable::GetParticle" 
 1602            << 
" invalid index (=" << index << 
")"  
 1612   if (!
IsIon(particle)) 
return false;
 
 1619   if (encoding !=0 ) {
 
 1622       if (particle == i->second ) {
 
 1659     G4double anExcitaionEnergy = ((
const G4Ions*)(ion))->GetExcitationEnergy();
 
 1677   if (LL==0) 
return FindIon(Z,A,E,J);
 
 1692     G4double anExcitaionEnergy = ((
const G4Ions*)(ion))->GetExcitationEnergy();
 
 1722     if ( ((
const G4Ions*)(ion))->GetIsomerLevel() == lvl) {
 
 1739   if (LL==0) 
return FindIon(Z,A,lvl);
 
 1753     if ( ((
const G4Ions*)(ion))->GetIsomerLevel() == lvl) {
 
 1780                "Method is invoked before G4IonTable is initialized.");
 
 1794   if( fProperty !=0 ) life = fProperty->
GetLifeTime();
 
G4int GetParticleDefinitionID() const 
void InitializeLightIons()
G4double GetMagneticMoment() const 
static const G4ParticleDefinition * p_triton
void RegisterIsotopeTable(G4VIsotopeTable *table)
static std::vector< G4VIsotopeTable * > * fIsotopeTableListShadow
G4double GetLevelTolerance()
static G4double GetNuclearMass(const G4double A, const G4double Z)
G4DecayTable * GetDecayTable() const 
void SetParticleDefinitionID(G4int id=-1)
std::ostringstream G4ExceptionDescription
void SetAntiPDGEncoding(G4int aEncoding)
const G4String & GetName() const 
G4int GetAtomicNumber() const 
void PrepareNuclideTable()
void DumpTable(const G4String &particle_name="ALL") const 
static const G4ParticleDefinition * p_alpha
G4ParticleDefinition * GetIon(G4int Z, G4int A, G4int lvl=0)
G4ParticleDefinition * GetDaughter(G4int anIndex)
void Remove(const G4ParticleDefinition *particle)
G4double GetIsomerMass(G4int Z, G4int A, G4int lvl=0) const 
static G4bool IsIon(const G4ParticleDefinition *)
G4bool IsLightAntiIon(const G4ParticleDefinition *) const 
G4VIsotopeTable * GetIsotopeTable(size_t idx=0) const 
void InsertWorker(const G4ParticleDefinition *particle)
static G4bool IsAntiIon(const G4ParticleDefinition *)
static G4int GetNucleusEncoding(G4int Z, G4int A, G4double E=0.0, G4int lvl=0)
G4int GetVerboseLevel() const 
G4int GetIsomerLevel() const 
G4VDecayChannel * GetDecayChannel(G4int index) const 
static G4ThreadLocal std::vector< G4VIsotopeTable * > * fIsotopeTableList
static const G4ParticleDefinition * p_proton
G4IsotopeProperty * GetIsotopeByIndex(size_t idx) const 
G4ParticleDefinition * GetGenericIon() const 
G4ProcessManager * GetProcessManager() const 
G4IsotopeProperty * FindIsotope(G4int Z, G4int A, G4double E) const 
#define G4MUTEX_INITIALIZER
static G4bool GetNucleusByEncoding(G4int encoding, G4int &Z, G4int &A, G4double &E, G4int &lvl)
const G4String & GetParticleName() const 
const G4String & GetIonName(G4int Z, G4int A, G4int lvl=0) const 
G4int GetAtomicNumber() const 
G4bool IsGeneralIon() const 
void Insert(const G4ParticleDefinition *particle)
static G4IonList * fIonListShadow
static G4StateManager * GetStateManager()
G4ParticleDefinition * CreateIon(G4int Z, G4int A, G4double E)
G4GLOB_DLL std::ostream G4cout
double A(double temperature)
virtual G4IsotopeProperty * GetIsotope(G4int Z, G4int A, G4double E)=0
std::multimap< G4int, const G4ParticleDefinition * > G4IonList
G4double GetEnergy() const 
static const G4ParticleDefinition * p_He3
G4double GetIonMass(G4int Z, G4int A, G4int L=0, G4int lvl=0) const 
G4int GetQuarkContent(G4int flavor) const 
const G4String & GetParticleType() const 
G4ApplicationState GetCurrentState() const 
G4bool IsMultithreadedApplication()
void AddProcessManager(G4ParticleDefinition *)
static const G4ParticleDefinition * p_triton
G4int GetAtomicMass() const 
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
G4bool Contains(const G4ParticleDefinition *particle) const 
static G4NuclideTable * GetNuclideTable()
G4ParticleDefinition * FindIon(G4int Z, G4int A, G4int lvl=0)
G4NuclideTable * pNuclideTable
G4double GetPDGMass() const 
static G4ParticleTable * GetParticleTable()
static const G4ParticleDefinition * p_deuteron
static const G4ParticleDefinition * p_alpha
static const G4ParticleDefinition * p_He3
void DestroyWorkerG4IonTable()
static const G4int LL[nN]
static G4ThreadLocal G4IonList * fIonList
G4double GetPDGLifeTime() const 
G4double GetLifeTime(const G4ParticleDefinition *) const 
G4double GetNucleusMass(G4int Z, G4int A, G4int L=0, G4int lvl=0) const 
G4ParticleDefinition * GetLightAntiIon(G4int Z, G4int A) const 
static const G4ParticleDefinition * p_proton
static const double eplus
G4ParticleDefinition * GetLightIon(G4int Z, G4int A) const 
G4ParticleDefinition * FindIonInMaster(G4int Z, G4int A, G4int lvl=0)
G4bool IsLightIon(const G4ParticleDefinition *) const 
G4int GetVerboseLevel() const 
std::multimap< G4int, const G4ParticleDefinition * >::iterator G4IonListIterator
G4int GetAtomicMass() const 
G4double GetLifeTime() const 
void SetPDGMagneticMoment(G4double mageticMoment)
G4int GetBaryonNumber() const 
static const G4String elementName[numberOfElements]
static G4double GetNuclearMass(G4int A, G4int Z, G4int L)
static const G4ParticleDefinition * p_deuteron
G4ParticleDefinition * GetParticle(G4int index) const