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10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /materials/src/G4IonisParamElm.cc (Version 11.3.0) and /materials/src/G4IonisParamElm.cc (Version 7.0)


  1 //                                                  1 //
  2 // *******************************************      2 // ********************************************************************
  3 // * License and Disclaimer                    <<   3 // * DISCLAIMER                                                       *
  4 // *                                                4 // *                                                                  *
  5 // * The  Geant4 software  is  copyright of th <<   5 // * The following disclaimer summarizes all the specific disclaimers *
  6 // * the Geant4 Collaboration.  It is provided <<   6 // * of contributors to this software. The specific disclaimers,which *
  7 // * conditions of the Geant4 Software License <<   7 // * govern, are listed with their locations in:                      *
  8 // * LICENSE and available at  http://cern.ch/ <<   8 // *   http://cern.ch/geant4/license                                  *
  9 // * include a list of copyright holders.      << 
 10 // *                                                9 // *                                                                  *
 11 // * Neither the authors of this software syst     10 // * Neither the authors of this software system, nor their employing *
 12 // * institutes,nor the agencies providing fin     11 // * institutes,nor the agencies providing financial support for this *
 13 // * work  make  any representation or  warran     12 // * work  make  any representation or  warranty, express or implied, *
 14 // * regarding  this  software system or assum     13 // * regarding  this  software system or assume any liability for its *
 15 // * use.  Please see the license in the file  <<  14 // * use.                                                             *
 16 // * for the full disclaimer and the limitatio << 
 17 // *                                               15 // *                                                                  *
 18 // * This  code  implementation is the result  <<  16 // * This  code  implementation is the  intellectual property  of the *
 19 // * technical work of the GEANT4 collaboratio <<  17 // * GEANT4 collaboration.                                            *
 20 // * By using,  copying,  modifying or  distri <<  18 // * By copying,  distributing  or modifying the Program (or any work *
 21 // * any work based  on the software)  you  ag <<  19 // * based  on  the Program)  you indicate  your  acceptance of  this *
 22 // * use  in  resulting  scientific  publicati <<  20 // * statement, and all its terms.                                    *
 23 // * acceptance of all terms of the Geant4 Sof << 
 24 // *******************************************     21 // ********************************************************************
 25                                                <<  22 //
 26 // 09-07-98, data moved from G4Element. M.Mair <<  23 //
 27 // 22-11-00, tabulation of ionisation potentia <<  24 // $Id: G4IonisParamElm.cc,v 1.11 2004/12/07 08:50:03 gcosmo Exp $
 28 //           the ICRU Report N#37. V.Ivanchenk <<  25 // GEANT4 tag $Name: geant4-07-00-cand-03 $
 29 // 08-03-01, correct handling of fShellCorrect <<  26 //
 30 // 17-10-02, Fix excitation energy interpolati <<  27 //
 31 // 06-09-04, Update calculated values after an <<  28 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
                                                   >>  29 //
                                                   >>  30 // 06-09-04, Update calculated values after any change of ionisation 
 32 //           potential change. V.Ivanchenko        31 //           potential change. V.Ivanchenko
 33 // 29-04-10, Using G4Pow and mean ionisation e <<  32 // 17-10-02, Fix excitation energy interpolation. V.Ivanchenko
 34 // 27.10.11: new scheme for G4Exception  (mma) <<  33 // 08-03-01, correct handling of fShellCorrectionVector. M.Maire
                                                   >>  34 // 22-11-00, tabulation of ionisation potential from 
                                                   >>  35 //           the ICRU Report N#37. V.Ivanchenko
                                                   >>  36 // 09-07-98, data moved from G4Element. M.Maire
                                                   >>  37 //
                                                   >>  38 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
 35                                                    39 
 36 #include "G4IonisParamElm.hh"                      40 #include "G4IonisParamElm.hh"
 37                                                    41 
 38 #include "G4NistManager.hh"                    <<  42 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
 39 #include "G4PhysicalConstants.hh"              <<  43 
 40 #include "G4Pow.hh"                            <<  44 G4IonisParamElm::G4IonisParamElm(G4double Z)
 41 #include "G4SystemOfUnits.hh"                  <<  45 {
 42                                                <<  46     if (Z < 1.) G4Exception
 43 //....oooOO0OOooo........oooOO0OOooo........oo <<  47       (" ERROR! It is not allowed to create an Element with Z < 1" );
 44                                                <<  48     
 45 G4IonisParamElm::G4IonisParamElm(G4double Atom <<  49     // some basic functions of the atomic number
 46 {                                              <<  50     fZ = Z;
 47   G4int Z = G4lrint(AtomNumber);               <<  51     fZ3  = std::pow(fZ, 1./3.);
 48   if (Z < 1) {                                 <<  52     fZZ3 = std::pow(fZ*(fZ+1.), 1./3.);
 49     G4Exception("G4IonisParamElm::G4IonisParam <<  53     flogZ3 = std::log(fZ)/3.;
 50       "It is not allowed to create an Element  <<  54    
 51   }                                            <<  55      // Parameters for energy loss by ionisation   
 52   G4Pow* g4pow = G4Pow::GetInstance();         <<  56 
 53                                                <<  57      // Mean excitation energy
 54   // some basic functions of the atomic number <<  58      // from "Stopping Powers for Electrons and Positrons"
 55   fZ = Z;                                      <<  59      // ICRU Report N#37, 1984  (energy in eV)
 56   fZ3 = g4pow->Z13(Z);                         <<  60     static double exc[100] = { 
 57   fZZ3 = fZ3 * g4pow->Z13(Z + 1);              <<  61     21.8, 20.9, 13.3, 15.9, 15.2, 13.0, 11.7, 11.9, 11.5, 13.7,
 58   flogZ3 = g4pow->logZ(Z) / 3.;                <<  62     13.6, 13.0, 12.8, 12.4, 11.5, 11.3, 10.2, 10.4, 10.0,  9.6,
 59                                                <<  63     10.3, 10.6, 10.7, 10.7, 10.9, 11.0, 11.0, 11.1, 11.1, 11.0,
 60   fMeanExcitationEnergy = G4NistManager::Insta <<  64     10.8, 10.4, 10.5, 10.2,  9.8,  9.8,  9.8,  9.6,  9.7,  9.8,
 61                                                <<  65     10.2, 10.1, 10.0, 10.0, 10.0, 10.2, 10.0,  9.8, 10.0,  9.8,
 62   // compute parameters for ion transport      <<  66      9.5,  9.3,  9.3,  8.9,  8.9,  8.8,  8.8,  8.8,  9.1,  9.1,
 63   // The aproximation from:                    <<  67      9.2,  9.3,  9.2,  9.2,  9.4,  9.5,  9.7,  9.7,  9.8,  9.8,
 64   // J.F.Ziegler, J.P. Biersack, U. Littmark   <<  68      9.8,  9.8,  9.8,  9.8,  9.8,  9.8,  9.8, 10.1, 10.0, 10.0,
 65   // The Stopping and Range of Ions in Matter, <<  69     10.0, 10.0,  9.9,  9.9,  9.7,  9.2,  9.5,  9.4,  9.4,  9.4,
 66   // Vol.1, Pergamon Press, 1985               <<  70      9.6,  9.7,  9.7,  9.8,  9.8,  9.8,  9.8,  9.9,  9.9,  9.9 };
 67   // Fast ions or hadrons                      <<  71 
 68                                                <<  72     G4int iz = (G4int)Z - 1 ;
 69   G4int iz = Z - 1;                            <<  73     if(0  > iz) iz = 0;
 70   if (91 < iz) {                               <<  74     else if(99 < iz) iz = 99 ;
 71     iz = 91;                                   <<  75     fMeanExcitationEnergy = fZ * exc[iz] * eV ;
 72   }                                            <<  76 
 73                                                <<  77 
 74   // clang-format off                          <<  78     fTau0 = 0.1*fZ3*MeV/proton_mass_c2;
 75   static const G4double vFermi[92] = {         <<  79     fTaul = 2.*MeV/proton_mass_c2;
 76     1.0309,  0.15976, 0.59782, 1.0781,  1.0486 <<  80 
 77     0.45259, 0.71074, 0.90519, 0.97411, 0.9718 <<  81     // compute the Bethe-Bloch formula for energy = fTaul*particle mass
 78     0.81707, 0.9943,  1.1423,  1.2381,  1.1222 <<  82     G4double rate = fMeanExcitationEnergy/electron_mass_c2 ;
 79     0.84912, 0.95,    1.0903,  1.0429,  0.4971 <<  83     G4double w = fTaul*(fTaul+2.) ;
 80     1.029,   1.2542,  1.122,   1.1241,  1.0882 <<  84     fBetheBlochLow = (fTaul+1.)*(fTaul+1.)*std::log(2.*w/rate)/w - 1. ;
 81     0.93155, 1.0047,  0.55379, 0.43289, 0.3263 <<  85     fBetheBlochLow = 2.*fZ*twopi_mc2_rcl2*fBetheBlochLow ; 
 82     0.71418, 0.71453, 0.5911,  0.70263, 0.6804 <<  86   
 83     0.71801, 0.83048, 1.1222,  1.2381,  1.045, <<  87     fClow = std::sqrt(fTaul)*fBetheBlochLow;
 84     0.66401, 0.84912, 0.88433, 0.80746, 0.4335 <<  88     fAlow = 6.458040 * fClow/fTau0;
 85     1.9578,  1.0257} ;                         <<  89     G4double Taum = 0.035*fZ3*MeV/proton_mass_c2;
 86                                                <<  90     fBlow =-3.229020*fClow/(fTau0*std::sqrt(Taum));
 87   static const G4double lFactor[92] = {        <<  91 
 88     1.0,  1.0,  1.1,  1.06, 1.01, 1.03, 1.04,  <<  92     // Shell correction factors
 89     0.82, 0.81, 0.83, 0.88, 1.0,  0.95, 0.97,  <<  93     fShellCorrectionVector = new G4double[3];
 90     0.98, 0.97, 0.96, 0.93, 0.91, 0.9,  0.88,  <<  94     rate = 0.001*fMeanExcitationEnergy/eV;
 91     0.9,  0.85, 0.9,  0.9,  0.91, 0.92, 0.9,   <<  95     G4double rate2 = rate*rate;
 92     0.9,  0.88, 0.9,  0.88, 0.88, 0.9,  0.9,   <<  96     /*    
 93     0.9,  0.9,  0.96, 1.2,  0.9,  0.88, 0.88,  <<  97     fShellCorrectionVector[0] = ( 1.10289e5 + 5.14781e8*rate)*rate2 ;
 94     0.92, 0.95, 0.99, 1.03, 1.05, 1.07, 1.08,  <<  98     fShellCorrectionVector[1] = ( 7.93805e3 - 2.22565e7*rate)*rate2 ;
 95     1.08, 1.08, 1.09, 1.09, 1.1,  1.11, 1.12,  <<  99     fShellCorrectionVector[2] = (-9.92256e1 + 2.10823e5*rate)*rate2 ;
 96     1.17, 1.2,  1.18, 1.17, 1.17, 1.16, 1.16,  << 100     */
 97     1.16, 1.16} ;                              << 101     fShellCorrectionVector[0] = ( 0.422377   + 3.858019*rate)*rate2 ;
 98   // clang-format on                           << 102     fShellCorrectionVector[1] = ( 0.0304043  - 0.1667989*rate)*rate2 ;
 99                                                << 103     fShellCorrectionVector[2] = (-0.00038106 + 0.00157955*rate)*rate2 ;
100   fVFermi = vFermi[iz];                        << 104 }
101   fLFactor = lFactor[iz];                      << 105 
102                                                << 106 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
103   // obsolete parameters for ionisation        << 107 
104   fTau0 = 0.1 * fZ3 * MeV / proton_mass_c2;    << 108 G4IonisParamElm::~G4IonisParamElm()
105   fTaul = 2. * MeV / proton_mass_c2;           << 109 {
106                                                << 110   if (fShellCorrectionVector) delete [] fShellCorrectionVector; 
107   // compute the Bethe-Bloch formula for energ << 111 }
108   G4double rate = fMeanExcitationEnergy / elec << 112 
109   G4double w = fTaul * (fTaul + 2.);           << 113 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
110   fBetheBlochLow = (fTaul + 1.) * (fTaul + 1.) << 114 
111   fBetheBlochLow = 2. * fZ * twopi_mc2_rcl2 *  << 115 G4IonisParamElm::G4IonisParamElm(G4IonisParamElm& right)
112                                                << 116 {
113   fClow = std::sqrt(fTaul) * fBetheBlochLow;   << 117   *this = right;
114   fAlow = 6.458040 * fClow / fTau0;            << 118 }
115   G4double Taum = 0.035 * fZ3 * MeV / proton_m << 119 
116   fBlow = -3.229020 * fClow / (fTau0 * std::sq << 120 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
117                                                << 121 
118   // Shell correction parameterization         << 122 const G4IonisParamElm& G4IonisParamElm::operator=(const G4IonisParamElm& right)
119   fShellCorrectionVector = new G4double[3];  / << 123 {
120   rate = 0.001 * fMeanExcitationEnergy / eV;   << 124   if (this != &right)
121   G4double rate2 = rate * rate;                << 125     {
122   fShellCorrectionVector[0] = (0.422377 + 3.85 << 126       fZ                     = right.fZ;
123   fShellCorrectionVector[1] = (0.0304043 - 0.1 << 127       fZ3                    = right.fZ3;
124   fShellCorrectionVector[2] = (-0.00038106 + 0 << 128       fZZ3                   = right.fZZ3;
                                                   >> 129       flogZ3                 = right.flogZ3;
                                                   >> 130       fTau0                  = right.fTau0;
                                                   >> 131       fTaul                  = right.fTaul;
                                                   >> 132       fBetheBlochLow         = right.fBetheBlochLow;
                                                   >> 133       fAlow                  = right.fAlow;
                                                   >> 134       fBlow                  = right.fBlow;
                                                   >> 135       fClow                  = right.fClow;
                                                   >> 136       fMeanExcitationEnergy  = right.fMeanExcitationEnergy;
                                                   >> 137       if (fShellCorrectionVector) delete [] fShellCorrectionVector;             
                                                   >> 138       fShellCorrectionVector = new G4double[3];            
                                                   >> 139       fShellCorrectionVector[0] = right.fShellCorrectionVector[0];
                                                   >> 140       fShellCorrectionVector[1] = right.fShellCorrectionVector[1];
                                                   >> 141       fShellCorrectionVector[2] = right.fShellCorrectionVector[2];      
                                                   >> 142      } 
                                                   >> 143   return *this;
125 }                                                 144 }
126                                                   145 
127 //....oooOO0OOooo........oooOO0OOooo........oo    146 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
128                                                   147 
129 G4IonisParamElm::~G4IonisParamElm() { delete[] << 148 G4int G4IonisParamElm::operator==(const G4IonisParamElm& right) const
                                                   >> 149 {
                                                   >> 150   return (this == (G4IonisParamElm *) &right);
                                                   >> 151 }
                                                   >> 152 
                                                   >> 153 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
                                                   >> 154 
                                                   >> 155 G4int G4IonisParamElm::operator!=(const G4IonisParamElm& right) const
                                                   >> 156 {
                                                   >> 157   return (this != (G4IonisParamElm *) &right);
                                                   >> 158 }
                                                   >> 159 
                                                   >> 160 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo.... ....oooOO0OOooo....
130                                                   161