- Timestamp:
- Jun 18, 2010, 11:42:07 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/hadronic/models/coherent_elastic/src/G4HadronElastic.cc
r1228 r1315 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4HadronElastic.cc,v 1.6 5 2009/10/08 18:56:57 vnivanchExp $27 // GEANT4 tag $Name: geant4-09-0 3$26 // $Id: G4HadronElastic.cc,v 1.66 2010/01/13 15:42:06 mkossov Exp $ 27 // GEANT4 tag $Name: geant4-09-04-beta-cand-01 $ 28 28 // 29 29 // … … 62 62 // p and He targets only 63 63 // 11-May-07 V.Ivanchenko remove unused method Defs1 64 // 13.01.10: M.Kosov: Use G4Q(Pr/Neut)ElasticCS instead of G4QElasticCS 64 65 // 65 66 … … 68 69 #include "G4ParticleDefinition.hh" 69 70 #include "G4IonTable.hh" 70 #include "G4QElasticCrossSection.hh" 71 #include "G4QProtonElasticCrossSection.hh" 72 #include "G4QNeutronElasticCrossSection.hh" 71 73 #include "G4VQCrossSection.hh" 72 74 #include "G4ElasticHadrNucleusHE.hh" … … 79 81 #include "G4PionMinus.hh" 80 82 81 G4VQCrossSection* G4HadronElastic::qCManager = 0; 83 G4VQCrossSection* G4HadronElastic::pCManager = 0; 84 G4VQCrossSection* G4HadronElastic::nCManager = 0; 82 85 83 86 G4HadronElastic::G4HadronElastic(G4ElasticHadrNucleusHE* HModel) … … 93 96 plabLowLimit = 20.0*MeV; 94 97 95 if(!qCManager) {qCManager = G4QElasticCrossSection::GetPointer();} 98 if(!pCManager) 99 { 100 pCManager = G4QProtonElasticCrossSection::GetPointer(); 101 nCManager = G4QNeutronElasticCrossSection::GetPointer(); 102 } 96 103 if(!hElastic) hElastic = new G4ElasticHadrNucleusHE(); 97 104 … … 112 119 G4VQCrossSection* G4HadronElastic::GetCS() 113 120 { 114 return qCManager; 121 return pCManager; 122 //if (PDG==2212) return pCManager; 123 //else if(PDG==2112) return nCManager; 124 //return 0; 115 125 } 116 126 … … 200 210 if(gtype == fQElastic) { 201 211 if (verboseLevel >1) { 202 G4cout << "G4HadronElastic: Z= " << Z << " N= " 203 << N << " pdg= " << projPDG 204 << " mom(GeV)= " << plab/GeV << " " << qCManager << G4endl; 212 G4cout << "G4HadronElastic: Z= " << Z << " N= " << N << " pdg= " << projPDG 213 << " mom(GeV)= " << plab/GeV<<", pC="<<pCManager<<", nC="<<nCManager<<G4endl; 205 214 } 206 215 if(Z == 1 && N == 2) N = 1; 207 216 else if(Z == 2 && N == 1) N = 2; 208 G4double cs = qCManager->GetCrossSection(false,plab,Z,N,projPDG); 217 G4double cs = 0.; 218 if (projPDG==2212) cs = pCManager->GetCrossSection(false,plab,Z,N,projPDG); 219 else if(projPDG==2112) cs = nCManager->GetCrossSection(false,plab,Z,N,projPDG); 209 220 210 221 // check if cross section is reasonable 211 if(cs > 0.0) t = qCManager->GetExchangeT(Z,N,projPDG); 222 if(cs > 0.0) 223 { 224 if (projPDG==2212) t = pCManager->GetExchangeT(Z,N,projPDG); 225 else if(projPDG==2112) t = nCManager->GetExchangeT(Z,N,projPDG); 226 } 212 227 else if(plab > plabLowLimit) gtype = fLElastic; 213 228 else gtype = fSWave;
Note: See TracChangeset
for help on using the changeset viewer.