Geant4 Cross Reference

Cross-Referencing   Geant4
Geant4/processes/hadronic/models/binary_cascade/src/G4RKFieldIntegrator.cc

Version: [ ReleaseNotes ] [ 1.0 ] [ 1.1 ] [ 2.0 ] [ 3.0 ] [ 3.1 ] [ 3.2 ] [ 4.0 ] [ 4.0.p1 ] [ 4.0.p2 ] [ 4.1 ] [ 4.1.p1 ] [ 5.0 ] [ 5.0.p1 ] [ 5.1 ] [ 5.1.p1 ] [ 5.2 ] [ 5.2.p1 ] [ 5.2.p2 ] [ 6.0 ] [ 6.0.p1 ] [ 6.1 ] [ 6.2 ] [ 6.2.p1 ] [ 6.2.p2 ] [ 7.0 ] [ 7.0.p1 ] [ 7.1 ] [ 7.1.p1 ] [ 8.0 ] [ 8.0.p1 ] [ 8.1 ] [ 8.1.p1 ] [ 8.1.p2 ] [ 8.2 ] [ 8.2.p1 ] [ 8.3 ] [ 8.3.p1 ] [ 8.3.p2 ] [ 9.0 ] [ 9.0.p1 ] [ 9.0.p2 ] [ 9.1 ] [ 9.1.p1 ] [ 9.1.p2 ] [ 9.1.p3 ] [ 9.2 ] [ 9.2.p1 ] [ 9.2.p2 ] [ 9.2.p3 ] [ 9.2.p4 ] [ 9.3 ] [ 9.3.p1 ] [ 9.3.p2 ] [ 9.4 ] [ 9.4.p1 ] [ 9.4.p2 ] [ 9.4.p3 ] [ 9.4.p4 ] [ 9.5 ] [ 9.5.p1 ] [ 9.5.p2 ] [ 9.6 ] [ 9.6.p1 ] [ 9.6.p2 ] [ 9.6.p3 ] [ 9.6.p4 ] [ 10.0 ] [ 10.0.p1 ] [ 10.0.p2 ] [ 10.0.p3 ] [ 10.0.p4 ] [ 10.1 ] [ 10.1.p1 ] [ 10.1.p2 ] [ 10.1.p3 ] [ 10.2 ] [ 10.2.p1 ] [ 10.2.p2 ] [ 10.2.p3 ] [ 10.3 ] [ 10.3.p1 ] [ 10.3.p2 ] [ 10.3.p3 ] [ 10.4 ] [ 10.4.p1 ] [ 10.4.p2 ] [ 10.4.p3 ] [ 10.5 ] [ 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 /processes/hadronic/models/binary_cascade/src/G4RKFieldIntegrator.cc (Version 11.3.0) and /processes/hadronic/models/binary_cascade/src/G4RKFieldIntegrator.cc (Version 10.1.p2)


  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 // G4RKFieldIntegrator                             26 // G4RKFieldIntegrator
 27 #include "G4RKFieldIntegrator.hh"                  27 #include "G4RKFieldIntegrator.hh"
 28 #include "G4PhysicalConstants.hh"                  28 #include "G4PhysicalConstants.hh"
 29 #include "G4SystemOfUnits.hh"                      29 #include "G4SystemOfUnits.hh"
 30 #include "G4NucleiProperties.hh"                   30 #include "G4NucleiProperties.hh"
 31 #include "G4FermiMomentum.hh"                      31 #include "G4FermiMomentum.hh"
 32 #include "G4NuclearFermiDensity.hh"                32 #include "G4NuclearFermiDensity.hh"
 33 #include "G4NuclearShellModelDensity.hh"           33 #include "G4NuclearShellModelDensity.hh"
 34 #include "G4Nucleon.hh"                            34 #include "G4Nucleon.hh"
 35 #include "G4Exp.hh"                            << 
 36 #include "G4Log.hh"                            << 
 37 #include "G4Pow.hh"                            << 
 38                                                    35 
 39 // Class G4RKFieldIntegrator                       36 // Class G4RKFieldIntegrator
 40 //********************************************     37 //*************************************************************************************************************************************
 41                                                    38 
 42 // only theActive are propagated, nothing else     39 // only theActive are propagated, nothing else
 43 // only theSpectators define the field, nothin     40 // only theSpectators define the field, nothing else
 44                                                    41 
 45 void G4RKFieldIntegrator::Transport(G4KineticT     42 void G4RKFieldIntegrator::Transport(G4KineticTrackVector &theActive, const G4KineticTrackVector &theSpectators, G4double theTimeStep)
 46 {                                                  43 {
 47    (void)theActive;                                44    (void)theActive;
 48    (void)theSpectators;                            45    (void)theSpectators;
 49    (void)theTimeStep;                              46    (void)theTimeStep;
 50 }                                                  47 }
 51                                                    48 
 52                                                    49 
 53 G4double G4RKFieldIntegrator::CalculateTotalEn     50 G4double G4RKFieldIntegrator::CalculateTotalEnergy(const G4KineticTrackVector& Barions)
 54 {                                                  51 {
 55    const G4double Alpha  =  0.25/fermi/fermi;      52    const G4double Alpha  =  0.25/fermi/fermi;
 56    const G4double t1     = -7264.04*fermi*ferm     53    const G4double t1     = -7264.04*fermi*fermi*fermi;
 57    const G4double tGamma =  87.65*fermi*fermi*     54    const G4double tGamma =  87.65*fermi*fermi*fermi*fermi*fermi*fermi;
 58 //   const G4double Gamma  =  1.676;               55 //   const G4double Gamma  =  1.676;
 59    const G4double Vo     = -0.498*fermi;           56    const G4double Vo     = -0.498*fermi;
 60    const G4double GammaY =  1.4*fermi;             57    const G4double GammaY =  1.4*fermi;
 61                                                    58 
 62    G4double Etot = 0;                              59    G4double Etot = 0;
 63    G4int nBarion = (G4int)Barions.size();      <<  60    G4int nBarion = Barions.size();
 64    for(G4int c1 = 0; c1 < nBarion; ++c1)       <<  61    for(G4int c1 = 0; c1 < nBarion; c1++)
 65       {                                            62       {
 66       G4KineticTrack* p1 = Barions.operator[](     63       G4KineticTrack* p1 = Barions.operator[](c1);
 67    // Ekin                                         64    // Ekin
 68       Etot += p1->Get4Momentum().e();              65       Etot += p1->Get4Momentum().e();
 69       for(G4int c2 = c1 + 1; c2 < nBarion; ++c <<  66       for(G4int c2 = c1 + 1; c2 < nBarion; c2++)
 70          {                                         67          {
 71          G4KineticTrack* p2 = Barions.operator     68          G4KineticTrack* p2 = Barions.operator[](c2);
 72          G4double r12 = (p1->GetPosition() - p     69          G4double r12 = (p1->GetPosition() - p2->GetPosition()).mag()*fermi;
 73                                                    70 
 74          //  Esk2                                  71          //  Esk2
 75          Etot += t1*G4Pow::GetInstance()->A23( <<  72          Etot += t1*std::pow(Alpha/pi, 3/2)*std::exp(-Alpha*r12*r12);
 76                                                    73 
 77          // Eyuk                                   74          // Eyuk
 78          Etot += Vo*0.5/r12*G4Exp(1/(4*Alpha*G <<  75          Etot += Vo*0.5/r12*std::exp(1/(4*Alpha*GammaY*GammaY))*
 79             (G4Exp(-r12/GammaY)*(1 - Erf(0.5/G <<  76             (std::exp(-r12/GammaY)*(1 - Erf(0.5/GammaY/std::sqrt(Alpha) - std::sqrt(Alpha)*r12)) -
 80              G4Exp( r12/GammaY)*(1 - Erf(0.5/G <<  77              std::exp( r12/GammaY)*(1 - Erf(0.5/GammaY/std::sqrt(Alpha) + std::sqrt(Alpha)*r12)));
 81                                                    78 
 82          // Ecoul                                  79          // Ecoul
 83          Etot += 1.44*p1->GetDefinition()->Get     80          Etot += 1.44*p1->GetDefinition()->GetPDGCharge()*p2->GetDefinition()->GetPDGCharge()/r12*Erf(std::sqrt(Alpha)*r12);
 84                                                    81 
 85          // Epaul                                  82          // Epaul
 86          Etot = 0;                                 83          Etot = 0;
 87                                                    84 
 88          for(G4int c3 = c2 + 1; c3 < nBarion;      85          for(G4int c3 = c2 + 1; c3 < nBarion; c3++)
 89             {                                      86             {
 90             G4KineticTrack* p3 = Barions.opera     87             G4KineticTrack* p3 = Barions.operator[](c3);
 91             G4double r13 = (p1->GetPosition()      88             G4double r13 = (p1->GetPosition() - p3->GetPosition()).mag()*fermi;
 92                                                    89 
 93             // Esk3                                90             // Esk3
 94             Etot  = tGamma*G4Pow::GetInstance( <<  91             Etot  = tGamma*std::pow(4*Alpha*Alpha/3/pi/pi, 1.5)*std::exp(-Alpha*(r12*r12 + r13*r13));
 95             }                                      92             }
 96          }                                         93          }
 97       }                                            94       }
 98    return Etot;                                    95    return Etot;
 99 }                                                  96 }
100                                                    97 
101 //********************************************     98 //************************************************************************************************
102 // originated from the Numerical recipes error     99 // originated from the Numerical recipes error function
103 G4double G4RKFieldIntegrator::Erf(G4double X)     100 G4double G4RKFieldIntegrator::Erf(G4double X)
104 {                                                 101 {
105    const G4double Z1 = 1;                         102    const G4double Z1 = 1;
106    const G4double HF = Z1/2;                      103    const G4double HF = Z1/2;
107    const G4double C1 = 0.56418958;                104    const G4double C1 = 0.56418958;
108                                                   105 
109    const G4double P10 = +3.6767877;               106    const G4double P10 = +3.6767877;
110    const G4double Q10 = +3.2584593;               107    const G4double Q10 = +3.2584593;
111    const G4double P11 = -9.7970465E-2;            108    const G4double P11 = -9.7970465E-2;
112                                                   109 
113 //   static G4ThreadLocal G4double P2[5] = { 7    110 //   static G4ThreadLocal G4double P2[5] = { 7.3738883, 6.8650185,  3.0317993, 0.56316962, 4.3187787e-5 };
114 //   static G4ThreadLocal G4double Q2[5] = { 7    111 //   static G4ThreadLocal G4double Q2[5] = { 7.3739609, 15.184908, 12.79553,   5.3542168,  1. };
115    const G4double P2[5] = { 7.3738883, 6.86501    112    const G4double P2[5] = { 7.3738883, 6.8650185,  3.0317993, 0.56316962, 4.3187787e-5 };
116    const G4double Q2[5] = { 7.3739609, 15.1849    113    const G4double Q2[5] = { 7.3739609, 15.184908, 12.79553,   5.3542168,  1. };
117                                                   114 
118    const G4double P30 = -1.2436854E-1;            115    const G4double P30 = -1.2436854E-1;
119    const G4double Q30 = +4.4091706E-1;            116    const G4double Q30 = +4.4091706E-1;
120    const G4double P31 = -9.6821036E-2;            117    const G4double P31 = -9.6821036E-2;
121                                                   118 
122    G4double V = std::abs(X);                      119    G4double V = std::abs(X);
123    G4double H;                                    120    G4double H;
124    G4double Y;                                    121    G4double Y;
125    G4int c1;                                      122    G4int c1;
126                                                   123 
127    if(V < HF)                                     124    if(V < HF)
128       {                                           125       {
129       Y = V*V;                                    126       Y = V*V;
130       H = X*(P10 + P11*Y)/(Q10+Y);                127       H = X*(P10 + P11*Y)/(Q10+Y);
131       }                                           128       }
132    else                                           129    else
133       {                                           130       {
134       if(V < 4)                                   131       if(V < 4)
135          {                                        132          {
136    G4double AP = P2[4];                           133    G4double AP = P2[4];
137    G4double AQ = Q2[4];                           134    G4double AQ = Q2[4];
138    for(c1 = 3; c1 >= 0; c1--)                     135    for(c1 = 3; c1 >= 0; c1--)
139             {                                     136             {
140             AP = P2[c1] + V*AP;                   137             AP = P2[c1] + V*AP;
141             AQ = Q2[c1] + V*AQ;                   138             AQ = Q2[c1] + V*AQ;
142             }                                     139             }
143    H = 1 - G4Exp(-V*V)*AP/AQ;                  << 140    H = 1 - std::exp(-V*V)*AP/AQ;
144    }                                              141    }
145       else                                        142       else
146         {                                         143         {
147         Y = 1./V*V;                               144         Y = 1./V*V;
148         H = 1 - G4Exp(-V*V)*(C1+Y*(P30 + P31*Y << 145         H = 1 - std::exp(-V*V)*(C1+Y*(P30 + P31*Y)/(Q30 + Y))/V;
149         }                                         146         }
150      if (X < 0)                                   147      if (X < 0)
151         H = -H;                                   148         H = -H;
152      }                                            149      }
153    return H;                                      150    return H;
154 }                                                 151 }
155                                                   152 
156 //********************************************    153 //************************************************************************************************
157 //This is a QMD version to calculate excitatio    154 //This is a QMD version to calculate excitation energy of a fragment,
158 //which consists from G4KTV &the Particles        155 //which consists from G4KTV &the Particles
159 /*                                                156 /*
160 G4double G4RKFieldIntegrator::GetExcitationEne    157 G4double G4RKFieldIntegrator::GetExcitationEnergy(const G4KineticTrackVector &theParticles)
161 {                                                 158 {
162    // Excitation energy of a fragment consisti    159    // Excitation energy of a fragment consisting from A nucleons and Z protons
163    // is Etot - Z*Mp - (A - Z)*Mn - B(A, Z), w    160    // is Etot - Z*Mp - (A - Z)*Mn - B(A, Z), where B(A,Z) is the binding energy of fragment
164    //  and Mp, Mn are proton and neutron mass,    161    //  and Mp, Mn are proton and neutron mass, respectively.
165    G4int NZ = 0;                                  162    G4int NZ = 0;
166    G4int NA = 0;                                  163    G4int NA = 0;
167    G4double Etot = CalculateTotalEnergy(thePar    164    G4double Etot = CalculateTotalEnergy(theParticles);
168    for(G4int cParticle = 0; cParticle < thePar    165    for(G4int cParticle = 0; cParticle < theParticles.length(); cParticle++)
169       {                                           166       {
170       G4KineticTrack* pKineticTrack = theParti    167       G4KineticTrack* pKineticTrack = theParticles.at(cParticle);
171       G4int Encoding =  std::abs(pKineticTrack    168       G4int Encoding =  std::abs(pKineticTrack->GetDefinition()->GetPDGEncoding());
172       if (Encoding == 2212)                       169       if (Encoding == 2212)
173           NZ++, NA++;                             170           NZ++, NA++;
174       if (Encoding == 2112)                       171       if (Encoding == 2112)
175           NA++;                                   172           NA++;
176       Etot -= pKineticTrack->GetDefinition()->    173       Etot -= pKineticTrack->GetDefinition()->GetPDGMass();
177       }                                           174       }
178    return Etot - G4NucleiProperties::GetBindin    175    return Etot - G4NucleiProperties::GetBindingEnergy(NZ, NA);
179 }                                                 176 }
180 */                                                177 */
181                                                   178 
182 //********************************************    179 //*************************************************************************************************************************************
183 //This is a simplified method to get excitatio    180 //This is a simplified method to get excitation energy of a residual
184 // nucleus with nHitNucleons.                     181 // nucleus with nHitNucleons.
185 G4double G4RKFieldIntegrator::GetExcitationEne    182 G4double G4RKFieldIntegrator::GetExcitationEnergy(G4int nHitNucleons, const G4KineticTrackVector &)
186 {                                                 183 {
187    const G4double MeanE = 50;                     184    const G4double MeanE = 50;
188    G4double Sum = 0;                              185    G4double Sum = 0;
189    for(G4int c1 = 0; c1 < nHitNucleons; ++c1)  << 186    for(G4int c1 = 0; c1 < nHitNucleons; c1++)
190        {                                          187        {
191        Sum += -MeanE*G4Log(G4UniformRand());   << 188        Sum += -MeanE*std::log(G4UniformRand());
192        }                                          189        }
193    return Sum;                                    190    return Sum;
194 }                                                 191 }
195 //********************************************    192 //*************************************************************************************************************************************
196                                                   193 
197 /*                                                194 /*
198 //This is free propagation of particles for CA    195 //This is free propagation of particles for CASCADE mode. Target nucleons should be frozen
199 void G4RKFieldIntegrator::Integrate(G4KineticT    196 void G4RKFieldIntegrator::Integrate(G4KineticTrackVector& theParticles)
200    {                                              197    {
201    for(G4int cParticle = 0; cParticle < thePar << 198    for(G4int cParticle = 0; cParticle < theParticles.length(); cParticle++)
202       {                                           199       {
203       G4KineticTrack* pKineticTrack = theParti    200       G4KineticTrack* pKineticTrack = theParticles.at(cParticle);
204       pKineticTrack->SetPosition(pKineticTrack    201       pKineticTrack->SetPosition(pKineticTrack->GetPosition() + theTimeStep*pKineticTrack->Get4Momentum().boostVector());
205       }                                           202       }
206    }                                              203    }
207 */                                                204 */
208 //********************************************    205 //*************************************************************************************************************************************
209                                                   206 
210 void G4RKFieldIntegrator::Integrate(const G4Ki    207 void G4RKFieldIntegrator::Integrate(const G4KineticTrackVector& theBarions, G4double theTimeStep)
211 {                                                 208 {
212    for(std::size_t cParticle = 0; cParticle <  << 209    for(size_t cParticle = 0; cParticle < theBarions.size(); cParticle++)
213       {                                           210       {
214       G4KineticTrack* pKineticTrack = theBario    211       G4KineticTrack* pKineticTrack = theBarions[cParticle];
215       pKineticTrack->SetPosition(pKineticTrack    212       pKineticTrack->SetPosition(pKineticTrack->GetPosition() + theTimeStep*pKineticTrack->Get4Momentum().boostVector());
216       }                                           213       }
217 }                                                 214 }
218                                                   215 
219 //********************************************    216 //*************************************************************************************************************************************
220                                                   217 
221 // constant to calculate theCoulomb barrier       218 // constant to calculate theCoulomb barrier
222 const G4double G4RKFieldIntegrator::coulomb =     219 const G4double G4RKFieldIntegrator::coulomb = 1.44 / 1.14 * MeV;
223                                                   220 
224 // kaon's potential constant (real part only)     221 // kaon's potential constant (real part only)
225 // 0.35 + i0.82 or 0.63 + i0.89 fermi             222 // 0.35 + i0.82 or 0.63 + i0.89 fermi
226 const G4double G4RKFieldIntegrator::a_kaon = 0    223 const G4double G4RKFieldIntegrator::a_kaon = 0.35;
227                                                   224 
228 // pion's potential constant (real part only)     225 // pion's potential constant (real part only)
229 //!! for pions it has todiffer from kaons         226 //!! for pions it has todiffer from kaons
230 // 0.35 + i0.82 or 0.63 + i0.89 fermi             227 // 0.35 + i0.82 or 0.63 + i0.89 fermi
231 const G4double G4RKFieldIntegrator::a_pion = 0    228 const G4double G4RKFieldIntegrator::a_pion = 0.35;
232                                                   229 
233 // antiproton's potential constant (real part     230 // antiproton's potential constant (real part only)
234 // 1.53 + i2.50 fermi                             231 // 1.53 + i2.50 fermi
235 const G4double G4RKFieldIntegrator::a_antiprot    232 const G4double G4RKFieldIntegrator::a_antiproton = 1.53;
236                                                   233 
237 // methods for calculating potentials for diff    234 // methods for calculating potentials for different types of particles
238 // aPosition is relative to the nucleus center    235 // aPosition is relative to the nucleus center
239 G4double G4RKFieldIntegrator::GetNeutronPotent    236 G4double G4RKFieldIntegrator::GetNeutronPotential(G4double )
240 {                                                 237 {
241    /*                                             238    /*
242    const G4double Mn  = 939.56563 * MeV; // ma    239    const G4double Mn  = 939.56563 * MeV; // mass of nuetron
243                                                   240 
244    G4VNuclearDensity *theDencity;                 241    G4VNuclearDensity *theDencity;
245    if(theA < 17) theDencity = new G4NuclearShe    242    if(theA < 17) theDencity = new G4NuclearShellModelDensity(theA, theZ);
246    else          theDencity = new G4NuclearFer    243    else          theDencity = new G4NuclearFermiDensity(theA, theZ);
247                                                   244 
248    // GetDencity() accepts only G4ThreeVector     245    // GetDencity() accepts only G4ThreeVector so build it:
249    G4ThreeVector aPosition(0.0, 0.0, radius);     246    G4ThreeVector aPosition(0.0, 0.0, radius);
250    G4double density = theDencity->GetDensity(a    247    G4double density = theDencity->GetDensity(aPosition);
251    delete theDencity;                             248    delete theDencity;
252                                                   249 
253    G4FermiMomentum *fm = new G4FermiMomentum()    250    G4FermiMomentum *fm = new G4FermiMomentum();
254    fm->Init(theA, theZ);                          251    fm->Init(theA, theZ);
255    G4double fermiMomentum = fm->GetFermiMoment    252    G4double fermiMomentum = fm->GetFermiMomentum(density);
256    delete fm;                                     253    delete fm;
257                                                   254 
258    return sqr(fermiMomentum)/(2 * Mn)             255    return sqr(fermiMomentum)/(2 * Mn)
259       + G4CreateNucleus::GetBindingEnergy(theZ    256       + G4CreateNucleus::GetBindingEnergy(theZ, theA)/theA;
260       //+ G4NucleiProperties::GetBindingEnergy    257       //+ G4NucleiProperties::GetBindingEnergy(theZ, theA)/theA;
261    */                                             258    */
262                                                   259 
263    return 0.0;                                    260    return 0.0;
264 }                                                 261 }
265                                                   262 
266 G4double G4RKFieldIntegrator::GetProtonPotenti    263 G4double G4RKFieldIntegrator::GetProtonPotential(G4double )
267 {                                                 264 {
268    /*                                             265    /*
269    // calculate Coulomb barrier value             266    // calculate Coulomb barrier value
270    G4double theCoulombBarrier = coulomb * theZ << 267    G4double theCoulombBarrier = coulomb * theZ/(1. + std::pow(theA, 1./3.));
271    const G4double Mp  = 938.27231 * MeV; // ma    268    const G4double Mp  = 938.27231 * MeV; // mass of proton
272                                                   269 
273    G4VNuclearDensity *theDencity;                 270    G4VNuclearDensity *theDencity;
274    if(theA < 17) theDencity = new G4NuclearShe    271    if(theA < 17) theDencity = new G4NuclearShellModelDensity(theA, theZ);
275    else          theDencity = new G4NuclearFer    272    else          theDencity = new G4NuclearFermiDensity(theA, theZ);
276                                                   273 
277    // GetDencity() accepts only G4ThreeVector     274    // GetDencity() accepts only G4ThreeVector so build it:
278    G4ThreeVector aPosition(0.0, 0.0, radius);     275    G4ThreeVector aPosition(0.0, 0.0, radius);
279    G4double density = theDencity->GetDensity(a    276    G4double density = theDencity->GetDensity(aPosition);
280    delete theDencity;                             277    delete theDencity;
281                                                   278 
282    G4FermiMomentum *fm = new G4FermiMomentum()    279    G4FermiMomentum *fm = new G4FermiMomentum();
283    fm->Init(theA, theZ);                          280    fm->Init(theA, theZ);
284    G4double fermiMomentum = fm->GetFermiMoment    281    G4double fermiMomentum = fm->GetFermiMomentum(density);
285    delete fm;                                     282    delete fm;
286                                                   283 
287    return sqr(fermiMomentum)/ (2 * Mp)            284    return sqr(fermiMomentum)/ (2 * Mp)
288       + G4CreateNucleus::GetBindingEnergy(theZ    285       + G4CreateNucleus::GetBindingEnergy(theZ, theA)/theA;
289       //+ G4NucleiProperties::GetBindingEnergy    286       //+ G4NucleiProperties::GetBindingEnergy(theZ, theA)/theA
290       + theCoulombBarrier;                        287       + theCoulombBarrier;
291    */                                             288    */
292                                                   289 
293    return 0.0;                                    290    return 0.0;
294 }                                                 291 }
295                                                   292 
296 G4double G4RKFieldIntegrator::GetAntiprotonPot    293 G4double G4RKFieldIntegrator::GetAntiprotonPotential(G4double )
297 {                                                 294 {
298    /*                                             295    /*
299    //G4double theM = G4NucleiProperties::GetAt    296    //G4double theM = G4NucleiProperties::GetAtomicMass(theA, theZ);
300    G4double theM = theZ * G4Proton::Proton()->    297    G4double theM = theZ * G4Proton::Proton()->GetPDGMass()
301       + (theA - theZ) * G4Neutron::Neutron()->    298       + (theA - theZ) * G4Neutron::Neutron()->GetPDGMass()
302       + G4CreateNucleus::GetBindingEnergy(theZ    299       + G4CreateNucleus::GetBindingEnergy(theZ, theA);
303                                                   300 
304    const G4double Mp  = 938.27231 * MeV; // ma    301    const G4double Mp  = 938.27231 * MeV; // mass of proton
305    G4double mu = (theM * Mp)/(theM + Mp);         302    G4double mu = (theM * Mp)/(theM + Mp);
306                                                   303 
307    // antiproton's potential coefficient          304    // antiproton's potential coefficient
308    //   V = coeff_antiproton * nucleus_density    305    //   V = coeff_antiproton * nucleus_density
309    G4double coeff_antiproton = -2.*pi/mu * (1.    306    G4double coeff_antiproton = -2.*pi/mu * (1. + Mp) * a_antiproton;
310                                                   307 
311    G4VNuclearDensity *theDencity;                 308    G4VNuclearDensity *theDencity;
312    if(theA < 17) theDencity = new G4NuclearShe    309    if(theA < 17) theDencity = new G4NuclearShellModelDensity(theA, theZ);
313    else          theDencity = new G4NuclearFer    310    else          theDencity = new G4NuclearFermiDensity(theA, theZ);
314                                                   311 
315    // GetDencity() accepts only G4ThreeVector     312    // GetDencity() accepts only G4ThreeVector so build it:
316    G4ThreeVector aPosition(0.0, 0.0, radius);     313    G4ThreeVector aPosition(0.0, 0.0, radius);
317    G4double density = theDencity->GetDensity(a    314    G4double density = theDencity->GetDensity(aPosition);
318    delete theDencity;                             315    delete theDencity;
319                                                   316 
320    return coeff_antiproton * density;             317    return coeff_antiproton * density;
321    */                                             318    */
322                                                   319 
323    return 0.0;                                    320    return 0.0;
324 }                                                 321 }
325                                                   322 
326 G4double G4RKFieldIntegrator::GetKaonPotential    323 G4double G4RKFieldIntegrator::GetKaonPotential(G4double )
327 {                                                 324 {
328    /*                                             325    /*
329    //G4double theM = G4NucleiProperties::GetAt    326    //G4double theM = G4NucleiProperties::GetAtomicMass(theA, theZ);
330    G4double theM = theZ * G4Proton::Proton()->    327    G4double theM = theZ * G4Proton::Proton()->GetPDGMass()
331       + (theA - theZ) * G4Neutron::Neutron()->    328       + (theA - theZ) * G4Neutron::Neutron()->GetPDGMass()
332       + G4CreateNucleus::GetBindingEnergy(theZ    329       + G4CreateNucleus::GetBindingEnergy(theZ, theA);
333                                                   330 
334    const G4double Mk  = 496. * MeV;      // ma    331    const G4double Mk  = 496. * MeV;      // mass of "kaon"
335    G4double mu = (theM * Mk)/(theM + Mk);         332    G4double mu = (theM * Mk)/(theM + Mk);
336                                                   333 
337    // kaon's potential coefficient                334    // kaon's potential coefficient
338    //   V = coeff_kaon * nucleus_density          335    //   V = coeff_kaon * nucleus_density
339    G4double coeff_kaon = -2.*pi/mu * (1. + Mk/    336    G4double coeff_kaon = -2.*pi/mu * (1. + Mk/theM) * a_kaon;
340                                                   337 
341    G4VNuclearDensity *theDencity;                 338    G4VNuclearDensity *theDencity;
342    if(theA < 17) theDencity = new G4NuclearShe    339    if(theA < 17) theDencity = new G4NuclearShellModelDensity(theA, theZ);
343    else          theDencity = new G4NuclearFer    340    else          theDencity = new G4NuclearFermiDensity(theA, theZ);
344                                                   341 
345    // GetDencity() accepts only G4ThreeVector     342    // GetDencity() accepts only G4ThreeVector so build it:
346    G4ThreeVector aPosition(0.0, 0.0, radius);     343    G4ThreeVector aPosition(0.0, 0.0, radius);
347    G4double density = theDencity->GetDensity(a    344    G4double density = theDencity->GetDensity(aPosition);
348    delete theDencity;                             345    delete theDencity;
349                                                   346 
350    return coeff_kaon * density;                   347    return coeff_kaon * density;
351    */                                             348    */
352                                                   349 
353    return 0.0;                                    350    return 0.0;
354 }                                                 351 }
355                                                   352 
356 G4double G4RKFieldIntegrator::GetPionPotential    353 G4double G4RKFieldIntegrator::GetPionPotential(G4double )
357 {                                                 354 {
358    /*                                             355    /*
359    //G4double theM = G4NucleiProperties::GetAt    356    //G4double theM = G4NucleiProperties::GetAtomicMass(theA, theZ);
360    G4double theM = theZ * G4Proton::Proton()->    357    G4double theM = theZ * G4Proton::Proton()->GetPDGMass()
361       + (theA - theZ) * G4Neutron::Neutron()->    358       + (theA - theZ) * G4Neutron::Neutron()->GetPDGMass()
362       + G4CreateNucleus::GetBindingEnergy(theZ    359       + G4CreateNucleus::GetBindingEnergy(theZ, theA);
363                                                   360 
364    const G4double Mpi = 139. * MeV;      // ma    361    const G4double Mpi = 139. * MeV;      // mass of "pion"
365    G4double mu = (theM * Mpi)/(theM + Mpi);       362    G4double mu = (theM * Mpi)/(theM + Mpi);
366                                                   363 
367    // pion's potential coefficient                364    // pion's potential coefficient
368    //   V = coeff_pion * nucleus_density          365    //   V = coeff_pion * nucleus_density
369    G4double coeff_pion = -2.*pi/mu * (1. + Mpi    366    G4double coeff_pion = -2.*pi/mu * (1. + Mpi) * a_pion;
370                                                   367 
371    G4VNuclearDensity *theDencity;                 368    G4VNuclearDensity *theDencity;
372    if(theA < 17) theDencity = new G4NuclearShe    369    if(theA < 17) theDencity = new G4NuclearShellModelDensity(theA, theZ);
373    else          theDencity = new G4NuclearFer    370    else          theDencity = new G4NuclearFermiDensity(theA, theZ);
374                                                   371 
375    // GetDencity() accepts only G4ThreeVector     372    // GetDencity() accepts only G4ThreeVector so build it:
376    G4ThreeVector aPosition(0.0, 0.0, radius);     373    G4ThreeVector aPosition(0.0, 0.0, radius);
377    G4double density = theDencity->GetDensity(a    374    G4double density = theDencity->GetDensity(aPosition);
378    delete theDencity;                             375    delete theDencity;
379                                                   376 
380    return coeff_pion * density;                   377    return coeff_pion * density;
381    */                                             378    */
382                                                   379 
383    return 0.0;                                    380    return 0.0;
384 }                                                 381 }
385                                                   382