Geant4 Cross Reference |
1 // 1 // 2 // ******************************************* 2 // ******************************************************************** 3 // * License and Disclaimer 3 // * License and Disclaimer * 4 // * 4 // * * 5 // * The Geant4 software is copyright of th 5 // * The Geant4 software is copyright of the Copyright Holders of * 6 // * the Geant4 Collaboration. It is provided 6 // * the Geant4 Collaboration. It is provided under the terms and * 7 // * conditions of the Geant4 Software License 7 // * conditions of the Geant4 Software License, included in the file * 8 // * LICENSE and available at http://cern.ch/ 8 // * LICENSE and available at http://cern.ch/geant4/license . These * 9 // * include a list of copyright holders. 9 // * include a list of copyright holders. * 10 // * 10 // * * 11 // * Neither the authors of this software syst 11 // * Neither the authors of this software system, nor their employing * 12 // * institutes,nor the agencies providing fin 12 // * institutes,nor the agencies providing financial support for this * 13 // * work make any representation or warran 13 // * work make any representation or warranty, express or implied, * 14 // * regarding this software system or assum 14 // * regarding this software system or assume any liability for its * 15 // * use. Please see the license in the file 15 // * use. Please see the license in the file LICENSE and URL above * 16 // * for the full disclaimer and the limitatio 16 // * for the full disclaimer and the limitation of liability. * 17 // * 17 // * * 18 // * This code implementation is the result 18 // * This code implementation is the result of the scientific and * 19 // * technical work of the GEANT4 collaboratio 19 // * technical work of the GEANT4 collaboration. * 20 // * By using, copying, modifying or distri 20 // * By using, copying, modifying or distributing the software (or * 21 // * any work based on the software) you ag 21 // * any work based on the software) you agree to acknowledge its * 22 // * use in resulting scientific publicati 22 // * use in resulting scientific publications, and indicate your * 23 // * acceptance of all terms of the Geant4 Sof 23 // * acceptance of all terms of the Geant4 Software license. * 24 // ******************************************* 24 // ******************************************************************** 25 << 25 // >> 26 // 26 // ------------------------------------------- 27 // ------------------------------------------------------------------- 27 // 28 // 28 // GEANT4 Class header file 29 // GEANT4 Class header file 29 // 30 // 30 // File name: G4NistManager 31 // File name: G4NistManager 31 // 32 // 32 // Author: Vladimir Ivanchenko 33 // Author: Vladimir Ivanchenko 33 // 34 // 34 // Creation date: 23.12.2004 35 // Creation date: 23.12.2004 35 // 36 // 36 // Modifications: 37 // Modifications: 37 // 27.02.06 V.Ivanchneko add GetAtomicMassAmu 38 // 27.02.06 V.Ivanchneko add GetAtomicMassAmu and ConstructNewGasMaterial 38 // 11.05.06 V.Ivanchneko add warning flag to F 39 // 11.05.06 V.Ivanchneko add warning flag to FindMaterial method 39 // 17.10.06 V.Ivanchneko add methods: GetAtomi 40 // 17.10.06 V.Ivanchneko add methods: GetAtomicMass, GetNistElementNames, 40 // GetNistMaterialNames 41 // GetNistMaterialNames 41 // 02.05.07 V.Ivanchneko add GetNistFirstIsoto << 42 // 02.05.07 V.Ivanchneko add GetNistFirstIsotopeN and GetNumberOfNistIsotopes 42 // 28.07.07 V.Ivanchneko make simple methods i 43 // 28.07.07 V.Ivanchneko make simple methods inline 43 // 28.10.07 V.Ivanchneko add state, T, P to ma 44 // 28.10.07 V.Ivanchneko add state, T, P to maetrial build 44 // 29.04.10 V.Ivanchneko add GetMeanIonisation << 45 // 29.04.10 V.Ivanchneko add GetMeanIonisationEnergy method 45 // 01.11.10 V.Ivanchneko add G4Pow for fast co << 46 // 01.11.10 V.Ivanchneko add G4Pow for fast computations 46 // 09.02.12 P.Gumplinger add ConstructNewIdeal 47 // 09.02.12 P.Gumplinger add ConstructNewIdealGasMaterial 47 // 48 // 48 // Class Description: 49 // Class Description: 49 // 50 // 50 // A utility static class 51 // A utility static class 51 // 52 // >> 53 >> 54 // ------------------------------------------------------------------- >> 55 // >> 56 // Class Description: >> 57 // 52 // Element data from the NIST DB on Atomic Wei 58 // Element data from the NIST DB on Atomic Weights and Isotope Compositions 53 // http://physics.nist.gov/PhysRefData/Composi 59 // http://physics.nist.gov/PhysRefData/Compositions/index.html 54 // 60 // 55 // ------------------------------------------- 61 // ------------------------------------------------------------------- >> 62 // 56 63 57 #ifndef G4NistManager_h 64 #ifndef G4NistManager_h 58 #define G4NistManager_h 1 65 #define G4NistManager_h 1 59 66 60 #include "G4ICRU90StoppingData.hh" << 67 #include <vector> >> 68 #include <CLHEP/Units/PhysicalConstants.h> >> 69 >> 70 #include "globals.hh" 61 #include "G4Material.hh" 71 #include "G4Material.hh" 62 #include "G4Element.hh" << 63 #include "G4Isotope.hh" << 64 #include "G4NistElementBuilder.hh" 72 #include "G4NistElementBuilder.hh" 65 #include "G4NistMaterialBuilder.hh" 73 #include "G4NistMaterialBuilder.hh" >> 74 #include "G4ICRU90StoppingData.hh" 66 #include "G4Pow.hh" 75 #include "G4Pow.hh" 67 #include "globals.hh" << 76 #include "G4Threading.hh" 68 << 69 #include <CLHEP/Units/PhysicalConstants.h> << 70 << 71 #include <vector> << 72 77 73 class G4NistMessenger; 78 class G4NistMessenger; 74 79 >> 80 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... >> 81 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... >> 82 75 class G4NistManager 83 class G4NistManager 76 { 84 { 77 public: << 85 >> 86 public: >> 87 78 static G4NistManager* Instance(); 88 static G4NistManager* Instance(); 79 ~G4NistManager(); 89 ~G4NistManager(); 80 90 81 // Get G4Element by index 91 // Get G4Element by index 82 // 92 // 83 inline G4Element* GetElement(std::size_t ind << 93 inline G4Element* GetElement(size_t index) const; 84 << 94 85 // Find or build G4Element by atomic number 95 // Find or build G4Element by atomic number 86 // 96 // 87 inline G4Element* FindElement(G4int Z) const 97 inline G4Element* FindElement(G4int Z) const; 88 inline G4Element* FindOrBuildElement(G4int Z << 98 inline G4Element* FindOrBuildElement(G4int Z, G4bool isotopes=true); 89 << 99 90 // Find or build G4Element by symbol 100 // Find or build G4Element by symbol 91 // 101 // 92 inline G4Element* FindOrBuildElement(const G << 102 inline G4Element* FindOrBuildElement(const G4String& symb, >> 103 G4bool isotopes=true); 93 104 94 // Get number of elements 105 // Get number of elements 95 // 106 // 96 inline std::size_t GetNumberOfElements() con << 107 inline size_t GetNumberOfElements() const; 97 108 98 // Get atomic number by element symbol 109 // Get atomic number by element symbol 99 // 110 // 100 inline G4int GetZ(const G4String& symb) cons 111 inline G4int GetZ(const G4String& symb) const; 101 112 102 // Get atomic weight by element symbol - mea << 113 // Get atomic weight by element symbol - mean mass in units of amu of 103 // an atom with electron shell for the natur << 114 // an atom with electron shell for the natural isotope composition 104 // 115 // 105 inline G4double GetAtomicMassAmu(const G4Str 116 inline G4double GetAtomicMassAmu(const G4String& symb) const; 106 117 107 // Get atomic weight in atomic units - mean << 118 // Get atomic weight in atomic units - mean mass in units of amu of an atom 108 // with electron shell for the natural isoto << 119 // with electron shell for the natural isotope composition 109 // 120 // 110 inline G4double GetAtomicMassAmu(G4int Z) co 121 inline G4double GetAtomicMassAmu(G4int Z) const; 111 122 112 // Get mass of isotope without electron shel << 123 // Get mass of isotope without electron shell in Geant4 energy units 113 // 124 // 114 inline G4double GetIsotopeMass(G4int Z, G4in 125 inline G4double GetIsotopeMass(G4int Z, G4int N) const; 115 126 116 // Get mass in Geant4 energy units of an ato << 127 // Get mass in Geant4 energy units of an atom of a particular isotope 117 // with the electron shell << 128 // with the electron shell 118 // 129 // 119 inline G4double GetAtomicMass(G4int Z, G4int 130 inline G4double GetAtomicMass(G4int Z, G4int N) const; 120 131 121 // Get total ionisation energy of an atom 132 // Get total ionisation energy of an atom 122 // 133 // 123 inline G4double GetTotalElectronBindingEnerg 134 inline G4double GetTotalElectronBindingEnergy(G4int Z) const; 124 135 125 // Get N for the first natural isotope 136 // Get N for the first natural isotope 126 // 137 // 127 inline G4int GetNistFirstIsotopeN(G4int Z) c 138 inline G4int GetNistFirstIsotopeN(G4int Z) const; 128 139 129 // Get number of natural isotopes 140 // Get number of natural isotopes 130 // 141 // 131 inline G4int GetNumberOfNistIsotopes(G4int Z 142 inline G4int GetNumberOfNistIsotopes(G4int Z) const; 132 143 133 // Get natural isotope abundance 144 // Get natural isotope abundance 134 // 145 // 135 inline G4double GetIsotopeAbundance(G4int Z, 146 inline G4double GetIsotopeAbundance(G4int Z, G4int N) const; 136 147 137 // Print element by Z 148 // Print element by Z 138 // 149 // 139 inline void PrintElement(G4int Z) const; 150 inline void PrintElement(G4int Z) const; 140 151 141 // Print element from internal DB by symbol, 152 // Print element from internal DB by symbol, if "all" - print all elements 142 // 153 // 143 void PrintElement(const G4String&) const; 154 void PrintElement(const G4String&) const; 144 155 145 // Print G4Element by name, if "all" - print 156 // Print G4Element by name, if "all" - print all G4Elements 146 // 157 // 147 void PrintG4Element(const G4String&) const; << 158 void PrintG4Element(const G4String&) const; 148 159 149 // Access to the vector of Geant4 predefined << 160 // Access to the vector of Geant4 predefined element names 150 // 161 // 151 inline const std::vector<G4String>& GetNistE 162 inline const std::vector<G4String>& GetNistElementNames() const; 152 163 153 // Access mean ionisation energy for atoms ( << 164 // Access mean ionisation energy for atoms (Z <= 98) by its index 154 // << 165 // 155 inline G4double GetMeanIonisationEnergy(G4in 166 inline G4double GetMeanIonisationEnergy(G4int Z) const; 156 167 157 // Access nominal density by atomic number f << 168 // Access nominal density by atomic number for simple materials and 158 // by the index for other NIST materials << 169 // by the index for other NIST materials 159 // 170 // 160 inline G4double GetNominalDensity(G4int Z) c 171 inline G4double GetNominalDensity(G4int Z) const; 161 172 162 // Get G4Material by index << 173 // Get G4Material by index 163 // 174 // 164 inline G4Material* GetMaterial(std::size_t i << 175 inline G4Material* GetMaterial(size_t index) const; 165 << 176 166 // Find or build a G4Material by name, from 177 // Find or build a G4Material by name, from the Geant4 dataBase 167 // 178 // 168 inline G4Material* FindMaterial(const G4Stri << 179 inline G4Material* FindMaterial(const G4String& name) const; 169 inline G4Material* FindOrBuildMaterial( << 180 inline G4Material* FindOrBuildMaterial(const G4String& name, 170 const G4String& name, G4bool isotopes = tr << 181 G4bool isotopes=true, >> 182 G4bool warning=false); 171 183 172 // Find or build a simple material via atomi 184 // Find or build a simple material via atomic number 173 // 185 // 174 inline G4Material* FindSimpleMaterial(G4int << 186 inline G4Material* FindSimpleMaterial(G4int Z) const; 175 inline G4Material* FindOrBuildSimpleMaterial << 187 inline G4Material* FindOrBuildSimpleMaterial(G4int Z, 176 << 188 G4bool warning=false); >> 189 177 // Build G4Material with user defined name a 190 // Build G4Material with user defined name and density on base 178 // of a material from Geant4 dataBase 191 // of a material from Geant4 dataBase 179 // 192 // 180 G4Material* BuildMaterialWithNewDensity(cons << 193 G4Material* BuildMaterialWithNewDensity(const G4String& name, 181 G4double density = 0.0, G4double temp = NT << 194 const G4String& basename, >> 195 G4double density = 0.0, >> 196 G4double temp = NTP_Temperature, >> 197 G4double pres = CLHEP::STP_Pressure); 182 198 183 // Construct a G4Material from scratch by at 199 // Construct a G4Material from scratch by atome count 184 // temperature and pressure should be consis 200 // temperature and pressure should be consistent with the density 185 // << 201 // 186 inline G4Material* ConstructNewMaterial(cons << 202 inline G4Material* ConstructNewMaterial( 187 const std::vector<G4int>& nbAtoms, G4doubl << 203 const G4String& name, 188 G4State state = kStateSolid, G4double temp << 204 const std::vector<G4String>& elm, 189 G4double pressure = CLHEP::STP_Pressure); << 205 const std::vector<G4int>& nbAtoms, >> 206 G4double dens, >> 207 G4bool isotopes=true, >> 208 G4State state = kStateSolid, >> 209 G4double temp = NTP_Temperature, >> 210 G4double pressure = CLHEP::STP_Pressure); 190 211 191 // Construct a G4Material from scratch by fr 212 // Construct a G4Material from scratch by fraction mass 192 // temperature and pressure should be consis 213 // temperature and pressure should be consistent with the density 193 // << 214 // 194 inline G4Material* ConstructNewMaterial(cons << 215 inline G4Material* ConstructNewMaterial( 195 const std::vector<G4double>& weight, G4dou << 216 const G4String& name, 196 G4State state = kStateSolid, G4double temp << 217 const std::vector<G4String>& elm, 197 G4double pressure = CLHEP::STP_Pressure); << 218 const std::vector<G4double>& weight, >> 219 G4double dens, >> 220 G4bool isotopes=true, >> 221 G4State state = kStateSolid, >> 222 G4double temp = NTP_Temperature, >> 223 G4double pressure = CLHEP::STP_Pressure); 198 224 199 // Construct a gas G4Material from scratch b 225 // Construct a gas G4Material from scratch by atome count 200 // << 226 // 201 inline G4Material* ConstructNewGasMaterial(c << 227 inline G4Material* ConstructNewGasMaterial(const G4String& name, 202 G4double temp, G4double pres, G4bool isoto << 228 const G4String& nameNist, >> 229 G4double temp, >> 230 G4double pres, >> 231 G4bool isotopes=true); 203 232 204 // Construct an ideal gas G4Material from sc 233 // Construct an ideal gas G4Material from scratch by atom count 205 // 234 // 206 inline G4Material* ConstructNewIdealGasMater << 235 inline G4Material* ConstructNewIdealGasMaterial( 207 const std::vector<G4String>& elm, const st << 236 const G4String& name, 208 G4double temp = NTP_Temperature, G4double << 237 const std::vector<G4String>& elm, >> 238 const std::vector<G4int>& nbAtoms, >> 239 G4bool isotopes = true, >> 240 G4double temp = NTP_Temperature, >> 241 G4double pressure = CLHEP::STP_Pressure); 209 242 210 // enable/disable density effect calculator 243 // enable/disable density effect calculator by material name 211 // 244 // 212 void SetDensityEffectCalculatorFlag(const G4 245 void SetDensityEffectCalculatorFlag(const G4String&, G4bool); 213 246 214 // enable/disable density effect calculator 247 // enable/disable density effect calculator by material pointer 215 // 248 // 216 void SetDensityEffectCalculatorFlag(G4Materi 249 void SetDensityEffectCalculatorFlag(G4Material*, G4bool); 217 250 218 // Get number of G4Materials 251 // Get number of G4Materials 219 // 252 // 220 inline std::size_t GetNumberOfMaterials() co << 253 inline size_t GetNumberOfMaterials() const; 221 << 254 222 inline G4int GetVerbose() const; 255 inline G4int GetVerbose() const; 223 256 224 void SetVerbose(G4int); 257 void SetVerbose(G4int); 225 258 226 // Print G4Material by name 259 // Print G4Material by name 227 // 260 // 228 void PrintG4Material(const G4String&) const; 261 void PrintG4Material(const G4String&) const; 229 262 230 // Print predefined Geant4 materials: 263 // Print predefined Geant4 materials: 231 // "simple" - only pure materials in basic s 264 // "simple" - only pure materials in basic state (Z = 1, ..., 98) 232 // "compound" - NIST compounds 265 // "compound" - NIST compounds 233 // "hep" - HEP materials and compounds 266 // "hep" - HEP materials and compounds 234 // "bio" - bio-medical materials and compoun 267 // "bio" - bio-medical materials and compounds 235 // "all" - all 268 // "all" - all 236 // 269 // 237 inline void ListMaterials(const G4String&) c 270 inline void ListMaterials(const G4String&) const; 238 271 239 // Access to the list of names of Geant4 pre 272 // Access to the list of names of Geant4 predefined materials 240 // 273 // 241 inline const std::vector<G4String>& GetNistM 274 inline const std::vector<G4String>& GetNistMaterialNames() const; 242 275 243 // Fast computation of Z^1/3 276 // Fast computation of Z^1/3 244 // 277 // 245 inline G4double GetZ13(G4double Z) const; 278 inline G4double GetZ13(G4double Z) const; 246 inline G4double GetZ13(G4int Z) const; 279 inline G4double GetZ13(G4int Z) const; 247 280 248 // Fast computation of A^0.27 for natuaral a 281 // Fast computation of A^0.27 for natuaral abundances 249 // 282 // 250 inline G4double GetA27(G4int Z) const; 283 inline G4double GetA27(G4int Z) const; 251 284 252 // Fast computation of log(A) 285 // Fast computation of log(A) 253 // 286 // 254 inline G4double GetLOGZ(G4int Z) const; 287 inline G4double GetLOGZ(G4int Z) const; 255 inline G4double GetLOGAMU(G4int Z) const; 288 inline G4double GetLOGAMU(G4int Z) const; 256 289 257 G4ICRU90StoppingData* GetICRU90StoppingData( 290 G4ICRU90StoppingData* GetICRU90StoppingData(); 258 291 259 private: << 292 private: 260 G4NistManager(); << 293 >> 294 explicit G4NistManager(); 261 295 262 std::vector<G4Element*> elements; << 296 static G4NistManager* instance; >> 297 >> 298 std::vector<G4Element*> elements; 263 std::vector<G4Material*> materials; 299 std::vector<G4Material*> materials; 264 300 265 G4ICRU90StoppingData* fICRU90; << 301 G4ICRU90StoppingData* fICRU90; 266 G4NistElementBuilder* elmBuilder; << 302 G4NistElementBuilder* elmBuilder; 267 G4NistMaterialBuilder* matBuilder; 303 G4NistMaterialBuilder* matBuilder; 268 G4NistMessenger* messenger; << 304 G4NistMessenger* messenger; 269 G4Pow* g4pow; << 305 G4Pow* g4pow; 270 const G4MaterialTable* theMaterialTable; << 271 const G4ElementTable* theElementTable; << 272 const G4IsotopeTable* theIsotopeTable; << 273 306 274 G4double POWERA27[101]; 307 G4double POWERA27[101]; 275 G4double LOGAZ[101]; 308 G4double LOGAZ[101]; 276 309 277 std::size_t nElements; << 310 size_t nElements; 278 std::size_t nMaterials; << 311 size_t nMaterials; 279 G4int verbose; << 312 G4int verbose; >> 313 >> 314 #ifdef G4MULTITHREADED >> 315 static G4Mutex nistManagerMutex; >> 316 #endif 280 }; 317 }; 281 318 282 //....oooOO0OOooo........oooOO0OOooo........oo 319 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... >> 320 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 283 321 284 inline std::size_t G4NistManager::GetNumberOfM << 322 inline size_t G4NistManager::GetNumberOfMaterials() const >> 323 { >> 324 return nMaterials; >> 325 } 285 326 286 //....oooOO0OOooo........oooOO0OOooo........oo 327 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 287 328 288 inline G4Element* G4NistManager::GetElement(st << 329 inline G4Element* G4NistManager::GetElement(size_t index) const 289 { 330 { 290 return (index < theElementTable->size()) ? ( << 331 const G4ElementTable* theElementTable = G4Element::GetElementTable(); >> 332 return (index < theElementTable->size()) ? (*theElementTable)[index] : nullptr; 291 } 333 } 292 334 293 //....oooOO0OOooo........oooOO0OOooo........oo 335 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 294 336 295 inline G4Element* G4NistManager::FindElement(G << 337 inline >> 338 G4Element* G4NistManager::FindElement(G4int Z) const >> 339 { >> 340 return elmBuilder->FindElement(Z); >> 341 } 296 342 297 //....oooOO0OOooo........oooOO0OOooo........oo 343 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 298 344 299 inline G4Element* G4NistManager::FindOrBuildEl << 345 inline >> 346 G4Element* G4NistManager::FindOrBuildElement(G4int Z, G4bool isotopes) 300 { 347 { 301 return elmBuilder->FindOrBuildElement(Z, iso 348 return elmBuilder->FindOrBuildElement(Z, isotopes); 302 } 349 } 303 350 304 //....oooOO0OOooo........oooOO0OOooo........oo 351 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 305 352 306 inline G4Element* G4NistManager::FindOrBuildEl << 353 inline >> 354 G4Element* G4NistManager::FindOrBuildElement(const G4String& symb, >> 355 G4bool isotopes) 307 { 356 { 308 return elmBuilder->FindOrBuildElement(symb, 357 return elmBuilder->FindOrBuildElement(symb, isotopes); 309 } 358 } 310 359 311 //....oooOO0OOooo........oooOO0OOooo........oo 360 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 312 361 313 inline std::size_t G4NistManager::GetNumberOfE << 362 inline size_t G4NistManager::GetNumberOfElements() const >> 363 { >> 364 return nElements; >> 365 } 314 366 315 //....oooOO0OOooo........oooOO0OOooo........oo 367 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 316 368 317 inline G4int G4NistManager::GetZ(const G4Strin << 369 inline G4int G4NistManager::GetZ(const G4String& symb) const >> 370 { >> 371 return elmBuilder->GetZ(symb); >> 372 } 318 373 319 //....oooOO0OOooo........oooOO0OOooo........oo 374 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 320 375 321 inline G4double G4NistManager::GetAtomicMassAm 376 inline G4double G4NistManager::GetAtomicMassAmu(const G4String& symb) const 322 { 377 { 323 return elmBuilder->GetAtomicMassAmu(symb); 378 return elmBuilder->GetAtomicMassAmu(symb); 324 } 379 } 325 380 326 //....oooOO0OOooo........oooOO0OOooo........oo 381 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 327 382 328 inline G4double G4NistManager::GetAtomicMassAm 383 inline G4double G4NistManager::GetAtomicMassAmu(G4int Z) const 329 { 384 { 330 return elmBuilder->GetAtomicMassAmu(Z); 385 return elmBuilder->GetAtomicMassAmu(Z); 331 } 386 } 332 387 333 //....oooOO0OOooo........oooOO0OOooo........oo 388 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 334 389 335 inline G4double G4NistManager::GetIsotopeMass( << 390 inline >> 391 G4double G4NistManager::GetIsotopeMass(G4int Z, G4int N) const 336 { 392 { 337 return elmBuilder->GetIsotopeMass(Z, N); 393 return elmBuilder->GetIsotopeMass(Z, N); 338 } 394 } 339 395 340 //....oooOO0OOooo........oooOO0OOooo........oo 396 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 341 397 342 inline G4double G4NistManager::GetAtomicMass(G << 398 inline >> 399 G4double G4NistManager::GetAtomicMass(G4int Z, G4int N) const 343 { 400 { 344 return elmBuilder->GetAtomicMass(Z, N); 401 return elmBuilder->GetAtomicMass(Z, N); 345 } 402 } 346 403 347 //....oooOO0OOooo........oooOO0OOooo........oo 404 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 348 405 349 inline G4double G4NistManager::GetTotalElectro << 406 inline >> 407 G4double G4NistManager::GetTotalElectronBindingEnergy(G4int Z) const 350 { 408 { 351 return elmBuilder->GetTotalElectronBindingEn 409 return elmBuilder->GetTotalElectronBindingEnergy(Z); 352 } 410 } 353 411 354 //....oooOO0OOooo........oooOO0OOooo........oo 412 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 355 413 356 inline G4double G4NistManager::GetIsotopeAbund << 414 inline >> 415 G4double G4NistManager::GetIsotopeAbundance(G4int Z, G4int N) const 357 { 416 { 358 return elmBuilder->GetIsotopeAbundance(Z, N) 417 return elmBuilder->GetIsotopeAbundance(Z, N); 359 } 418 } 360 419 361 //....oooOO0OOooo........oooOO0OOooo........oo 420 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 362 421 363 inline G4int G4NistManager::GetNistFirstIsotop << 422 inline >> 423 G4int G4NistManager::GetNistFirstIsotopeN(G4int Z) const 364 { 424 { 365 return elmBuilder->GetNistFirstIsotopeN(Z); 425 return elmBuilder->GetNistFirstIsotopeN(Z); 366 } 426 } 367 427 368 //....oooOO0OOooo........oooOO0OOooo........oo 428 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 369 429 370 inline G4int G4NistManager::GetNumberOfNistIso << 430 inline >> 431 G4int G4NistManager::GetNumberOfNistIsotopes(G4int Z) const 371 { 432 { 372 return elmBuilder->GetNumberOfNistIsotopes(Z 433 return elmBuilder->GetNumberOfNistIsotopes(Z); 373 } 434 } 374 435 375 //....oooOO0OOooo........oooOO0OOooo........oo 436 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 376 437 377 inline const std::vector<G4String>& G4NistMana << 438 inline >> 439 const std::vector<G4String>& G4NistManager::GetNistElementNames() const 378 { 440 { 379 return elmBuilder->GetElementNames(); 441 return elmBuilder->GetElementNames(); 380 } 442 } 381 443 382 //....oooOO0OOooo........oooOO0OOooo........oo 444 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 383 445 384 inline G4double G4NistManager::GetMeanIonisati 446 inline G4double G4NistManager::GetMeanIonisationEnergy(G4int Z) const 385 { 447 { 386 return matBuilder->GetMeanIonisationEnergy(Z 448 return matBuilder->GetMeanIonisationEnergy(Z); 387 } 449 } 388 450 389 //....oooOO0OOooo........oooOO0OOooo........oo 451 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 390 452 391 inline G4double G4NistManager::GetNominalDensi 453 inline G4double G4NistManager::GetNominalDensity(G4int Z) const 392 { 454 { 393 return matBuilder->GetNominalDensity(Z); 455 return matBuilder->GetNominalDensity(Z); 394 } 456 } 395 457 396 //....oooOO0OOooo........oooOO0OOooo........oo 458 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 397 459 398 inline void G4NistManager::PrintElement(G4int << 460 inline void G4NistManager::PrintElement(G4int Z) const >> 461 { >> 462 elmBuilder->PrintElement(Z); >> 463 } 399 464 400 //....oooOO0OOooo........oooOO0OOooo........oo 465 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 401 466 402 inline G4Material* G4NistManager::GetMaterial( << 467 inline G4Material* G4NistManager::GetMaterial(size_t index) const 403 { 468 { >> 469 const G4MaterialTable* theMaterialTable = G4Material::GetMaterialTable(); 404 return (index < theMaterialTable->size()) ? 470 return (index < theMaterialTable->size()) ? (*theMaterialTable)[index] : nullptr; 405 } 471 } 406 472 407 //....oooOO0OOooo........oooOO0OOooo........oo 473 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 408 474 409 inline G4int G4NistManager::GetVerbose() const << 475 inline G4int G4NistManager::GetVerbose() const >> 476 { >> 477 return verbose; >> 478 } 410 479 411 //....oooOO0OOooo........oooOO0OOooo........oo 480 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 412 481 413 inline G4Material* G4NistManager::FindMaterial << 482 inline >> 483 G4Material* G4NistManager::FindMaterial(const G4String& name) const 414 { 484 { 415 return matBuilder->FindMaterial(name); << 485 return matBuilder->FindMaterial(name); 416 } 486 } 417 487 418 //....oooOO0OOooo........oooOO0OOooo........oo 488 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 419 489 420 inline G4Material* G4NistManager::FindOrBuildM << 490 inline >> 491 G4Material* G4NistManager::FindOrBuildMaterial(const G4String& name, >> 492 G4bool, G4bool warning) 421 { 493 { 422 return matBuilder->FindOrBuildMaterial(name, 494 return matBuilder->FindOrBuildMaterial(name, warning); 423 } 495 } 424 496 425 //....oooOO0OOooo........oooOO0OOooo........oo 497 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 426 498 427 inline G4Material* G4NistManager::FindSimpleMa << 499 inline >> 500 G4Material* G4NistManager::FindSimpleMaterial(G4int Z) const 428 { 501 { 429 return matBuilder->FindSimpleMaterial(Z); << 502 return matBuilder->FindSimpleMaterial(Z); 430 } 503 } 431 504 432 //....oooOO0OOooo........oooOO0OOooo........oo 505 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 433 506 434 inline G4Material* G4NistManager::FindOrBuildS << 507 inline >> 508 G4Material* G4NistManager::FindOrBuildSimpleMaterial(G4int Z, G4bool warning) 435 { 509 { 436 return matBuilder->FindOrBuildSimpleMaterial << 510 return matBuilder->FindOrBuildSimpleMaterial(Z, warning); 437 } 511 } 438 512 439 //....oooOO0OOooo........oooOO0OOooo........oo 513 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 440 514 441 inline G4Material* G4NistManager::ConstructNew << 515 inline G4Material* G4NistManager::ConstructNewMaterial( 442 const std::vector<G4String>& elm, const std: << 516 const G4String& name, 443 G4State state, G4double T, G4double P) << 517 const std::vector<G4String>& elm, >> 518 const std::vector<G4int>& nbAtoms, >> 519 G4double dens, >> 520 G4bool, >> 521 G4State state, >> 522 G4double T, >> 523 G4double P) 444 524 445 { 525 { 446 return matBuilder->ConstructNewMaterial(name << 526 return >> 527 matBuilder->ConstructNewMaterial(name,elm,nbAtoms,dens,state,T,P); 447 } 528 } 448 529 449 //....oooOO0OOooo........oooOO0OOooo........oo 530 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 450 531 451 inline G4Material* G4NistManager::ConstructNew << 532 inline G4Material* G4NistManager::ConstructNewMaterial( 452 const std::vector<G4String>& elm, const std: << 533 const G4String& name, 453 G4State state, G4double T, G4double P) << 534 const std::vector<G4String>& elm, >> 535 const std::vector<G4double>& w, >> 536 G4double dens, >> 537 G4bool, >> 538 G4State state, >> 539 G4double T, >> 540 G4double P) 454 { 541 { 455 return matBuilder->ConstructNewMaterial(name << 542 return matBuilder->ConstructNewMaterial(name,elm,w,dens,state,T,P); 456 } 543 } 457 544 458 //....oooOO0OOooo........oooOO0OOooo........oo 545 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 459 546 460 inline G4Material* G4NistManager::ConstructNew 547 inline G4Material* G4NistManager::ConstructNewGasMaterial( 461 const G4String& name, const G4String& nameNi << 548 const G4String& name, >> 549 const G4String& nameNist, >> 550 G4double temp, G4double pres, >> 551 G4bool) 462 { 552 { 463 return matBuilder->ConstructNewGasMaterial(n << 553 return matBuilder->ConstructNewGasMaterial(name,nameNist,temp,pres); 464 } 554 } 465 555 466 //....oooOO0OOooo........oooOO0OOooo........oo 556 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 467 557 468 inline G4Material* G4NistManager::ConstructNew << 558 inline G4Material* G4NistManager::ConstructNewIdealGasMaterial( 469 const std::vector<G4String>& elm, const std: << 559 const G4String& name, 470 G4double P) << 560 const std::vector<G4String>& elm, >> 561 const std::vector<G4int>& nbAtoms, >> 562 G4bool, >> 563 G4double T, >> 564 G4double P) 471 { 565 { 472 return matBuilder->ConstructNewIdealGasMater << 566 return >> 567 matBuilder->ConstructNewIdealGasMaterial(name,elm,nbAtoms,T,P); 473 } 568 } 474 569 475 //....oooOO0OOooo........oooOO0OOooo........oo 570 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 476 571 477 inline void G4NistManager::ListMaterials(const 572 inline void G4NistManager::ListMaterials(const G4String& list) const 478 { 573 { 479 matBuilder->ListMaterials(list); 574 matBuilder->ListMaterials(list); 480 } 575 } 481 576 482 //....oooOO0OOooo........oooOO0OOooo........oo 577 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 483 578 484 inline const std::vector<G4String>& G4NistMana << 579 inline >> 580 const std::vector<G4String>& G4NistManager::GetNistMaterialNames() const 485 { 581 { 486 return matBuilder->GetMaterialNames(); 582 return matBuilder->GetMaterialNames(); 487 } 583 } 488 584 489 //....oooOO0OOooo........oooOO0OOooo........oo 585 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 490 586 491 inline G4double G4NistManager::GetZ13(G4double << 587 inline G4double G4NistManager::GetZ13(G4double A) const >> 588 { >> 589 return g4pow->A13(A); >> 590 } 492 591 493 //....oooOO0OOooo........oooOO0OOooo........oo 592 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 494 593 495 inline G4double G4NistManager::GetZ13(G4int Z) << 594 inline G4double G4NistManager::GetZ13(G4int Z) const >> 595 { >> 596 return g4pow->Z13(Z); >> 597 } 496 598 497 //....oooOO0OOooo........oooOO0OOooo........oo 599 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 498 600 499 inline G4double G4NistManager::GetA27(G4int Z) 601 inline G4double G4NistManager::GetA27(G4int Z) const 500 { 602 { 501 return (0 <= Z && Z < 101) ? POWERA27[Z] : g 603 return (0 <= Z && Z < 101) ? POWERA27[Z] : g4pow->powZ(Z, 0.27); 502 } 604 } 503 605 504 //....oooOO0OOooo........oooOO0OOooo........oo 606 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 505 607 506 inline G4double G4NistManager::GetLOGZ(G4int Z << 608 inline G4double G4NistManager::GetLOGZ(G4int Z) const >> 609 { >> 610 return g4pow->logZ(Z); >> 611 } 507 612 508 //....oooOO0OOooo........oooOO0OOooo........oo 613 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 509 614 510 inline G4double G4NistManager::GetLOGAMU(G4int 615 inline G4double G4NistManager::GetLOGAMU(G4int Z) const 511 { 616 { 512 return (0 <= Z && Z < 101) ? LOGAZ[Z] : 0.0; 617 return (0 <= Z && Z < 101) ? LOGAZ[Z] : 0.0; 513 } 618 } 514 619 515 //....oooOO0OOooo........oooOO0OOooo........oo 620 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 516 621 517 #endif 622 #endif >> 623 518 624