#include <G4ChargeExchangeProcess.hh>
Inheritance diagram for G4ChargeExchangeProcess:
Public Member Functions | |
G4ChargeExchangeProcess (const G4String &procName="chargeExchange") | |
virtual | ~G4ChargeExchangeProcess () |
virtual G4bool | IsApplicable (const G4ParticleDefinition &aParticleType) |
virtual void | BuildPhysicsTable (const G4ParticleDefinition &aParticleType) |
virtual void | DumpPhysicsTable (const G4ParticleDefinition &aParticleType) |
virtual G4double | GetElementCrossSection (const G4DynamicParticle *aParticle, const G4Element *anElement, const G4Material *mat=0) |
Definition at line 53 of file G4ChargeExchangeProcess.hh.
G4ChargeExchangeProcess::G4ChargeExchangeProcess | ( | const G4String & | procName = "chargeExchange" |
) |
Definition at line 54 of file G4ChargeExchangeProcess.cc.
References G4HadronicProcess::AddDataSet(), G4Alpha::Alpha(), G4AntiLambda::AntiLambda(), G4AntiNeutron::AntiNeutron(), G4AntiOmegaMinus::AntiOmegaMinus(), G4AntiProton::AntiProton(), G4AntiSigmaMinus::AntiSigmaMinus(), G4AntiSigmaPlus::AntiSigmaPlus(), G4AntiSigmaZero::AntiSigmaZero(), G4AntiXiMinus::AntiXiMinus(), G4AntiXiZero::AntiXiZero(), G4Deuteron::Deuteron(), G4He3::He3(), G4KaonMinus::KaonMinus(), G4KaonPlus::KaonPlus(), G4KaonZeroLong::KaonZeroLong(), G4KaonZeroShort::KaonZeroShort(), G4Lambda::Lambda(), G4Neutron::Neutron(), G4OmegaMinus::OmegaMinus(), G4PionMinus::PionMinus(), G4PionPlus::PionPlus(), G4PionZero::PionZero(), G4Proton::Proton(), G4SigmaMinus::SigmaMinus(), G4SigmaPlus::SigmaPlus(), G4SigmaZero::SigmaZero(), G4Triton::Triton(), G4VProcess::verboseLevel, G4XiMinus::XiMinus(), and G4XiZero::XiZero().
00055 : G4HadronicProcess(procName,fChargeExchange), first(true) 00056 { 00057 thEnergy = 20.*MeV; 00058 pPDG = 0; 00059 verboseLevel= 1; 00060 AddDataSet(new G4HadronElasticDataSet); 00061 theProton = G4Proton::Proton(); 00062 theNeutron = G4Neutron::Neutron(); 00063 theAProton = G4AntiProton::AntiProton(); 00064 theANeutron = G4AntiNeutron::AntiNeutron(); 00065 thePiPlus = G4PionPlus::PionPlus(); 00066 thePiMinus = G4PionMinus::PionMinus(); 00067 thePiZero = G4PionZero::PionZero(); 00068 theKPlus = G4KaonPlus::KaonPlus(); 00069 theKMinus = G4KaonMinus::KaonMinus(); 00070 theK0S = G4KaonZeroShort::KaonZeroShort(); 00071 theK0L = G4KaonZeroLong::KaonZeroLong(); 00072 theL = G4Lambda::Lambda(); 00073 theAntiL = G4AntiLambda::AntiLambda(); 00074 theSPlus = G4SigmaPlus::SigmaPlus(); 00075 theASPlus = G4AntiSigmaPlus::AntiSigmaPlus(); 00076 theSMinus = G4SigmaMinus::SigmaMinus(); 00077 theASMinus = G4AntiSigmaMinus::AntiSigmaMinus(); 00078 theS0 = G4SigmaZero::SigmaZero(); 00079 theAS0 = G4AntiSigmaZero::AntiSigmaZero(); 00080 theXiMinus = G4XiMinus::XiMinus(); 00081 theXi0 = G4XiZero::XiZero(); 00082 theAXiMinus = G4AntiXiMinus::AntiXiMinus(); 00083 theAXi0 = G4AntiXiZero::AntiXiZero(); 00084 theOmega = G4OmegaMinus::OmegaMinus(); 00085 theAOmega = G4AntiOmegaMinus::AntiOmegaMinus(); 00086 theD = G4Deuteron::Deuteron(); 00087 theT = G4Triton::Triton(); 00088 theA = G4Alpha::Alpha(); 00089 theHe3 = G4He3::He3(); 00090 }
G4ChargeExchangeProcess::~G4ChargeExchangeProcess | ( | ) | [virtual] |
void G4ChargeExchangeProcess::BuildPhysicsTable | ( | const G4ParticleDefinition & | aParticleType | ) | [virtual] |
Reimplemented from G4HadronicProcess.
Definition at line 98 of file G4ChargeExchangeProcess.cc.
References G4HadronicProcess::BuildPhysicsTable(), G4cout, G4endl, G4HadronicProcess::GetCrossSectionDataStore(), G4ParticleDefinition::GetParticleName(), G4ParticleDefinition::GetPDGEncoding(), CLHEP::detail::n, G4PhysicsVector::PutValue(), and G4VProcess::verboseLevel.
00099 { 00100 if(first) { 00101 first = false; 00102 theParticle = &aParticleType; 00103 pPDG = theParticle->GetPDGEncoding(); 00104 00105 store = G4HadronicProcess::GetCrossSectionDataStore(); 00106 00107 const size_t n = 10; 00108 if(theParticle == thePiPlus || theParticle == thePiMinus || 00109 theParticle == theKPlus || theParticle == theKMinus || 00110 theParticle == theK0S || theParticle == theK0L) { 00111 00112 G4double F[n] = {0.33,0.27,0.29,0.31,0.27,0.18,0.13,0.1,0.09,0.07}; 00113 factors = new G4PhysicsLinearVector(0.0,2.0*GeV,n); 00114 for(size_t i=0; i<n; i++) {factors->PutValue(i,F[i]);} 00115 00116 } else { 00117 00118 G4double F[n] = {0.50,0.45,0.40,0.35,0.30,0.25,0.06,0.04,0.005,0.0}; 00119 factors = new G4PhysicsLinearVector(0.0,4.0*GeV,n); 00120 for(size_t i=0; i<n; i++) {factors->PutValue(i,F[i]);} 00121 } 00122 //factors->SetSpline(true); 00123 00124 if(verboseLevel>1) 00125 G4cout << "G4ChargeExchangeProcess for " 00126 << theParticle->GetParticleName() 00127 << G4endl; 00128 } 00129 G4HadronicProcess::BuildPhysicsTable(aParticleType); 00130 }
void G4ChargeExchangeProcess::DumpPhysicsTable | ( | const G4ParticleDefinition & | aParticleType | ) | [virtual] |
Reimplemented from G4HadronicProcess.
Definition at line 192 of file G4ChargeExchangeProcess.cc.
References G4CrossSectionDataStore::DumpPhysicsTable().
00193 { 00194 store->DumpPhysicsTable(aParticleType); 00195 }
G4double G4ChargeExchangeProcess::GetElementCrossSection | ( | const G4DynamicParticle * | aParticle, | |
const G4Element * | anElement, | |||
const G4Material * | mat = 0 | |||
) | [virtual] |
Reimplemented from G4HadronicProcess.
Definition at line 132 of file G4ChargeExchangeProcess.cc.
References G4cout, G4endl, G4CrossSectionDataStore::GetCrossSection(), G4DynamicParticle::GetKineticEnergy(), G4Element::GetN(), G4Element::GetName(), G4ParticleDefinition::GetParticleName(), G4ParticleDefinition::GetPDGMass(), G4DynamicParticle::GetTotalMomentum(), G4PhysicsVector::GetValue(), G4Element::GetZ(), and G4VProcess::verboseLevel.
00136 { 00137 // gives the microscopic cross section in GEANT4 internal units 00138 G4double Z = elm->GetZ(); 00139 G4int iz = G4int(Z); 00140 G4double x = 0.0; 00141 00142 // The process is effective only above the threshold 00143 if(iz == 1 || dp->GetKineticEnergy() < thEnergy) return x; 00144 00145 if(verboseLevel>1) 00146 G4cout << "G4ChargeExchangeProcess compute GHAD CS for element " 00147 << elm->GetName() 00148 << G4endl; 00149 x = store->GetCrossSection(dp, elm, mat); 00150 00151 if(verboseLevel>1) 00152 G4cout << "G4ChargeExchangeProcess cross(mb)= " << x/millibarn 00153 << " E(MeV)= " << dp->GetKineticEnergy() 00154 << " " << theParticle->GetParticleName() 00155 << " in Z= " << iz 00156 << G4endl; 00157 G4bool b; 00158 G4double A = elm->GetN(); 00159 G4double ptot = dp->GetTotalMomentum(); 00160 x *= factors->GetValue(ptot, b)/std::pow(A, 0.42); 00161 if(theParticle == thePiPlus || theParticle == theProton || 00162 theParticle == theKPlus || theParticle == theANeutron) 00163 { x *= (1.0 - Z/A); } 00164 00165 else if(theParticle == thePiMinus || theParticle == theNeutron || 00166 theParticle == theKMinus || theParticle == theAProton) 00167 { x *= Z/A; } 00168 00169 if(theParticle->GetPDGMass() < GeV) { 00170 if(ptot > 2.*GeV) x *= 4.0*GeV*GeV/(ptot*ptot); 00171 } 00172 00173 if(verboseLevel>1) 00174 G4cout << "Corrected cross(mb)= " << x/millibarn << G4endl; 00175 00176 return x; 00177 }
G4bool G4ChargeExchangeProcess::IsApplicable | ( | const G4ParticleDefinition & | aParticleType | ) | [virtual] |
Reimplemented from G4VProcess.
Definition at line 180 of file G4ChargeExchangeProcess.cc.
00181 { 00182 const G4ParticleDefinition* p = &aParticleType; 00183 return (p == thePiPlus || p == thePiMinus || 00184 p == theProton || p == theNeutron || 00185 p == theAProton|| p == theANeutron|| 00186 p == theKPlus || p == theKMinus || 00187 p == theK0S || p == theK0L || 00188 p == theL); 00189 }