Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4MoleculeDefinition.hh
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 // Contact: Mathieu Karamitros (kara (AT) cenbg . in2p3 . fr)
27 //
28 // WARNING : This class is released as a prototype.
29 // It might strongly evolve or even disapear in the next releases.
30 //
31 // ----------------------------------------------------------------------
32 // GEANT 4 class implementation file
33 //
34 // 21 Oct 2009 first implementation by A. Mantero and M.Karamitros
35 // Based on prototype of A.Mantero
36 // **********************************************************************
37 //
38 
39 
40 #ifndef G4MoleculeDefinition_h
41 #define G4MoleculeDefinition_h 1
42 
43 #include "globals.hh"
44 #include "G4ParticleDefinition.hh"
45 #include "G4ios.hh"
46 #include "G4ElectronOccupancy.hh"
49 #include "G4MoleculeID.hh"
50 
51 // ######################################################################
52 // ### Molecule ###
53 // ######################################################################
54 
58 
60 {
61 // Class Description
62 // This is the base class for all molecules
63 // All molecules created are objects of this class.
64 
65 public: //With Description
67  G4double mass,
68  G4int electronsNumber,
69  G4int electronicLevels,
70  G4double diffCoeff,
71  G4int atomsNumber = -1,
72  G4double radius = -1,
73  G4double lifetime = -1,
74  G4String aType = "",
76  );
77 
78  virtual ~G4MoleculeDefinition();
79 
80  // Set the electronic configuration at ground level
81  void SetLevelOccupation(G4int, G4int eNb=2);
82  // set the occupation(0(def), 1 or 2) of the level specified
83  //(levels numbering starts from 0)
84 
85  //methods to set/get diffusion properties
86  inline void SetDiffusionCoefficient(G4double);
87  inline G4double GetDiffusionCoefficient() const;
88 
89  inline void SetAtomsNumber(G4int);
90  inline G4int GetAtomsNumber() const;
91 
92  inline void SetVanDerVaalsRadius(G4double);
93  inline G4double GetVanDerVaalsRadius() const;
94 
95  //°°°°°°°°°°°°°°°°°°°°°°°°
96  // Build the decay table
97  void AddExcitedState(const G4String&) ;
98  const G4String& GetExcitedState(const G4ElectronOccupancy*) const;
99  void AddDecayChannel(const G4String&, const G4MolecularDecayChannel*) ;
100  void AddeConfToExcitedState(const G4String&,const G4ElectronOccupancy&, double decayTime = 0.);
101 
102  //°°°°°°°°°°°°°°°°°°°°°°°°
103  // "Get" methods related to decay
104  const std::vector<const G4MolecularDecayChannel*>* GetDecayChannels(const G4ElectronOccupancy*) const;
105  const std::vector<const G4MolecularDecayChannel*>* GetDecayChannels(const G4String&) const;
106 
107  //°°°°°°°°°°°°°°°°°°°°°°°°
108  // General "Get" methods
110  inline const G4String& GetName() const;
111  inline G4double GetMass() const;
112  inline const G4String& GetType() const;
113  inline G4int GetNbElectrons() const;
114  inline G4int GetNbMolecularShells() const;
115  inline const G4MolecularDecayTable* GetDecayTable() const ;
117  inline G4double GetDecayTime() const;
118 
119 protected :
122 
123 private :
124  const G4MoleculeDefinition & operator=(const G4MoleculeDefinition &right);
125 
126 private:
127  G4double fMass;
128 
129  G4int fNbOfElectrons;
130  G4int fNbOfMolecularShells;
131 
132  // Diffusion Coefficient in one medium only
133  // Note : For the time being, we will consider only one diffusion
134  // coefficient for the all simulation => diffusion in one medium only
135  // If the user needs to use the diffusion in different materials,
136  // she/he should contact the developpers/mainteners of this package
137  G4double fDiffusionCoefficient;
138 
139  G4int fAtomsNb;
140  G4double fVanDerVaalsRadius;
141 
142  G4ElectronOccupancy* fElectronOccupancy;
143  G4MolecularDecayTable* fDecayTable;
144 };
145 
146 
148 {
149  fDiffusionCoefficient = value;
150 }
151 
153 {
154  return fDiffusionCoefficient;
155 }
156 
158 {
159  return GetPDGLifeTime();
160 }
161 
163 {
164  fAtomsNb = val;
165 }
166 
168 {
169  return fAtomsNb;
170 }
171 
173 {
174  fVanDerVaalsRadius = val;
175 }
176 
178 {
179  return fVanDerVaalsRadius;
180 }
181 
183 {
184  return fElectronOccupancy;
185 }
186 
188 {
189 
190  return GetParticleName();
191 }
192 
194 {
195  return fMass;
196 }
197 
199 {
200 
201  return GetParticleSubType();
202 }
203 
205 {
206 
207  return fNbOfElectrons;
208 }
209 
211 {
212 
213  return fNbOfMolecularShells;
214 }
215 
217 {
218  return fDecayTable;
219 }
220 
222 {
223  return fDecayTable;
224 }
225 #endif
226 
227 
228 
229 
230 
231 
232 
233 
const G4String & GetExcitedState(const G4ElectronOccupancy *) const
const G4String & GetType() const
const XML_Char * name
void AddeConfToExcitedState(const G4String &, const G4ElectronOccupancy &, double decayTime=0.)
const G4String & GetParticleSubType() const
int G4int
Definition: G4Types.hh:78
const G4String & GetParticleName() const
const std::vector< const G4MolecularDecayChannel * > * GetDecayChannels(const G4ElectronOccupancy *) const
G4int GetNbMolecularShells() const
void AddExcitedState(const G4String &)
G4double GetDecayTime() const
void AddDecayChannel(const G4String &, const G4MolecularDecayChannel *)
void SetDiffusionCoefficient(G4double)
G4double GetVanDerVaalsRadius() const
const G4String & GetName() const
const XML_Char int const XML_Char * value
G4double GetPDGLifeTime() const
G4double GetDiffusionCoefficient() const
void SetVanDerVaalsRadius(G4double)
void SetLevelOccupation(G4int, G4int eNb=2)
double G4double
Definition: G4Types.hh:76
const G4ElectronOccupancy * GetGroundStateElectronOccupancy() const
const G4MolecularDecayTable * GetDecayTable() const
static G4MoleculeID Create()
Definition: G4MoleculeID.hh:59