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 | // By JPW, working, but to be cleaned up. @@@ |
---|
27 | // 22 Dec 2006 - DHW added isotope dependence |
---|
28 | // G.Folger, 25-Nov-2009: extend to 100TeV, using a constant above 20GeV |
---|
29 | // |
---|
30 | |
---|
31 | #include "G4NeutronInelasticCrossSection.hh" |
---|
32 | #include "G4HadTmpUtil.hh" |
---|
33 | #include "globals.hh" |
---|
34 | |
---|
35 | G4double G4NeutronInelasticCrossSection:: |
---|
36 | GetCrossSection(const G4DynamicParticle* aPart, |
---|
37 | const G4Element* anEle, G4double /*aTemperature*/) |
---|
38 | { |
---|
39 | G4int nIso = anEle->GetNumberOfIsotopes(); |
---|
40 | G4double KE = aPart->GetKineticEnergy(); |
---|
41 | G4double cross_section = 0; |
---|
42 | |
---|
43 | if (nIso) { |
---|
44 | G4double psig; |
---|
45 | G4IsotopeVector* isoVector = anEle->GetIsotopeVector(); |
---|
46 | G4double* abundVector = anEle->GetRelativeAbundanceVector(); |
---|
47 | G4int ZZ; |
---|
48 | G4int AA; |
---|
49 | |
---|
50 | for (G4int i = 0; i < nIso; i++) { |
---|
51 | ZZ = (*isoVector)[i]->GetZ(); |
---|
52 | AA = (*isoVector)[i]->GetN(); |
---|
53 | psig = GetCrossSection(KE, AA, ZZ); |
---|
54 | cross_section += psig*abundVector[i]; |
---|
55 | } |
---|
56 | |
---|
57 | } else { |
---|
58 | G4int ZZ = G4lrint(anEle->GetZ()); |
---|
59 | G4int AA = G4lrint(anEle->GetN()); |
---|
60 | cross_section = GetCrossSection(KE, AA, ZZ); |
---|
61 | } |
---|
62 | |
---|
63 | return cross_section; |
---|
64 | } |
---|
65 | |
---|
66 | |
---|
67 | G4double G4NeutronInelasticCrossSection:: |
---|
68 | GetCrossSection(G4double anEnergy, G4int AA, G4int ZZ) |
---|
69 | { |
---|
70 | G4double atomicNumber = G4double(AA); |
---|
71 | G4double nOfProtons = G4double(ZZ); |
---|
72 | |
---|
73 | if (anEnergy > 19.9*GeV ) |
---|
74 | { // constant cross section above ~20GeV. |
---|
75 | return GetCrossSection(19.8*GeV, AA, ZZ); |
---|
76 | } |
---|
77 | G4double kineticEnergy = std::log10(DBL_MIN/MeV); |
---|
78 | if (anEnergy > DBL_MIN/MeV) kineticEnergy = std::log10(anEnergy/MeV); |
---|
79 | G4double nOfNeutrons = atomicNumber-nOfProtons; |
---|
80 | const G4double p1=1.3773; |
---|
81 | const G4double p2=1.+10./atomicNumber-0.0006*atomicNumber; |
---|
82 | const G4double p3=0.6+13./atomicNumber-0.0005*atomicNumber; |
---|
83 | const G4double p4=7.2449-0.018242*atomicNumber; |
---|
84 | const G4double p5=1.64-1.8/atomicNumber-0.0005*atomicNumber; |
---|
85 | const G4double p6=1.+200./atomicNumber+0.02*atomicNumber; |
---|
86 | const G4double p7=(atomicNumber-70.)*(atomicNumber-200.)/11000.; |
---|
87 | |
---|
88 | G4double logN = 1.0; |
---|
89 | if (nOfNeutrons > 1.5) logN = std::log(nOfNeutrons); |
---|
90 | G4double part1 = pi*(p1*p1)*logN; |
---|
91 | G4double part2 = 1.+ std::pow(atomicNumber, 1./3.) |
---|
92 | - p2*(1.-1./std::pow(atomicNumber, 1./3.)); |
---|
93 | |
---|
94 | G4double firstexp = -p4*(kineticEnergy-p5); |
---|
95 | G4double first=1.+std::exp(firstexp); |
---|
96 | G4double corr = 1.+p3*(1.-1./first); |
---|
97 | |
---|
98 | G4double secondexp = -p6*(kineticEnergy-p7); |
---|
99 | G4double second=1.+std::exp(secondexp); |
---|
100 | G4double corr2 =1./second; |
---|
101 | |
---|
102 | G4double xsec = corr*corr2*part1*part2*10.*millibarn; |
---|
103 | return xsec; |
---|
104 | } |
---|