48 const G4double G4IsomerTable::levelTolerance = 1.0*
keV;
65 if(fIsotopeList !=0)
return;
68 fIsotopeList->reserve(nEntries);
70 for (
size_t i=0; i<nEntries; i++) {
72 G4int ionZ = pid/10000;
73 G4int ionA = (pid-ionZ*10000)/10;
82 fProperty->SetAtomicNumber(ionZ);
83 fProperty->SetAtomicMass(ionA);
84 fProperty->SetIsomerLevel(lvl);
85 fProperty->SetEnergy(ionE);
86 fProperty->SetiSpin(ionJ);
87 fProperty->SetLifeTime(ionLife);
88 fProperty->SetDecayTable(0);
89 fProperty->SetMagneticMoment(ionMu);
91 fIsotopeList->push_back(fProperty);
98 if (fIsotopeList!=0) {
99 for (
size_t i = 0 ; i<fIsotopeList->size(); i++) {
100 delete (*fIsotopeList)[i];
102 fIsotopeList->clear();
128 if ((Z<MinZ)||(Z>MaxZ)||(A>MaxA))
return fProperty;
132 G4int ptr = (low+high)/2;
135 G4int zptr = (*fIsotopeList)[ptr]->GetAtomicNumber();
136 while ( high-low > 1){
138 while ((zptr == Z)&&(ptr>0)) {
140 zptr = (*fIsotopeList)[ptr]->GetAtomicNumber();
142 if (ptr!=0) ptr += 1;
144 }
else if (zptr >Z) {
151 zptr = (*fIsotopeList)[ptr]->GetAtomicNumber();
153 if ( Z == (*fIsotopeList)[low]->GetAtomicNumber()) ptr =low;
154 else if ( Z != zptr )
return fProperty;
160 aptr = (*fIsotopeList)[ptr]->GetAtomicMass();
161 if (Z != (*fIsotopeList)[ptr]->GetAtomicNumber())
break;
163 if ( aptr != A)
return fProperty;
167 while ( (ptrE < E-levelTolerance ) && (ptr+1<(
G4int)(
entries())) ){
169 ptrE = (*fIsotopeList)[ptr]->GetEnergy();
170 if (A != (*fIsotopeList)[ptr]->GetAtomicMass())
return fProperty;
172 if (ptrE > E+levelTolerance)
return fProperty;
175 fProperty = (*fIsotopeList)[ptr];
186 if ((Z<MinZ)||(Z>MaxZ)||(A>MaxA))
return fProperty;
190 G4int ptr = (low+high)/2;
194 const G4int PID = 10000*Z +10*A + lvl;
195 G4int id = (fIsotopeList->at(ptr))->GetAtomicNumber() *10000
196 + (fIsotopeList->at(ptr))->GetAtomicMass() *10
197 + (fIsotopeList->at(ptr))->GetIsomerLevel();
198 while ( high-low > 1){
201 }
else if (
id >PID) {
208 id = (fIsotopeList->at(ptr))->GetAtomicNumber() *10000
209 + (fIsotopeList->at(ptr))->GetAtomicMass() *10
210 + (fIsotopeList->at(ptr))->GetIsomerLevel();
214 fProperty = (*fIsotopeList)[ptr];
216 id = (fIsotopeList->at(low))->GetAtomicNumber() *10000
217 + (fIsotopeList->at(low))->GetAtomicMass() *10
218 + (fIsotopeList->at(low))->GetIsomerLevel();
220 fProperty = (*fIsotopeList)[low];
222 id = (fIsotopeList->at(high))->GetAtomicNumber() *10000
223 + (fIsotopeList->at(high))->GetAtomicMass() *10
224 + (fIsotopeList->at(high))->GetIsomerLevel();
225 if (
id == PID) fProperty = (*fIsotopeList)[high];
virtual G4IsotopeProperty * GetIsotope(G4int Z, G4int A, G4double E)
G4double GetEnergy() const
G4IsomerTable & operator=(const G4IsomerTable &right)
static G4ParticleTable * GetParticleTable()
G4int GetVerboseLevel() const
virtual G4IsotopeProperty * GetIsotopeByIsoLvl(G4int Z, G4int A, G4int lvl=0)
void SetVerboseLevel(G4int level)
G4int GetAtomicMass() const
std::vector< G4IsotopeProperty * > G4IsotopeList