source: trunk/source/processes/electromagnetic/lowenergy/src/G4CrossSectionChargeTransferCH.cc @ 1347

Last change on this file since 1347 was 1347, checked in by garnier, 13 years ago

geant4 tag 9.4

  • Property svn:executable set to *
File size: 7.0 KB
Line 
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//
27// $Id: G4CrossSectionChargeTransferCH.cc,v 1.4 2009/06/10 13:32:36 mantero Exp $
28// GEANT4 tag $Name: geant4-09-04-ref-00 $
29//
30// Contact Author: Maria Grazia Pia (Maria.Grazia.Pia@cern.ch)
31//
32// Reference: TNS Geant4-DNA paper
33// Reference for implementation model: NIM. 155, pp. 145-156, 1978
34
35// History:
36// -----------
37// Date         Name              Modification
38// 28 Dec 2007  M.G. Pia          Created
39//
40// -------------------------------------------------------------------
41
42// Class description:
43// Total cross section for incident p charge transfer in hydrocarbons
44// Reference: K. Janev, J. G. Wang and T. Kato, NIFS-DATA (2001)
45//            http://www-cfadc.phy.ornl.gov/astro/ps/data/
46// http://www-pub.iaea.org/MTCD/publications/PDF/APID-VOL10.pdf
47//
48// The fit formula is:
49// ln(cross section)=\sum C_i T_i(x)
50//            x=[2ln(E)-ln(E_min)-ln(E_max)]/[ln(E_max)-ln(E_min)]
51//            T_1(x)=1
52//            T_2(x)=x
53//          T_n+2(x)=2T_n+1(x)-T_n(x)
54//       
55// Where cross section is given in 10^-16 cm2 and E is in keV,
56// E_min=1e-4 keV and E_max=1.e3 keV.
57
58// Further documentation available from http://www.ge.infn.it/geant4/
59
60// -------------------------------------------------------------------
61
62
63#include "G4CrossSectionChargeTransferCH.hh"
64#include "G4Track.hh"
65#include "G4DynamicParticle.hh"
66#include "G4Proton.hh"
67
68G4CrossSectionChargeTransferCH::G4CrossSectionChargeTransferCH()
69{
70  // Default energy limits (defined for protection against anomalous behaviour only)
71  name = "ChargeTransferCH";
72  lowEnergyLimit = 0.1 * eV;
73  highEnergyLimit = 1.0 * MeV;
74
75  std::vector<G4double> coeff;
76  G4String materialName;
77
78  // CH
79  materialName = "CH";
80  coeff.push_back(-1.060468);
81  coeff.push_back(-5.662572);
82  coeff.push_back(-4.376450);
83  coeff.push_back(-3.567226);
84  coeff.push_back(-1.433069);
85  coeff.push_back(-0.5789399);
86  coeff.push_back(-0.3523295); 
87  coeff.push_back(-0.09956988);   
88  coeff.push_back(0.01532751);
89  crossMap[materialName] = coeff;
90  coeff.clear();
91
92  // CH2
93  materialName = "CH2";
94  coeff.push_back(1.118652E-01); 
95  coeff.push_back(-5.216803E+00); 
96  coeff.push_back(-3.893841E+00); 
97  coeff.push_back(-2.756865E+00); 
98  coeff.push_back(-1.192043E+00); 
99  coeff.push_back(-5.200059E-01); 
100  coeff.push_back(-1.816781E-01);   
101  coeff.push_back(1.129866E-02); 
102  coeff.push_back(-3.658702E-03);
103  crossMap[materialName] = coeff;
104  coeff.clear();
105
106  // CH3
107  coeff.push_back(6.854778E-01); 
108  coeff.push_back(-5.810741E+00); 
109  coeff.push_back(-3.622136E+00); 
110  coeff.push_back(-2.179920E+00); 
111  coeff.push_back(-7.801006E-01); 
112  coeff.push_back(-2.421371E-02);   
113  coeff.push_back(2.762333E-01); 
114  coeff.push_back(2.288237E-01);   
115  coeff.push_back(6.164797E-02);
116  crossMap[materialName] = coeff;
117  coeff.clear();
118
119  // CH4
120  materialName = "CH4";
121  coeff.push_back(0.3901564);
122  coeff.push_back(-6.426675);
123  coeff.push_back(-3.706893);
124  coeff.push_back(-1.999034);
125  coeff.push_back(-0.5625439);
126  coeff.push_back(0.2279431);
127  coeff.push_back(0.3443980); 
128  coeff.push_back(0.1566892);   
129  coeff.push_back(-0.05398410);
130  coeff.push_back(-0.1822252); 
131  coeff.push_back(-0.1593352);   
132  coeff.push_back(-0.08826322);
133  crossMap[materialName] = coeff;
134  coeff.clear();
135
136  // C2H
137  materialName = "C2H";
138  coeff.push_back(-1.986507E+00);
139  coeff.push_back(-5.720283E+00);
140  coeff.push_back(-3.535139E+00);
141  coeff.push_back(-4.230273E+00);
142  coeff.push_back(-1.254502E+00);
143  coeff.push_back(-2.056898E-01);
144  coeff.push_back(-4.595756E-01);
145  coeff.push_back(-7.842824E-02);
146  coeff.push_back(3.002537E-02);
147  coeff.push_back(-5.626713E-02);
148  coeff.push_back(6.455583E-02);
149  crossMap[materialName] = coeff;
150  coeff.clear();
151
152  // C2H2
153  materialName = "C2H2";
154  coeff.push_back(2.513870E-01);
155  coeff.push_back(-5.812705E+00);
156  coeff.push_back(-3.338185E+00);
157  coeff.push_back(-3.071630E+00);
158  coeff.push_back(-1.433263E+00);
159  coeff.push_back(-3.583544E-01);
160  coeff.push_back(-1.456216E-01);
161  coeff.push_back(-7.391778E-03);
162  coeff.push_back(1.151712E-02);
163  crossMap[materialName] = coeff;
164  coeff.clear();
165  //
166
167}
168
169
170G4CrossSectionChargeTransferCH::~G4CrossSectionChargeTransferCH()
171{ }
172 
173
174G4double G4CrossSectionChargeTransferCH::CrossSection(const G4Track& track)
175{
176  G4double sigma = DBL_MIN;
177 
178  const G4DynamicParticle* particle = track.GetDynamicParticle();
179  G4double e = particle->GetKineticEnergy() / keV;
180
181  // Get the material the track is in
182  G4Material* material = track.GetMaterial();
183  G4String materialName;
184  materialName = material->GetName();
185
186  // Check whether cross section data are available for the current material
187
188  std::map<G4String,std::vector<G4double>,std::less<G4String> >::const_iterator pos;
189  pos = crossMap.find(materialName);
190  if (pos!= crossMap.end())
191    {
192      std::vector<G4double> coeff = (*pos).second;
193      G4double eMin = lowEnergyLimit / keV;
194      G4double eMax = highEnergyLimit / keV;
195      G4double scaleFactor = 1.e-16 * cm2;
196
197      if (e >=  eMin && e <= eMax)
198        {
199          G4double x = (2.*std::log(e) - std::log(eMin) - std::log(eMax)) / (std::log(eMax) - std::log(eMin));
200         
201          std::vector<G4double> t;
202          t.push_back(1.);
203          t.push_back(x);
204          G4double cross = t[0] * coeff[0] + t[1] * coeff[1];
205
206          G4int nCoeff = coeff.size();
207          for (G4int i=2; i<nCoeff; i++)
208            {
209              G4double tNext = 2. * t[i-1] - t[i-2];
210              t.push_back(tNext);
211              cross = cross + coeff[i] * tNext;
212            }
213          sigma = std::exp(cross) * scaleFactor;
214        }
215    }     
216
217  return sigma;
218}
219
Note: See TracBrowser for help on using the repository browser.