Geant4_10
G4IsomerTable.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 #ifndef G4IsomerTable_h
27 #define G4IsomerTable_h 1
28 // %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
29 //
30 // MODULE: G4IsomerTable.hh
31 //
32 // Date: 5/05/13
33 // Author: H.Kurashige
34 //
35 // %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
36 //
37 // HISTORY
38 // 25/07/13 isomerTable is chaned to const member
39 //
41 
42 //
43 #include "globals.hh"
44 #include "G4IsotopeProperty.hh"
45 #include "G4VIsotopeTable.hh"
46 #include "G4Ions.hh"
47 #include "G4ParticleTable.hh"
48 #include "G4IonTable.hh"
49 #include "G4DecayTable.hh"
50 
51 #include <vector>
52 
54 //
56 {
57  // class description
58  // G4IsomerTable is the table of pointers to G4IsotopeProperty,
59  // which has magnetic moment and spin.
60  // Data File name is given by G4IONMAGNETICMOMENT
61  //
62 public:
63  //
64  typedef std::vector<G4IsotopeProperty*> G4IsotopeList;
65 
66 public:
67  // constructor
68  //
69  G4IsomerTable();
70 
71 protected:
72  // hide copy construictor and assignment operator as protected
75 
76 public:
77  // destructor
78  virtual ~G4IsomerTable();
79 
80 public:
81  // with description
82  //
85  //
86  // again it will replace the pure virtual one in the abstract base class.
87  //
88  // Z: Atomic Number
89  // A: Atomic Mass
90  // E: Excitaion energy
91  // or
92  // lvl: isomer level
93  //
94 
95  size_t entries() const;
96  G4IsotopeProperty* GetIsotopeByIndex(size_t idx) const;
97 
98 protected:
99  void FillIsotopeList();
100 
101 private:
102  enum {nEntries=3075,MaxA=260, MinZ=2, MaxZ=100};
103  static const G4double isomerTable[nEntries][5];
104  // Table of Isomer Property
105  // 0: PID = Z*10000 + 10*A + Lvl
106  // 1: Energy [keV]
107  // 2: Life Time [ns]
108  // 3: Spin [h_bar/2]
109  // 4: Magnetic Moment [joule/tesla]
110  enum {idxPID=0, idxEnergy, idxLife, idxSpin, idxMu };
111 
112  G4IsotopeList* fIsotopeList;
113  static const G4double levelTolerance;
114 };
115 
116 
117 inline
118  size_t G4IsomerTable::entries() const
119 {
120  return fIsotopeList->size();
121 }
122 
123 inline
125 {
126  if (idx<fIsotopeList->size()) return (*fIsotopeList)[idx];
127  else return 0;
128 }
129 #endif
130 
131 
132 
133 
134 
135 
size_t entries() const
virtual G4IsotopeProperty * GetIsotope(G4int Z, G4int A, G4double E)
int G4int
Definition: G4Types.hh:78
Float_t Z
Definition: plot.C:39
G4IsomerTable & operator=(const G4IsomerTable &right)
G4IsotopeProperty * GetIsotopeByIndex(size_t idx) const
void FillIsotopeList()
virtual ~G4IsomerTable()
virtual G4IsotopeProperty * GetIsotopeByIsoLvl(G4int Z, G4int A, G4int lvl=0)
double G4double
Definition: G4Types.hh:76
std::vector< G4IsotopeProperty * > G4IsotopeList