#include <G4MolecularConfiguration.hh>
Definition at line 59 of file G4MolecularConfiguration.hh.
G4MolecularConfiguration::G4MolecularConfiguration | ( | const G4MoleculeDefinition * | , | |
const G4ElectronOccupancy & | ||||
) | [protected] |
Definition at line 111 of file G4MolecularConfiguration.cc.
References fDynCharge, fDynDecayTime, fDynDiffusionCoefficient, fDynMass, fDynVanDerVaalsRadius, fElectronOccupancy, fgManager, fMoleculeDefinition, G4MolecularConfiguration::G4MolecularConfigurationManager::fTable, G4MoleculeDefinition::GetDecayTime(), G4MoleculeDefinition::GetDiffusionCoefficient(), G4MoleculeDefinition::GetMass(), G4MoleculeDefinition::GetNbElectrons(), G4ElectronOccupancy::GetTotalOccupancy(), and G4MoleculeDefinition::GetVanDerVaalsRadius().
Referenced by ChangeConfiguration(), and GetMolecularConfiguration().
00113 { 00114 fMoleculeDefinition = moleculeDef ; 00115 fgManager->fTable[fMoleculeDefinition][elecOcc] = this; 00116 std::map<G4ElectronOccupancy, G4MolecularConfiguration*, comparator>::iterator it ; 00117 it = fgManager->fTable[moleculeDef].find(elecOcc); 00118 fElectronOccupancy = &(it->first); 00119 00120 fDynCharge = fMoleculeDefinition->GetNbElectrons()-fElectronOccupancy->GetTotalOccupancy(); 00121 fDynMass = fMoleculeDefinition->GetMass() ; 00122 00123 fDynDiffusionCoefficient = fMoleculeDefinition->GetDiffusionCoefficient() ; 00124 fDynVanDerVaalsRadius = fMoleculeDefinition->GetVanDerVaalsRadius() ; 00125 fDynDecayTime = fMoleculeDefinition->GetDecayTime() ; 00126 }
G4MolecularConfiguration::G4MolecularConfiguration | ( | const G4MolecularConfiguration & | ) | [protected] |
G4MolecularConfiguration::~G4MolecularConfiguration | ( | ) | [protected] |
Definition at line 128 of file G4MolecularConfiguration.cc.
References fElectronOccupancy.
00129 { 00130 if(fElectronOccupancy) 00131 { 00132 delete fElectronOccupancy; 00133 fElectronOccupancy = 0; 00134 } 00135 }
G4MolecularConfiguration * G4MolecularConfiguration::AddElectron | ( | G4int | orbit, | |
G4int | n = 1 | |||
) |
Add n electrons to a given orbit. Note : You can add as many electrons to a given orbit, the result may be unrealist.
Definition at line 189 of file G4MolecularConfiguration.cc.
References G4ElectronOccupancy::AddElectron(), ChangeConfiguration(), and fElectronOccupancy.
Referenced by G4Molecule::AddElectron(), and MoveOneElectron().
00190 { 00191 G4ElectronOccupancy newElectronOccupancy(*fElectronOccupancy); 00192 newElectronOccupancy.AddElectron(orbit, number); 00193 return ChangeConfiguration(newElectronOccupancy); 00194 }
G4MolecularConfiguration * G4MolecularConfiguration::ChangeConfiguration | ( | const G4ElectronOccupancy & | newElectronOccupancy | ) | [protected] |
Definition at line 137 of file G4MolecularConfiguration.cc.
References fgManager, fMoleculeDefinition, G4MolecularConfiguration::G4MolecularConfigurationManager::fTable, and G4MolecularConfiguration().
Referenced by AddElectron(), ExciteMolecule(), IonizeMolecule(), MoveOneElectron(), and RemoveElectron().
00138 { 00139 G4MolecularConfiguration* output = fgManager->fTable[fMoleculeDefinition][newElectronOccupancy] ; 00140 if(! output) 00141 { 00142 output = new G4MolecularConfiguration(fMoleculeDefinition, newElectronOccupancy); 00143 } 00144 return output ; 00145 }
void G4MolecularConfiguration::DeleteManager | ( | ) | [static] |
G4MolecularConfiguration * G4MolecularConfiguration::ExciteMolecule | ( | G4int | ) |
Method used in Geant4-DNA to excite water molecules
Definition at line 156 of file G4MolecularConfiguration.cc.
References G4ElectronOccupancy::AddElectron(), ChangeConfiguration(), fElectronOccupancy, and G4ElectronOccupancy::RemoveElectron().
Referenced by G4Molecule::ExciteMolecule().
00157 { 00158 G4ElectronOccupancy newElectronOccupancy (*fElectronOccupancy); 00159 00160 newElectronOccupancy.RemoveElectron(ExcitedLevel,1); 00161 newElectronOccupancy.AddElectron(5,1); 00162 00163 return ChangeConfiguration(newElectronOccupancy); 00164 }
G4int G4MolecularConfiguration::GetAtomsNumber | ( | ) | const |
Returns the nomber of atoms compouning the molecule
Definition at line 248 of file G4MolecularConfiguration.cc.
References fMoleculeDefinition, and G4MoleculeDefinition::GetAtomsNumber().
Referenced by G4Molecule::GetAtomsNumber().
00249 { 00250 return fMoleculeDefinition->GetAtomsNumber(); 00251 }
G4int G4MolecularConfiguration::GetCharge | ( | ) | const [inline] |
Returns the charge of molecule.
Definition at line 275 of file G4MolecularConfiguration.hh.
References fDynCharge.
Referenced by G4Molecule::GetCharge().
00276 { 00277 return fDynCharge ; 00278 }
const vector< const G4MolecularDecayChannel * > * G4MolecularConfiguration::GetDecayChannel | ( | ) | const |
Definition at line 274 of file G4MolecularConfiguration.cc.
References fElectronOccupancy, and fMoleculeDefinition.
Referenced by G4Molecule::GetDecayChannel().
00275 { 00276 return fMoleculeDefinition-> GetDecayChannels(fElectronOccupancy); 00277 }
G4double G4MolecularConfiguration::GetDecayTime | ( | ) | const [inline] |
Returns the decay time of the molecule.
Definition at line 260 of file G4MolecularConfiguration.hh.
References fDynDecayTime.
Referenced by G4Molecule::GetDecayTime().
00261 { 00262 return fDynDecayTime; 00263 }
const G4MoleculeDefinition * G4MolecularConfiguration::GetDefinition | ( | ) | const [inline] |
Definition at line 235 of file G4MolecularConfiguration.hh.
References fMoleculeDefinition.
Referenced by G4Molecule::BuildTrack(), G4Molecule::GetDefinition(), and G4Molecule::SetElectronOccupancy().
00236 { 00237 return fMoleculeDefinition; 00238 }
G4double G4MolecularConfiguration::GetDiffusionCoefficient | ( | ) | const [inline] |
Returns the diffusion coefficient D.
Definition at line 250 of file G4MolecularConfiguration.hh.
References fDynDiffusionCoefficient.
Referenced by G4Molecule::GetDiffusionCoefficient().
00251 { 00252 return fDynDiffusionCoefficient; 00253 }
const G4ElectronOccupancy * G4MolecularConfiguration::GetElectronOccupancy | ( | ) | const [inline] |
Returns the object ElectronOccupancy describing the electronic configuration of the molecule.
Definition at line 240 of file G4MolecularConfiguration.hh.
References fElectronOccupancy.
Referenced by G4Molecule::GetElectronOccupancy().
00241 { 00242 return fElectronOccupancy ; 00243 }
G4MolecularConfiguration::G4MolecularConfigurationManager * G4MolecularConfiguration::GetManager | ( | ) | [static, protected] |
Definition at line 46 of file G4MolecularConfiguration.cc.
References fgManager.
Referenced by GetMolecularConfiguration().
00047 { 00048 if(!fgManager) 00049 { 00050 fgManager = new G4MolecularConfiguration::G4MolecularConfigurationManager; 00051 } 00052 00053 return fgManager; 00054 }
G4double G4MolecularConfiguration::GetMass | ( | ) | const [inline] |
Returns the total mass of the molecule.
Definition at line 285 of file G4MolecularConfiguration.hh.
References fDynMass.
Referenced by G4Molecule::GetDiffusionVelocity(), G4Molecule::GetKineticEnergy(), and G4Molecule::GetMass().
00286 { 00287 return fDynMass; 00288 }
G4MolecularConfiguration * G4MolecularConfiguration::GetMolecularConfiguration | ( | const G4MoleculeDefinition * | ) | [static] |
Definition at line 75 of file G4MolecularConfiguration.cc.
References G4MolecularConfiguration::G4MolecularConfigurationManager::fTable, G4MolecularConfiguration(), G4MoleculeDefinition::GetGroundStateElectronOccupancy(), and GetManager().
00076 { 00077 const G4ElectronOccupancy& elecOcc = *molDef->GetGroundStateElectronOccupancy(); 00078 if(GetManager()->fTable[molDef][elecOcc]) 00079 { 00080 return GetManager()->fTable[molDef][elecOcc]; 00081 } 00082 else 00083 { 00084 G4MolecularConfiguration* newConf = new G4MolecularConfiguration(molDef, elecOcc); 00085 return newConf ; 00086 } 00087 }
G4MolecularConfiguration * G4MolecularConfiguration::GetMolecularConfiguration | ( | const G4MoleculeDefinition * | , | |
const G4ElectronOccupancy & | electronOccupancy | |||
) | [static] |
Definition at line 89 of file G4MolecularConfiguration.cc.
References G4MolecularConfiguration::G4MolecularConfigurationManager::fTable, G4MolecularConfiguration(), and GetManager().
Referenced by G4MoleculeDefinition::AddeConfToExcitedState(), G4Molecule::G4Molecule(), and G4Molecule::SetElectronOccupancy().
00091 { 00092 if(GetManager()->fTable[molDef][elecOcc]) 00093 { 00094 return GetManager()->fTable[molDef][elecOcc]; 00095 } 00096 else 00097 { 00098 G4MolecularConfiguration* newConf = new G4MolecularConfiguration(molDef, elecOcc); 00099 return newConf ; 00100 } 00101 }
G4int G4MolecularConfiguration::GetMoleculeID | ( | ) | const |
Definition at line 279 of file G4MolecularConfiguration.cc.
References FatalErrorInArgument, fMoleculeDefinition, G4Exception(), G4ParticleDefinition::GetPDGEncoding(), and INT_MAX.
Referenced by G4Molecule::GetMoleculeID().
00280 { 00281 if(fMoleculeDefinition) 00282 return fMoleculeDefinition->GetPDGEncoding(); 00283 else 00284 G4Exception("G4Molecule::GetMoleculeID","",FatalErrorInArgument, "You should first enter a molecule defintion"); 00285 00286 return INT_MAX; 00287 }
const G4String & G4MolecularConfiguration::GetName | ( | ) | const |
Returns the name of the molecule
Definition at line 235 of file G4MolecularConfiguration.cc.
References G4UIcommand::ConvertToString(), fDynCharge, fMoleculeDefinition, fName, G4MoleculeDefinition::GetName(), and G4String::isNull().
Referenced by G4Molecule::GetName(), IonizeMolecule(), MoveOneElectron(), PrintState(), and RemoveElectron().
00236 { 00237 if(fName.isNull()) 00238 { 00239 fName = fMoleculeDefinition->GetName(); 00240 fName+= "^"; 00241 fName+= "{"; 00242 fName+= G4UIcommand::ConvertToString(fDynCharge); 00243 fName+= "}"; 00244 } 00245 return fName; 00246 }
G4double G4MolecularConfiguration::GetNbElectrons | ( | ) | const |
Returns the number of electron.
Definition at line 253 of file G4MolecularConfiguration.cc.
References fElectronOccupancy, and G4ElectronOccupancy::GetTotalOccupancy().
Referenced by G4Molecule::GetNbElectrons().
00254 { 00255 return fElectronOccupancy->GetTotalOccupancy(); 00256 }
G4double G4MolecularConfiguration::GetVanDerVaalsRadius | ( | ) | const [inline] |
Definition at line 270 of file G4MolecularConfiguration.hh.
References fDynVanDerVaalsRadius.
Referenced by G4Molecule::GetVanDerVaalsRadius().
00271 { 00272 return fDynVanDerVaalsRadius; 00273 }
G4MolecularConfiguration * G4MolecularConfiguration::IonizeMolecule | ( | G4int | ) |
Method used in Geant4-DNA to ionize water molecules
Definition at line 168 of file G4MolecularConfiguration.cc.
References ChangeConfiguration(), G4UIcommand::ConvertToString(), FatalErrorInArgument, fElectronOccupancy, G4Exception(), GetName(), G4ElectronOccupancy::GetOccupancy(), PrintState(), and G4ElectronOccupancy::RemoveElectron().
Referenced by G4Molecule::IonizeMolecule().
00169 { 00170 G4ElectronOccupancy newElectronOccupancy(*fElectronOccupancy); 00171 00172 if(newElectronOccupancy.GetOccupancy(IonizedLevel) != 0) 00173 { 00174 newElectronOccupancy.RemoveElectron(IonizedLevel,1); 00175 } 00176 else 00177 { 00178 G4String errMsg = "There is no electron on the orbit " + G4UIcommand::ConvertToString(IonizedLevel) + 00179 " you want to free. The molecule's name you want to ionized is "+ GetName(); 00180 G4Exception("G4Molecule::IonizeMolecule","",FatalErrorInArgument, errMsg); 00181 PrintState(); 00182 } 00183 00184 // PrintState(); 00185 00186 return ChangeConfiguration(newElectronOccupancy); 00187 }
G4MolecularConfiguration * G4MolecularConfiguration::MoveOneElectron | ( | G4int | , | |
G4int | ||||
) |
Move one electron from an orbit to another.
Definition at line 215 of file G4MolecularConfiguration.cc.
References AddElectron(), ChangeConfiguration(), G4UIcommand::ConvertToString(), FatalErrorInArgument, fElectronOccupancy, G4Exception(), GetName(), PrintState(), and RemoveElectron().
Referenced by G4Molecule::MoveOneElectron().
00216 { 00217 G4ElectronOccupancy newElectronOccupancy (*fElectronOccupancy); 00218 00219 if(newElectronOccupancy . GetOccupancy(orbitToFree)>=1) 00220 { 00221 newElectronOccupancy . RemoveElectron(orbitToFree,1); 00222 newElectronOccupancy . AddElectron(orbitToFill,1); 00223 } 00224 else 00225 { 00226 G4String errMsg = "There is no electron on the orbit " + G4UIcommand::ConvertToString(orbitToFree) + 00227 " you want to free. The molecule's name is "+ GetName(); 00228 G4Exception("G4Molecule::MoveOneElectron","",FatalErrorInArgument, errMsg); 00229 PrintState(); 00230 } 00231 00232 return ChangeConfiguration(newElectronOccupancy); 00233 }
G4MolecularConfiguration & G4MolecularConfiguration::operator= | ( | G4MolecularConfiguration & | right | ) | [protected] |
void G4MolecularConfiguration::PrintState | ( | ) | const |
Show the electronic state of the molecule.
Definition at line 258 of file G4MolecularConfiguration.cc.
References G4ElectronOccupancy::DumpInfo(), fElectronOccupancy, fMoleculeDefinition, G4cout, G4endl, G4MoleculeDefinition::GetDecayTable(), G4MoleculeDefinition::GetGroundStateElectronOccupancy(), and GetName().
Referenced by IonizeMolecule(), MoveOneElectron(), G4Molecule::PrintState(), and RemoveElectron().
00259 { 00260 G4cout<<"--------------Print electronic state of "<<GetName()<<"---------------"<<G4endl; 00261 fElectronOccupancy->DumpInfo(); 00262 if(fElectronOccupancy==fMoleculeDefinition->GetGroundStateElectronOccupancy()) 00263 { 00264 G4cout<<"At ground state"<<G4endl; 00265 } 00266 else 00267 { 00268 if(fMoleculeDefinition->GetDecayTable()) 00269 G4cout<<"Transition :"<<(fMoleculeDefinition->GetDecayTable())->GetExcitedState(fElectronOccupancy)<<G4endl; 00270 } 00271 }
G4MolecularConfiguration * G4MolecularConfiguration::RemoveElectron | ( | G4int | , | |
G4int | number = 1 | |||
) |
Remove n electrons to a given orbit.
Definition at line 196 of file G4MolecularConfiguration.cc.
References ChangeConfiguration(), G4UIcommand::ConvertToString(), fElectronOccupancy, G4Exception(), GetName(), G4ElectronOccupancy::GetOccupancy(), JustWarning, PrintState(), and G4ElectronOccupancy::RemoveElectron().
Referenced by MoveOneElectron(), and G4Molecule::RemoveElectron().
00197 { 00198 G4ElectronOccupancy newElectronOccupancy (*fElectronOccupancy); 00199 00200 if(newElectronOccupancy.GetOccupancy(orbit) != 0) 00201 { 00202 newElectronOccupancy.RemoveElectron(orbit, number ); 00203 } 00204 else 00205 { 00206 G4String errMsg = "There is already no electron into the orbit " + G4UIcommand::ConvertToString(orbit) + 00207 " you want to free. The molecule's name is "+ GetName(); 00208 G4Exception("G4Molecule::RemoveElectron","",JustWarning, errMsg); 00209 PrintState(); 00210 } 00211 00212 return ChangeConfiguration(newElectronOccupancy); 00213 }
void G4MolecularConfiguration::SetDecayTime | ( | G4double | ) | [inline] |
Set the decay time of the molecule.
Definition at line 255 of file G4MolecularConfiguration.hh.
References fDynDecayTime.
Referenced by G4MoleculeDefinition::AddeConfToExcitedState(), and G4Molecule::SetDecayTime().
00256 { 00257 fDynDecayTime = dynDecayTime; 00258 }
void G4MolecularConfiguration::SetDiffusionCoefficient | ( | G4double | ) | [inline] |
Sets the diffusion coefficient D of the molecule used in diffusion processes to calculate the mean square jump distance between two changes of direction. In three dimension : <x^2> = 6 D t where t is the mean jump time between two changes of direction.
Definition at line 245 of file G4MolecularConfiguration.hh.
References fDynDiffusionCoefficient.
Referenced by G4Molecule::SetDiffusionCoefficient().
00246 { 00247 fDynDiffusionCoefficient = dynDiffusionCoefficient ; 00248 }
void G4MolecularConfiguration::SetMass | ( | G4double | ) | [inline] |
Set the total mass of the molecule.
Definition at line 280 of file G4MolecularConfiguration.hh.
References fDynMass.
Referenced by G4Molecule::SetMass().
00281 { 00282 fDynMass = aMass ; 00283 }
void G4MolecularConfiguration::SetVanDerVaalsRadius | ( | G4double | ) | [inline] |
The Van Der Valls Radius of the molecule
Definition at line 265 of file G4MolecularConfiguration.hh.
References fDynVanDerVaalsRadius.
Referenced by G4Molecule::SetVanDerVaalsRadius().
00266 { 00267 fDynVanDerVaalsRadius = dynVanDerVaalsRadius ; 00268 }
G4int G4MolecularConfiguration::fDynCharge [protected] |
Definition at line 190 of file G4MolecularConfiguration.hh.
Referenced by G4MolecularConfiguration(), GetCharge(), and GetName().
G4double G4MolecularConfiguration::fDynDecayTime [protected] |
Definition at line 188 of file G4MolecularConfiguration.hh.
Referenced by G4MolecularConfiguration(), GetDecayTime(), and SetDecayTime().
Definition at line 186 of file G4MolecularConfiguration.hh.
Referenced by G4MolecularConfiguration(), GetDiffusionCoefficient(), and SetDiffusionCoefficient().
G4double G4MolecularConfiguration::fDynMass [protected] |
Definition at line 189 of file G4MolecularConfiguration.hh.
Referenced by G4MolecularConfiguration(), GetMass(), and SetMass().
Definition at line 187 of file G4MolecularConfiguration.hh.
Referenced by G4MolecularConfiguration(), GetVanDerVaalsRadius(), and SetVanDerVaalsRadius().
const G4ElectronOccupancy* G4MolecularConfiguration::fElectronOccupancy [protected] |
Definition at line 171 of file G4MolecularConfiguration.hh.
Referenced by AddElectron(), ExciteMolecule(), G4MolecularConfiguration(), GetDecayChannel(), GetElectronOccupancy(), GetNbElectrons(), IonizeMolecule(), MoveOneElectron(), PrintState(), RemoveElectron(), and ~G4MolecularConfiguration().
G4MolecularConfiguration::G4MolecularConfigurationManager * G4MolecularConfiguration::fgManager = 0 [static, protected] |
Definition at line 182 of file G4MolecularConfiguration.hh.
Referenced by ChangeConfiguration(), DeleteManager(), G4MolecularConfiguration(), and GetManager().
const G4MoleculeDefinition* G4MolecularConfiguration::fMoleculeDefinition [protected] |
Definition at line 170 of file G4MolecularConfiguration.hh.
Referenced by ChangeConfiguration(), G4MolecularConfiguration(), GetAtomsNumber(), GetDecayChannel(), GetDefinition(), GetMoleculeID(), GetName(), and PrintState().
G4String G4MolecularConfiguration::fName [mutable, protected] |