Changeset 1347 for trunk/source/processes/hadronic/models/de_excitation/evaporation/src/G4EvaporationChannel.cc
- Timestamp:
- Dec 22, 2010, 3:52:27 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/hadronic/models/de_excitation/evaporation/src/G4EvaporationChannel.cc
r962 r1347 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4EvaporationChannel.cc,v 1.19 2010/11/24 15:30:49 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-04-ref-00 $ 26 28 // 27 29 //J.M. Quesada (August2008). Based on: … … 30 32 // by V. Lara (Oct 1998) 31 33 // 32 // Modif (03 September 2008) by J. M. Quesada for external choice of inverse 33 // cross section option 34 // JMQ (06 September 2008) Also external choices have been added for 35 // superimposed Coulomb barrier (if useSICB is set true, by default is false) 36 34 // Modified: 35 // 03-09-2008 J.M. Quesada for external choice of inverse cross section option 36 // 06-09-2008 J.M. Quesada Also external choices have been added for superimposed 37 // Coulomb barrier (if useSICB is set true, by default is false) 38 // 17-11-2010 V.Ivanchenko in constructor replace G4VEmissionProbability by 39 // G4EvaporationProbability and do not new and delete probability 40 // object at each call; use G4Pow 37 41 38 42 #include "G4EvaporationChannel.hh" 39 43 #include "G4PairingCorrection.hh" 40 41 42 43 G4EvaporationChannel::G4EvaporationChannel(const G4int anA, const G4int aZ, const G4String & aName, 44 G4VEmissionProbability * aEmissionStrategy, 45 G4VCoulombBarrier * aCoulombBarrier): 44 #include "G4NucleiProperties.hh" 45 #include "G4Pow.hh" 46 #include "G4EvaporationLevelDensityParameter.hh" 47 #include "Randomize.hh" 48 #include "G4Alpha.hh" 49 50 G4EvaporationChannel::G4EvaporationChannel(G4int anA, G4int aZ, 51 const G4String & aName, 52 G4EvaporationProbability* aEmissionStrategy, 53 G4VCoulombBarrier* aCoulombBarrier): 46 54 G4VEvaporationChannel(aName), 47 55 theA(anA), … … 52 60 MaximalKineticEnergy(-1000.0) 53 61 { 54 theLevelDensityPtr = new G4EvaporationLevelDensityParameter; 55 // MyOwnLevelDensity = true; 62 ResidualA = 0; 63 ResidualZ = 0; 64 ResidualMass = CoulombBarrier=0.0; 65 EvaporatedMass = G4NucleiProperties::GetNuclearMass(theA, theZ); 66 theLevelDensityPtr = new G4EvaporationLevelDensityParameter; 67 } 68 69 G4EvaporationChannel::G4EvaporationChannel(): 70 G4VEvaporationChannel(""), 71 theA(0), 72 theZ(0), 73 theEvaporationProbabilityPtr(0), 74 theCoulombBarrierPtr(0), 75 EmissionProbability(0.0), 76 MaximalKineticEnergy(-1000.0) 77 { 78 ResidualA = 0; 79 ResidualZ = 0; 80 EvaporatedMass = ResidualMass = CoulombBarrier = 0.0; 81 theLevelDensityPtr = new G4EvaporationLevelDensityParameter; 56 82 } 57 83 … … 60 86 delete theLevelDensityPtr; 61 87 } 62 63 G4EvaporationChannel::G4EvaporationChannel(const G4EvaporationChannel & ) : G4VEvaporationChannel()64 {65 throw G4HadronicException(__FILE__, __LINE__, "G4EvaporationChannel::copy_costructor meant to not be accessable");66 }67 68 const G4EvaporationChannel & G4EvaporationChannel::operator=(const G4EvaporationChannel & )69 {70 throw G4HadronicException(__FILE__, __LINE__, "G4EvaporationChannel::operator= meant to not be accessable");71 return *this;72 }73 74 G4bool G4EvaporationChannel::operator==(const G4EvaporationChannel & right) const75 {76 return (this == (G4EvaporationChannel *) &right);77 // return false;78 }79 80 G4bool G4EvaporationChannel::operator!=(const G4EvaporationChannel & right) const81 {82 return (this != (G4EvaporationChannel *) &right);83 // return true;84 }85 86 //void G4EvaporationChannel::SetLevelDensityParameter(G4VLevelDensityParameter * aLevelDensity)87 // {88 // if (MyOwnLevelDensity) delete theLevelDensityPtr;89 // theLevelDensityPtr = aLevelDensity;90 // MyOwnLevelDensity = false;91 // }92 88 93 89 void G4EvaporationChannel::Initialize(const G4Fragment & fragment) … … 98 94 theEvaporationProbabilityPtr->UseSICB(useSICB); 99 95 100 101 G4int FragmentA = static_cast<G4int>(fragment.GetA()); 102 G4int FragmentZ = static_cast<G4int>(fragment.GetZ()); 96 G4int FragmentA = fragment.GetA_asInt(); 97 G4int FragmentZ = fragment.GetZ_asInt(); 103 98 ResidualA = FragmentA - theA; 104 99 ResidualZ = FragmentZ - theZ; 100 //G4cout << "G4EvaporationChannel::Initialize Z= " << theZ << " A= " << theA 101 // << " FragZ= " << FragmentZ << " FragA= " << FragmentA << G4endl; 105 102 106 103 //Effective excitation energy … … 108 105 G4PairingCorrection::GetInstance()->GetPairingCorrection(FragmentA,FragmentZ); 109 106 110 111 107 // Only channels which are physically allowed are taken into account 112 108 if (ResidualA <= 0 || ResidualZ <= 0 || ResidualA < ResidualZ || 113 109 (ResidualA == ResidualZ && ResidualA > 1) || ExEnergy <= 0.0) { 114 CoulombBarrier =0.0;110 CoulombBarrier = ResidualMass = 0.0; 115 111 MaximalKineticEnergy = -1000.0*MeV; 116 112 EmissionProbability = 0.0; 117 113 } else { 114 ResidualMass = G4NucleiProperties::GetNuclearMass(ResidualA, ResidualZ); 115 G4double FragmentMass = fragment.GetGroundStateMass(); 118 116 CoulombBarrier = theCoulombBarrierPtr->GetCoulombBarrier(ResidualA,ResidualZ,ExEnergy); 119 117 // Maximal Kinetic Energy 120 MaximalKineticEnergy = CalcMaximalKineticEnergy 121 (G4ParticleTable::GetParticleTable()->122 GetIonTable()->GetNucleusMass(FragmentZ,FragmentA)+ExEnergy);118 MaximalKineticEnergy = CalcMaximalKineticEnergy(FragmentMass + ExEnergy); 119 //MaximalKineticEnergy = ExEnergy + fragment.GetGroundStateMass() 120 // - EvaporatedMass - ResidualMass; 123 121 124 122 // Emission probability … … 131 129 limit= CoulombBarrier; 132 130 else limit=0.; 131 limit = std::max(limit, FragmentMass - ResidualMass - EvaporatedMass); 133 132 134 133 // The threshold for charged particle emission must be set to 0 if Coulomb 135 134 //cutoff is included in the cross sections 136 //if (MaximalKineticEnergy <= 0.0) EmissionProbability = 0.0;137 135 if (MaximalKineticEnergy <= limit) EmissionProbability = 0.0; 138 136 else { … … 142 140 } 143 141 } 142 //G4cout << "G4EvaporationChannel:: probability= " << EmissionProbability << G4endl; 144 143 145 144 return; … … 148 147 G4FragmentVector * G4EvaporationChannel::BreakUp(const G4Fragment & theNucleus) 149 148 { 150 G4double EvaporatedKineticEnergy=GetKineticEnergy(theNucleus); 151 152 G4double EvaporatedMass = G4ParticleTable::GetParticleTable()->GetIonTable()-> 153 GetIonMass(theZ,theA); 154 G4double EvaporatedEnergy = EvaporatedKineticEnergy + EvaporatedMass; 155 149 /* 150 G4double Ecm = GetKineticEnergy(theNucleus) + ResidualMass + EvaporatedMass; 151 152 G4double EvaporatedEnergy = 153 ((Ecm-ResidualMass)*(Ecm+ResidualMass) + EvaporatedMass*EvaporatedMass)/(2*Ecm); 154 */ 155 G4double EvaporatedEnergy = GetKineticEnergy(theNucleus) + EvaporatedMass; 156 156 157 G4ThreeVector momentum(IsotropicVector 157 (std::sqrt(EvaporatedKineticEnergy* 158 (EvaporatedKineticEnergy+2.0*EvaporatedMass)))); 159 160 momentum.rotateUz(theNucleus.GetMomentum().vect().unit()); 158 (std::sqrt((EvaporatedEnergy - EvaporatedMass)* 159 (EvaporatedEnergy + EvaporatedMass)))); 161 160 162 161 G4LorentzVector EvaporatedMomentum(momentum,EvaporatedEnergy); 163 EvaporatedMomentum.boost(theNucleus.GetMomentum().boostVector()); 162 G4LorentzVector ResidualMomentum = theNucleus.GetMomentum(); 163 EvaporatedMomentum.boost(ResidualMomentum.boostVector()); 164 164 165 165 G4Fragment * EvaporatedFragment = new G4Fragment(theA,theZ,EvaporatedMomentum); 166 #ifdef PRECOMPOUND_TEST 167 EvaporatedFragment->SetCreatorModel(G4String("G4Evaporation")); 168 #endif 169 // ** And now the residual nucleus ** 170 G4double theExEnergy = theNucleus.GetExcitationEnergy(); 171 G4double theMass = G4ParticleTable::GetParticleTable()->GetIonTable()-> 172 GetNucleusMass(static_cast<G4int>(theNucleus.GetZ()), 173 static_cast<G4int>(theNucleus.GetA())); 174 G4double ResidualEnergy = theMass + 175 (theExEnergy - EvaporatedKineticEnergy) - EvaporatedMass; 176 177 G4LorentzVector ResidualMomentum(-momentum,ResidualEnergy); 178 ResidualMomentum.boost(theNucleus.GetMomentum().boostVector()); 179 180 G4Fragment * ResidualFragment = new G4Fragment(ResidualA, ResidualZ, ResidualMomentum ); 181 182 #ifdef PRECOMPOUND_TEST 183 ResidualFragment->SetCreatorModel(G4String("ResidualNucleus")); 184 #endif 166 ResidualMomentum -= EvaporatedMomentum; 167 168 G4Fragment * ResidualFragment = new G4Fragment(ResidualA, ResidualZ, ResidualMomentum); 169 185 170 G4FragmentVector * theResult = new G4FragmentVector; 186 171 … … 211 196 ///////////////////////////////////////// 212 197 // Calculates the maximal kinetic energy that can be carried by fragment. 213 G4double G4EvaporationChannel::CalcMaximalKineticEnergy(const G4double NucleusTotalE) 214 { 215 G4double ResidualMass = G4ParticleTable::GetParticleTable()-> 216 GetIonTable()->GetNucleusMass( ResidualZ, ResidualA ); 217 G4double EvaporatedMass = G4ParticleTable::GetParticleTable()-> 218 GetIonTable()->GetNucleusMass( theZ, theA ); 219 198 G4double G4EvaporationChannel::CalcMaximalKineticEnergy(G4double NucleusTotalE) 199 { 220 200 // This is the "true" assimptotic kinetic energy (from energy conservation) 221 G4double Tmax = (NucleusTotalE*NucleusTotalE + EvaporatedMass*EvaporatedMass - 222 ResidualMass*ResidualMass)/(2.0*NucleusTotalE) - EvaporatedMass; 201 G4double Tmax = 202 ((NucleusTotalE-ResidualMass)*(NucleusTotalE+ResidualMass) + EvaporatedMass*EvaporatedMass) 203 /(2.0*NucleusTotalE) - EvaporatedMass; 223 204 224 205 //JMQ (13-09-08) bug fixed: in the original version the Tmax is calculated … … 245 226 246 227 247 if (MaximalKineticEnergy < 0.0) 228 if (MaximalKineticEnergy < 0.0) { 248 229 throw G4HadronicException(__FILE__, __LINE__, 249 230 "G4EvaporationChannel::CalcKineticEnergy: maximal kinetic at the Coulomb barrier is less than 0"); 250 231 } 251 232 G4double Rb = 4.0*theLevelDensityPtr-> 252 233 LevelDensityParameter(ResidualA+theA,ResidualZ+theZ,MaximalKineticEnergy)* … … 263 244 G4double Q2 = 1.0; 264 245 if (theZ == 0) { // for emitted neutron 265 G4double Beta = (2.12/ std::pow(G4double(ResidualA),2./3.) - 0.05)*MeV/266 (0.76 + 2.2/ std::pow(G4double(ResidualA),1./3.));246 G4double Beta = (2.12/G4Pow::GetInstance()->Z23(ResidualA) - 0.05)*MeV/ 247 (0.76 + 2.2/G4Pow::GetInstance()->Z13(ResidualA)); 267 248 Q1 = 1.0 + Beta/(MaximalKineticEnergy); 268 249 Q2 = Q1*std::sqrt(Q1); … … 277 258 } else if (OPTxs==1 || OPTxs==2 || OPTxs==3 || OPTxs==4) { 278 259 279 G4double V;280 if(useSICB) V= CoulombBarrier;281 else V=0.;282 //If Coulomb barrier is just included in the cross sections 283 // G4double V=0.;260 // Coulomb barrier is just included in the cross sections 261 G4double V = 0; 262 if(useSICB) { V= CoulombBarrier; } 263 264 V = std::max(V, aFragment.GetGroundStateMass()-EvaporatedMass-ResidualMass); 284 265 285 266 G4double Tmax=MaximalKineticEnergy; 286 267 G4double T(0.0); 287 268 G4double NormalizedProbability(1.0); 288 269 270 // VI: This is very ineffective - create new objects at each call to the method 271 /* 289 272 // A pointer is created in order to access the distribution function. 290 G4EvaporationProbability * G4EPtemp ;273 G4EvaporationProbability * G4EPtemp = 0; 291 274 292 275 if (theA==1 && theZ==0) G4EPtemp=new G4NeutronEvaporationProbability(); … … 305 288 G4EPtemp->SetOPTxs(OPTxs); 306 289 G4EPtemp->UseSICB(useSICB); 307 290 */ 291 292 // use local pointer and not create a new one 308 293 do 309 294 { 310 295 T=V+G4UniformRand()*(Tmax-V); 311 NormalizedProbability=G4EPtemp->ProbabilityDistributionFunction(aFragment,T)/ 312 (this->GetEmissionProbability()); 296 NormalizedProbability = 297 theEvaporationProbabilityPtr->ProbabilityDistributionFunction(aFragment,T)/ 298 GetEmissionProbability(); 313 299 314 300 } 315 301 while (G4UniformRand() > NormalizedProbability); 316 delete G4EPtemp;317 return T;302 // delete G4EPtemp; 303 return T; 318 304 } else{ 319 305 std::ostringstream errOs; … … 323 309 } 324 310 325 G4ThreeVector G4EvaporationChannel::IsotropicVector( constG4double Magnitude)311 G4ThreeVector G4EvaporationChannel::IsotropicVector(G4double Magnitude) 326 312 // Samples a isotropic random vectorwith a magnitud given by Magnitude. 327 313 // By default Magnitude = 1.0 328 314 { 329 330 331 332 333 334 335 336 315 G4double CosTheta = 1.0 - 2.0*G4UniformRand(); 316 G4double SinTheta = std::sqrt(1.0 - CosTheta*CosTheta); 317 G4double Phi = twopi*G4UniformRand(); 318 G4ThreeVector Vector(Magnitude*std::cos(Phi)*SinTheta, 319 Magnitude*std::sin(Phi)*SinTheta, 320 Magnitude*CosTheta); 321 return Vector; 322 } 337 323 338 324
Note: See TracChangeset
for help on using the changeset viewer.