Ignore:
Timestamp:
Apr 6, 2009, 12:30:29 PM (15 years ago)
Author:
garnier
Message:

update processes

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/processes/hadronic/cross_sections/src/G4BGGNucleonElasticXS.cc

    r819 r962  
    2424// ********************************************************************
    2525//
    26 // $Id: G4BGGNucleonElasticXS.cc,v 1.1 2007/03/13 15:19:30 vnivanch Exp $
    27 // GEANT4 tag $Name: $
     26// $Id: G4BGGNucleonElasticXS.cc,v 1.3 2008/12/01 16:50:23 vnivanch Exp $
     27// GEANT4 tag $Name: geant4-09-02-ref-02 $
    2828//
    2929// -------------------------------------------------------------------
     
    4646#include "G4GlauberGribovCrossSection.hh"
    4747#include "G4NucleonNuclearCrossSection.hh"
     48#include "G4HadronNucleonXsc.hh"
    4849#include "G4Proton.hh"
    4950#include "G4Neutron.hh"
     
    5253//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    5354
    54 G4BGGNucleonElasticXS::G4BGGNucleonElasticXS(const G4ParticleDefinition* p)
     55G4BGGNucleonElasticXS::G4BGGNucleonElasticXS(const G4ParticleDefinition*)
    5556{
    5657  verboseLevel = 0;
    57   thEnergy     = 100.*GeV;
    58   if(p == G4Proton::Proton() || p == G4Neutron::Neutron()) {
    59     fNucleon = new G4NucleonNuclearCrossSection();
    60     fGlauber = new G4GlauberGribovCrossSection();
    61     particle = p;
    62     Initialise();
    63   } else {
    64     fNucleon = 0;
    65     fGlauber = 0;
    66     particle = 0;
    67     if(p) G4cout << "### G4BGGNucleonElasticXS WARNING: is not applicable to "
    68                  << p->GetParticleName()
    69                  << G4endl;
    70     else  G4cout << "### G4BGGNucleonElasticXS WARNING: particle is not defined "
    71                  << G4endl;
    72   }
     58  fGlauberEnergy = 91.*GeV;
     59  fLowEnergy = 20.*MeV;
     60  fNucleon = 0;
     61  fGlauber = 0;
     62  fHadron  = 0;
     63  particle = 0;
     64  isProton = false;
     65  isInitialized = false;
    7366}
    7467
     
    7972  delete fGlauber;
    8073  delete fNucleon;
     74  delete fHadron;
    8175}
    8276
     
    9084  G4double cross = 0.0;
    9185  G4double ekin = dp->GetKineticEnergy();
    92   G4int iz = G4int(Z + 0.5);
     86  G4int iz = G4int(Z);
    9387  if(iz > 92) iz = 92;
    9488
    95   if(ekin > thEnergy) {
    96     cross = theFac[iz]*fGlauber->GetElasticGlauberGribov(dp, Z, A);
     89  if(ekin <= fLowEnergy) {
     90    cross = theCoulombFac[iz];
     91    if(isProton) { cross *= CoulombFactor(ekin, A); }
     92
     93  } else if(iz == 1) {
     94    if( A < 1.5) {
     95      //fHadron->GetHadronNucleonXscPDG(dp, G4Proton::Proton());
     96      //fHadron->GetHadronNucleonXscEL(dp, G4Proton::Proton());
     97      //fHadron->GetHadronNucleonXscNS(dp, G4Proton::Proton());
     98      fHadron->GetHadronNucleonXscMK(dp, G4Proton::Proton());
     99      cross = fHadron->GetElasticHadronNucleonXsc();
     100    } else {
     101      fHadron->GetHadronNucleonXscMK(dp, G4Proton::Proton());
     102      cross = fHadron->GetElasticHadronNucleonXsc();
     103      fHadron->GetHadronNucleonXscMK(dp, G4Neutron::Neutron());
     104      cross += fHadron->GetElasticHadronNucleonXsc();
     105    }
     106  } else if(ekin > fGlauberEnergy) {
     107    cross = theGlauberFac[iz]*fGlauber->GetElasticGlauberGribov(dp, Z, A);
    97108  } else {
    98     cross = fNucleon->GetIsoZACrossSection(dp, Z, A);
     109    cross = fNucleon->GetElasticCrossSection(dp, Z, A);
    99110  }
    100111
     
    112123//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    113124
    114 void G4BGGNucleonElasticXS::BuildPhysicsTable(const G4ParticleDefinition&)
    115 {
     125void G4BGGNucleonElasticXS::BuildPhysicsTable(const G4ParticleDefinition& p)
     126{
     127  if(&p == G4Proton::Proton() || &p == G4Neutron::Neutron()) {
     128    particle = &p;
     129    Initialise();
     130  } else {
     131    G4cout << "### G4BGGNucleonElasticXS WARNING: is not applicable to "
     132           << p.GetParticleName()
     133           << G4endl;
     134  }
    116135}
    117136
     
    127146void G4BGGNucleonElasticXS::Initialise()
    128147{
     148  if(isInitialized) return;
     149  isInitialized = true;
     150
     151  fNucleon = new G4NucleonNuclearCrossSection();
     152  fGlauber = new G4GlauberGribovCrossSection();
     153  fHadron  = new G4HadronNucleonXsc();
     154  fNucleon->BuildPhysicsTable(*particle);
     155  fGlauber->BuildPhysicsTable(*particle);
     156  if(particle == G4Proton::Proton()) isProton = true;
     157
    129158  G4ParticleDefinition* part = const_cast<G4ParticleDefinition*>(particle);
    130159  G4ThreeVector mom(0.0,0.0,1.0);
    131   G4DynamicParticle dp(part, mom, thEnergy);
     160  G4DynamicParticle dp(part, mom, fGlauberEnergy);
    132161
    133162  G4NistManager* nist = G4NistManager::Instance();
    134   G4double A = nist->GetAtomicMassAmu(2);
    135 
    136   G4double csup, csdn;
     163
     164  G4double A, csup, csdn;
    137165
    138166  if(verboseLevel > 0) G4cout << "### G4BGGNucleonElasticXS::Initialise for "
     
    145173
    146174    csup = fGlauber->GetElasticGlauberGribov(&dp, Z, A);
    147     csdn = fNucleon->GetIsoZACrossSection(&dp, Z, A);
    148 
    149     theFac[iz] = csdn/csup;
     175    csdn = fNucleon->GetElasticCrossSection(&dp, Z, A);
     176
     177    theGlauberFac[iz] = csdn/csup;
    150178    if(verboseLevel > 0) G4cout << "Z= " << Z <<  "  A= " << A
    151                                 << " factor= " << theFac[iz] << G4endl;
    152   }
    153 }
    154 
    155 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
    156 
    157 
     179                                << " factor= " << theGlauberFac[iz] << G4endl;
     180  }
     181  dp.SetKineticEnergy(fLowEnergy);
     182  fHadron->GetHadronNucleonXscMK(&dp, G4Proton::Proton());
     183  theCoulombFac[1] = fHadron->GetElasticHadronNucleonXsc();
     184  if(isProton) { theCoulombFac[1] /= CoulombFactor(fLowEnergy, 1.0); }
     185
     186  for(G4int iz=2; iz<93; iz++) {
     187
     188    G4double Z = G4double(iz);
     189    A = nist->GetAtomicMassAmu(iz);
     190
     191    theCoulombFac[iz] = fNucleon->GetElasticCrossSection(&dp, Z, A);
     192    if(isProton) { theCoulombFac[iz] /= CoulombFactor(fLowEnergy, A); }
     193    if(verboseLevel > 0) G4cout << "Z= " << Z <<  "  A= " << A
     194                                << " factor= " << theCoulombFac[iz] << G4endl;
     195  }
     196}
     197
     198//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
     199
     200G4double G4BGGNucleonElasticXS::CoulombFactor(G4double kinEnergy, G4double A)
     201{
     202  G4double res= 0.0;
     203  if(kinEnergy <= DBL_MIN) return res;
     204  else if(A < 1.5) return kinEnergy*kinEnergy;
     205
     206  G4double elog = std::log10(kinEnergy/GeV);
     207
     208  // from G4ProtonInelasticCrossSection
     209  G4double f1 = 8.0  - 8.0/A - 0.008*A;
     210  G4double f2 = 2.34 - 5.4/A - 0.0028*A;
     211
     212  res = 1.0/(1.0 + std::exp(-f1*(elog + f2)));
     213 
     214  f1 = 5.6 - 0.016*A;
     215  f2 = 1.37 + 1.37/A;
     216  res *= ( 1.0 + (0.8 + 18./A - 0.002*A)/(1.0 + std::exp(f1*(elog + f2))));
     217  return res; 
     218}
     219
     220//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
     221
     222
Note: See TracChangeset for help on using the changeset viewer.