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 // G4IsotopeProperty << 27 // 26 // 28 // Class description: << 27 // $Id: G4IsotopeProperty.hh,v 1.5 2007-03-15 06:53:27 kurasige Exp $ >> 28 // GEANT4 tag $Name: not supported by cvs2svn $ 29 // 29 // 30 // G4IsotopeProperty contains properties of an << 30 // >> 31 // ------------------------------------------------------------ >> 32 // GEANT 4 class header file >> 33 // >> 34 // ------------------------------------------------------------ >> 35 // New design using G4VIsotopeTable 5 Oct. 99 H.Kurashige >> 36 // Add Magnetic Moment 14 Mar 07 H.Kurashige 31 37 32 // Author: H.Kurashige, 5 October 1999 << 38 #ifndef G4IsotopeProperty_h 33 // ------------------------------------------- << 39 #define G4IsotopeProperty_h 1 34 #ifndef G4IsotopeProperty_hh << 35 #define G4IsotopeProperty_hh 1 << 36 40 37 #include "G4Ions.hh" << 38 #include "globals.hh" 41 #include "globals.hh" 39 << 42 class G4DecayTable; 40 class G4DecayTable; << 41 class G4IsotopeProperty 43 class G4IsotopeProperty 42 { 44 { 43 public: << 45 // Class Description 44 // Constructor & destructor << 46 // G4IsotopeProperty contains properties of an isotope 45 G4IsotopeProperty() = default; << 47 // 46 virtual ~G4IsotopeProperty(); << 48 47 << 49 public: 48 G4IsotopeProperty(const G4IsotopeProperty& << 50 G4IsotopeProperty(); 49 G4IsotopeProperty& operator=(G4IsotopeProp << 51 50 << 52 // copy construictor 51 // Equality operators << 53 G4IsotopeProperty(const G4IsotopeProperty& right); 52 G4bool operator==(const G4IsotopeProperty& << 54 53 G4bool operator!=(const G4IsotopeProperty& << 55 // Assignment operator 54 << 56 G4IsotopeProperty & operator=(G4IsotopeProperty& right); 55 // Set/Get Atomic Number << 57 56 inline G4int GetAtomicNumber() const; << 58 // equal / unequal operator 57 inline void SetAtomicNumber(G4int Z); << 59 G4int operator==(const G4IsotopeProperty &right) const; 58 << 60 G4int operator!=(const G4IsotopeProperty &right) const; 59 // Set/Get Atomic Mass << 61 60 inline G4int GetAtomicMass() const; << 62 // destructor 61 inline void SetAtomicMass(G4int A); << 63 virtual ~G4IsotopeProperty(); 62 << 64 63 // Set/Get spin << 65 64 inline G4int GetiSpin() const; << 66 public: // With Description 65 inline void SetiSpin(G4int J); << 67 // Set/Get Atomic Number 66 << 68 G4int GetAtomicNumber() const; 67 // Set/Get Magnetic Moment << 69 void SetAtomicNumber(G4int Z); 68 inline G4double GetMagneticMoment() const; << 70 69 inline void SetMagneticMoment(G4double M); << 71 // Set/Get Atomic Mass 70 << 72 G4int GetAtomicMass() const; 71 // Set/Get Excited Energy << 73 void SetAtomicMass(G4int A); 72 inline G4double GetEnergy() const; << 74 73 inline void SetEnergy(G4double E); << 75 // Set/Get spin 74 << 76 G4int GetiSpin() const; 75 // Set/Get isomer level << 77 void SetiSpin(G4int J); 76 inline G4int GetIsomerLevel() const; << 78 77 inline void SetIsomerLevel(G4int level); << 79 // Set/Get Magentic Moment 78 << 80 G4double GetMagneticMoment() const; 79 // Set/Get floating level base << 81 void SetMagneticMoment(G4double M); 80 inline G4Ions::G4FloatLevelBase GetFloatLe << 82 81 inline void SetFloatLevelBase(G4Ions::G4Fl << 83 // Set/Get Excited Energy 82 inline void SetFloatLevelBase(G4int flbInd << 84 G4double GetEnergy() const; 83 << 85 void SetEnergy(G4double E); 84 // Set/Get life time << 86 85 inline G4double GetLifeTime() const; << 87 // Set/Get life time 86 inline void SetLifeTime(G4double T); << 88 G4double GetLifeTime() const; 87 << 89 void SetLifeTime(G4double T); 88 // Set/Get decay table << 90 89 inline G4DecayTable* GetDecayTable() const << 91 // Set/Get decay table 90 inline void SetDecayTable(G4DecayTable* ta << 92 G4DecayTable* GetDecayTable() const; 91 << 93 void SetDecayTable(G4DecayTable* table); 92 // Dump out information << 94 93 void DumpInfo() const; << 95 // Dump out information 94 << 96 void DumpInfo() const; 95 private: << 97 96 G4int fAtomicNumber = 0; // number of pro << 98 private: 97 G4int fAtomicMass = 0; // number of nucle << 99 G4int fAtomicNumber; // number of proton 98 G4int fISpin = 0; // total angular moment << 100 G4int fAtomicMass; // number of nucleon 99 G4double fEnergy = 0.0; // excited energy << 101 G4int fISpin; // total angular momentum (in unit of 1/2) 100 G4double fLifeTime = -1.0; // lifeTime << 102 G4double fEnergy; // excited energy 101 G4DecayTable* fDecayTable = nullptr; // d << 103 G4double fLifeTime; // lifeTime 102 G4double fMagneticMoment = 0.0; // magnet << 104 G4DecayTable* fDecayTable; // decay Table 103 G4int fIsomerLevel = -1; // isomer level << 105 G4double fMagneticMoment; // magnetic moment 104 G4Ions::G4FloatLevelBase fFloatLevelBase{ << 105 G4Ions::G4FloatLevelBase::no_Float}; // << 106 }; 106 }; 107 107 108 // ------------------------ << 108 inline 109 // Inline methods << 109 G4int G4IsotopeProperty::GetAtomicNumber() const 110 // ------------------------ << 111 << 112 inline G4int G4IsotopeProperty::GetAtomicNumbe << 113 { 110 { 114 return fAtomicNumber; 111 return fAtomicNumber; 115 } 112 } 116 113 117 inline void G4IsotopeProperty::SetAtomicNumber << 114 inline >> 115 void G4IsotopeProperty::SetAtomicNumber(G4int Z) 118 { 116 { 119 fAtomicNumber = Z; << 117 fAtomicNumber = Z; 120 } 118 } 121 119 122 inline G4int G4IsotopeProperty::GetAtomicMass( << 120 inline >> 121 G4int G4IsotopeProperty::GetAtomicMass() const 123 { 122 { 124 return fAtomicMass; 123 return fAtomicMass; 125 } 124 } 126 125 127 inline void G4IsotopeProperty::SetAtomicMass(G << 126 inline >> 127 void G4IsotopeProperty::SetAtomicMass(G4int A) 128 { 128 { 129 fAtomicMass = A; << 129 fAtomicMass = A; 130 } 130 } 131 131 132 inline G4int G4IsotopeProperty::GetiSpin() con << 132 inline >> 133 G4int G4IsotopeProperty::GetiSpin() const 133 { 134 { 134 return fISpin; 135 return fISpin; 135 } 136 } 136 137 137 inline void G4IsotopeProperty::SetiSpin(G4int << 138 inline >> 139 void G4IsotopeProperty::SetiSpin(G4int J) 138 { 140 { 139 fISpin = J; << 141 fISpin = J; 140 } 142 } 141 143 142 inline G4double G4IsotopeProperty::GetMagnetic << 144 inline >> 145 G4double G4IsotopeProperty::GetMagneticMoment() const 143 { 146 { 144 return fMagneticMoment; 147 return fMagneticMoment; 145 } 148 } 146 149 147 inline void G4IsotopeProperty::SetMagneticMome << 150 inline >> 151 void G4IsotopeProperty::SetMagneticMoment(G4double M) 148 { 152 { 149 fMagneticMoment = M; 153 fMagneticMoment = M; 150 } 154 } 151 155 152 inline G4double G4IsotopeProperty::GetEnergy() << 156 inline >> 157 G4double G4IsotopeProperty::GetEnergy() const 153 { 158 { 154 return fEnergy; 159 return fEnergy; 155 } 160 } 156 161 157 inline void G4IsotopeProperty::SetEnergy(G4dou << 162 inline >> 163 void G4IsotopeProperty::SetEnergy(G4double E) 158 { 164 { 159 fEnergy = E; << 165 fEnergy = E; 160 } 166 } 161 167 162 inline G4int G4IsotopeProperty::GetIsomerLevel << 168 inline 163 { << 169 G4double G4IsotopeProperty::GetLifeTime() const 164 return fIsomerLevel; << 165 } << 166 inline void G4IsotopeProperty::SetIsomerLevel( << 167 { << 168 fIsomerLevel = level; << 169 } << 170 << 171 inline G4double G4IsotopeProperty::GetLifeTime << 172 { 170 { 173 return fLifeTime; 171 return fLifeTime; 174 } 172 } 175 173 176 inline void G4IsotopeProperty::SetLifeTime(G4d << 174 inline >> 175 void G4IsotopeProperty::SetLifeTime(G4double T) 177 { 176 { 178 fLifeTime = T; << 177 fLifeTime = T; 179 } 178 } 180 179 181 inline G4DecayTable* G4IsotopeProperty::GetDec << 180 inline >> 181 G4DecayTable* G4IsotopeProperty::GetDecayTable() const 182 { 182 { 183 return fDecayTable; 183 return fDecayTable; 184 } 184 } 185 185 186 inline void G4IsotopeProperty::SetDecayTable(G << 186 inline >> 187 void G4IsotopeProperty::SetDecayTable(G4DecayTable* table) 187 { 188 { 188 fDecayTable = table; << 189 fDecayTable = table; 189 } 190 } >> 191 #endif >> 192 >> 193 >> 194 >> 195 >> 196 >> 197 190 198 191 inline G4Ions::G4FloatLevelBase G4IsotopePrope << 192 { << 193 return fFloatLevelBase; << 194 } << 195 199 196 inline void G4IsotopeProperty::SetFloatLevelBa << 197 { << 198 fFloatLevelBase = flb; << 199 } << 200 200 201 inline void G4IsotopeProperty::SetFloatLevelBa << 202 { << 203 fFloatLevelBase = G4Ions::FloatLevelBase(flb << 204 } << 205 201 206 #endif << 207 202