#include <G4FTFModel.hh>
Inheritance diagram for G4FTFModel:
Public Member Functions | |
G4FTFModel (const G4String &modelName="FTF") | |
~G4FTFModel () | |
void | Init (const G4Nucleus &aNucleus, const G4DynamicParticle &aProjectile) |
G4ExcitedStringVector * | GetStrings () |
G4V3DNucleus * | GetWoundedNucleus () const |
virtual void | ModelDescription (std::ostream &) const |
Definition at line 63 of file G4FTFModel.hh.
G4FTFModel::G4FTFModel | ( | const G4String & | modelName = "FTF" |
) |
Definition at line 56 of file G4FTFModel.cc.
References G4VHighEnergyGenerator::SetEnergyMomentumCheckLevels(), and G4VPartonStringModel::SetThisPointer().
00056 :G4VPartonStringModel(modelName), 00057 theExcitation(new G4DiffractiveExcitation()), 00058 theElastic(new G4ElasticHNScattering()), 00059 theAnnihilation(new G4FTFAnnihilation()) 00060 { 00061 G4VPartonStringModel::SetThisPointer(this); 00062 theParameters=0; 00063 NumberOfInvolvedNucleon=0; 00064 NumberOfInvolvedNucleonOfProjectile=0; 00065 SetEnergyMomentumCheckLevels(2*perCent, 150*MeV); 00066 }
G4FTFModel::~G4FTFModel | ( | ) |
Definition at line 70 of file G4FTFModel.cc.
00071 { 00072 // Because FTF model can be called for various particles 00073 // theParameters must be erased at the end of each call. 00074 // Thus the delete is also in G4FTFModel::GetStrings() method 00075 if( theParameters != 0 ) delete theParameters; 00076 if( theExcitation != 0 ) delete theExcitation; 00077 if( theElastic != 0 ) delete theElastic; 00078 if( theAnnihilation != 0 ) delete theAnnihilation; 00079 00080 // Erasing of strings created at annihilation 00081 if(theAdditionalString.size() != 0) 00082 { 00083 std::for_each(theAdditionalString.begin(), theAdditionalString.end(), 00084 DeleteVSplitableHadron()); 00085 } 00086 theAdditionalString.clear(); 00087 00088 // Erasing of target involved nucleons 00089 if( NumberOfInvolvedNucleon != 0) 00090 { 00091 for(G4int i=0; i < NumberOfInvolvedNucleon; i++) 00092 { 00093 G4VSplitableHadron * aNucleon = TheInvolvedNucleon[i]->GetSplitableHadron(); 00094 if(aNucleon) delete aNucleon; 00095 } 00096 } 00097 00098 // Erasing of projectile involved nucleons 00099 /* 00100 if( NumberOfInvolvedNucleonOfProjectile != 0) 00101 { 00102 for(G4int i=0; i < NumberOfInvolvedNucleonOfProjectile; i++) 00103 { 00104 G4VSplitableHadron * aNucleon = TheInvolvedNucleonOfProjectile[i]->GetSplitableHadron(); 00105 if(aNucleon) delete aNucleon; 00106 } 00107 } 00108 */ 00109 }
G4ExcitedStringVector * G4FTFModel::GetStrings | ( | ) | [virtual] |
Implements G4VPartonStringModel.
Definition at line 206 of file G4FTFModel.cc.
References G4ParticleDefinition::GetBaryonNumber(), G4ReactionProduct::GetDefinition(), G4FTFParticipants::GetInteraction(), G4FTFParticipants::GetList(), G4ReactionProduct::GetTotalMomentum(), G4FTFParticipants::Next(), and G4FTFParticipants::StartLoop().
00207 { 00208 G4ExcitedStringVector * theStrings(0); 00209 00210 theParticipants.GetList(theProjectile,theParameters); 00211 // StoreInvolvedNucleon(); 00212 //G4cout<<" GetList theProjectile.GetMomentum() GetBaryonNumber() "<<theProjectile.GetMomentum()<<" "<<theProjectile.GetDefinition()->GetBaryonNumber()<<G4endl; 00213 G4bool Success(true); 00214 00215 if((std::abs(theProjectile.GetDefinition()->GetBaryonNumber()) <= 1) && 00216 (theProjectile.GetDefinition()->GetBaryonNumber() != -1) ) 00217 { // Standard variant of FTF for projectile hadron/nucleon 00218 //G4cout<<"Standard variant of FTF for projectile hadron/nucleon"<<G4endl; 00219 ReggeonCascade(); 00220 //G4cout<<"Success after Reggeon "<<Success<<" PutOnMasShell"<<G4endl; 00221 Success=PutOnMassShell(); 00222 //G4cout<<"Success after PutOn "<<Success<<" GetResid"<<G4endl; 00223 GetResidualNucleus(); 00224 } 00225 //G4cout<<"Success after GetN "<<Success<<G4endl; 00226 //G4int Uzhi; G4cin>>Uzhi; 00227 if(theProjectile.GetDefinition()->GetBaryonNumber() > 1) 00228 { // Variant of FTF for projectile nuclei 00229 //G4cout<<"Variant of FTF for projectile nuclei"<<G4endl; 00230 StoreInvolvedNucleon(); 00231 ReggeonCascade(); 00232 Success=PutOnMassShell(); 00233 GetResidualNucleus(); 00234 } 00235 00236 // G4bool LowE_Anti_Ion(false); 00237 if(theProjectile.GetDefinition()->GetBaryonNumber() <= -1) 00238 { // Projectile is Anti-baryon or Anti-Nucleus 00239 //G4cout<<"Projectile is Anti-baryon or Anti-Nucleus "<<G4endl; 00240 //G4cout<<"Be4 Store"<<G4endl; 00241 StoreInvolvedNucleon(); 00242 if(theProjectile.GetTotalMomentum()/ 00243 std::abs(theProjectile.GetDefinition()->GetBaryonNumber()) > 5000.*MeV) 00244 {// High energy interaction 00245 //G4cout<<"High energy interaction "<<G4endl; 00246 //G4cout<<"Regeon "<<G4endl; 00247 ReggeonCascade(); 00248 //G4cout<<"Put on mass "<<G4endl; 00249 Success=PutOnMassShell(); 00250 //G4cout<<"Residual "<<G4endl; 00251 GetResidualNucleus(); 00252 } 00253 else 00254 { 00255 //G4cout<<"Low energy interaction "<<G4endl; 00256 // LowE_Anti_Ion=true; 00257 Success=true; 00258 } 00259 } 00260 //G4cout<<"Before Excite Success "<<Success<<G4endl; 00261 Success=Success && ExciteParticipants(); 00262 //G4cout<<"Success ExciteParticipants()? "<<Success<<G4endl; 00263 // if(LowE_Anti_Ion) Success=Success && GetResidualNucleusAfterAnnihilation(); 00264 00265 if( Success ) 00266 { 00267 theStrings = BuildStrings(); 00268 //G4cout<<"BuildStrings OK"<<G4endl; 00269 if( theParameters != 0 ) 00270 { 00271 delete theParameters; 00272 theParameters=0; 00273 } 00274 } 00275 /* 00276 if( Success ) 00277 { 00278 if( ExciteParticipants() ) 00279 { 00280 //G4cout<<"Excite partic OK"<<G4endl; 00281 theStrings = BuildStrings(); 00282 //G4cout<<"Build String OK"<<G4endl; 00283 if(LowE_Anti_Ion) GetResidualNucleusAfterAnnihilation(); 00284 00285 if( theParameters != 0 ) 00286 { 00287 delete theParameters; 00288 theParameters=0; 00289 } 00290 } else // if( ExciteParticipants() ) 00291 { Success=false;} 00292 } else // if( Success ) 00293 { Success=false;} 00294 */ 00295 if(!Success) 00296 { 00297 // -------------- Erase the projectile ---------------- 00298 //G4cout<<"Erase Proj"<<G4endl; 00299 std::vector<G4VSplitableHadron *> primaries; 00300 00301 theParticipants.StartLoop(); // restart a loop 00302 while ( theParticipants.Next() ) 00303 { 00304 const G4InteractionContent & interaction=theParticipants.GetInteraction(); 00305 00306 // do not allow for duplicates ... 00307 if ( primaries.end() == std::find(primaries.begin(), primaries.end(), 00308 interaction.GetProjectile()) ) 00309 primaries.push_back(interaction.GetProjectile()); 00310 } 00311 std::for_each(primaries.begin(), primaries.end(), DeleteVSplitableHadron()); 00312 primaries.clear(); 00313 } 00314 // -------------- Cleaning of the memory -------------- 00315 G4VSplitableHadron * aNucleon = 0; 00316 // -------------- Erase the projectile nucleon -------- 00317 /* 00318 G4VSplitableHadron * aNucleon = 0; 00319 for(G4int i=0; i < NumberOfInvolvedNucleonOfProjectile; i++) 00320 { 00321 aNucleon = TheInvolvedNucleonOfProjectile[i]->GetSplitableHadron(); 00322 if(aNucleon) delete aNucleon; 00323 } 00324 00325 NumberOfInvolvedNucleonOfProjectile=0; 00326 */ // Maybe it will be needed latter------------------ 00327 00328 // -------------- Erase the target nucleons ----------- 00329 //G4cout<<"Erase Target Ninv "<<NumberOfInvolvedNucleon<<G4endl; 00330 for(G4int i=0; i < NumberOfInvolvedNucleon; i++) 00331 { 00332 aNucleon = TheInvolvedNucleon[i]->GetSplitableHadron(); 00333 if(aNucleon) delete aNucleon; 00334 } 00335 00336 NumberOfInvolvedNucleon=0; 00337 //G4cout<<"Go to fragmentation"<<G4endl; 00338 return theStrings; 00339 00340 }
G4V3DNucleus * G4FTFModel::GetWoundedNucleus | ( | ) | const [inline, virtual] |
Implements G4VPartonStringModel.
Definition at line 121 of file G4FTFModel.hh.
References G4VParticipants::GetWoundedNucleus().
00122 { 00123 return theParticipants.GetWoundedNucleus(); 00124 }
void G4FTFModel::Init | ( | const G4Nucleus & | aNucleus, | |
const G4DynamicParticle & | aProjectile | |||
) | [virtual] |
Implements G4VPartonStringModel.
Definition at line 112 of file G4FTFModel.cc.
References G4AntiNeutron::AntiNeutron(), G4AntiProton::AntiProton(), G4V3DNucleus::DoLorentzBoost(), G4Nucleus::GetA_asInt(), G4ParticleDefinition::GetBaryonNumber(), G4Nucleon::GetDefinition(), G4ReactionProduct::GetDefinition(), G4ReactionProduct::GetMomentum(), G4V3DNucleus::GetNextNucleon(), G4ParticleDefinition::GetPDGCharge(), G4ParticleDefinition::GetPDGEncoding(), G4ReactionProduct::GetTotalEnergy(), G4Nucleus::GetZ_asInt(), G4VParticipants::Init(), G4FTFParticipants::InitProjectileNucleus(), G4Nucleon::SetParticleType(), G4FTFParticipants::SetProjectileNucleus(), G4V3DNucleus::StartLoop(), and G4FTFParticipants::theProjectileNucleus.
00113 { 00114 theProjectile = aProjectile; 00115 00116 G4double PlabPerParticle(0.); // Laboratory momentum Pz per particle/nucleon 00117 00118 /* 00119 G4cout<<"FTF init Pro Name "<<theProjectile.GetDefinition()->GetParticleName()<<G4endl; 00120 G4cout<<"FTF init Pro Mass "<<theProjectile.GetMass()<<" "<<theProjectile.GetMomentum()<<G4endl; 00121 G4cout<<"FTF init Pro B Q "<<theProjectile.GetDefinition()->GetBaryonNumber()<<" "<<(G4int) theProjectile.GetDefinition()->GetPDGCharge()<<G4endl; 00122 G4cout<<"FTF init A Z "<<aNucleus.GetA_asInt()<<" "<<aNucleus.GetZ_asInt()<<G4endl; 00123 G4cout<<" "<<aNucleus.GetN()<<" "<<aNucleus.GetZ()<<G4endl; 00124 //G4int Uzhi; G4cin>>Uzhi; 00125 */ 00126 00127 theParticipants.SetProjectileNucleus(0); 00128 theParticipants.Init(aNucleus.GetA_asInt(),aNucleus.GetZ_asInt()); 00129 00130 if(std::abs(theProjectile.GetDefinition()->GetBaryonNumber()) <= 1) 00131 { // Projectile is a hadron 00132 PlabPerParticle=theProjectile.GetMomentum().z(); 00133 00134 // S = sqr( theProjectile.GetMass() ) + sqr( ProtonMass ) + 00135 // 2*ProtonMass*theProjectile.GetTotalEnergy(); 00136 } 00137 00138 00139 if(theProjectile.GetDefinition()->GetBaryonNumber() > 1) 00140 { // Projectile is a nucleus 00141 theParticipants.InitProjectileNucleus( 00142 theProjectile.GetDefinition()->GetBaryonNumber(), 00143 (G4int) theProjectile.GetDefinition()->GetPDGCharge() ); 00144 00145 G4ThreeVector BoostVector=theProjectile.GetMomentum()/theProjectile.GetTotalEnergy(); 00146 theParticipants.theProjectileNucleus->DoLorentzBoost(BoostVector); 00147 00148 PlabPerParticle=theProjectile.GetMomentum().z()/ 00149 theProjectile.GetDefinition()->GetBaryonNumber(); 00150 00151 // S = 2.*sqr( ProtonMass ) + 2*ProtonMass* 00152 // theProjectile.GetTotalEnergy()/theProjectile.GetDefinition()->GetBaryonNumber(); 00153 } 00154 00155 if(theProjectile.GetDefinition()->GetBaryonNumber() < -1) 00156 { // Projectile is an anti-nucleus 00157 theParticipants.InitProjectileNucleus( 00158 std::abs( theProjectile.GetDefinition()->GetBaryonNumber()), 00159 std::abs((G4int) theProjectile.GetDefinition()->GetPDGCharge()) ); 00160 00161 G4ThreeVector BoostVector=theProjectile.GetMomentum()/theProjectile.GetTotalEnergy(); 00162 00163 theParticipants.theProjectileNucleus->StartLoop(); 00164 G4Nucleon * aNucleon; 00165 while ( (aNucleon = theParticipants.theProjectileNucleus->GetNextNucleon()) ) 00166 { 00167 if(aNucleon->GetDefinition()->GetPDGEncoding() == 2212) // Proton 00168 {aNucleon->SetParticleType(G4AntiProton::AntiProton());} 00169 00170 if(aNucleon->GetDefinition()->GetPDGEncoding() == 2112) // Neutron 00171 {aNucleon->SetParticleType(G4AntiNeutron::AntiNeutron());} 00172 } // end of while (theParticipant.theProjectileNucleus->GetNextNucleon()) 00173 00174 theParticipants.theProjectileNucleus->DoLorentzBoost(BoostVector); 00175 00176 PlabPerParticle= theProjectile.GetMomentum().z()/ 00177 std::abs(theProjectile.GetDefinition()->GetBaryonNumber()); 00178 00179 // S = 2.*sqr( ProtonMass ) + 2*ProtonMass* 00180 // theProjectile.GetTotalEnergy()/ 00181 // std::abs(theProjectile.GetDefinition()->GetBaryonNumber()); 00182 } 00183 00184 // ------------------------------------------------------------------------ 00185 if( theParameters != 0 ) delete theParameters; 00186 theParameters = new G4FTFParameters(theProjectile.GetDefinition(), 00187 aNucleus.GetA_asInt(),aNucleus.GetZ_asInt(), 00188 PlabPerParticle); 00189 //G4cout<<" End Init "<<theProjectile.GetMomentum()<<G4endl; 00190 // To turn on/off (1/0) elastic scattering close/open ... 00191 //theParameters->SetProbabilityOfElasticScatt(0.); 00192 //G4cout<<" etProbabilityOfElasticScatt "<<theParameters->GetProbabilityOfElasticScatt()<<G4endl; 00193 //G4cout<<" INIT "; 00194 //G4int Uzhi; G4cin>>Uzhi; 00195 00196 if(theAdditionalString.size() != 0) 00197 { 00198 std::for_each(theAdditionalString.begin(), theAdditionalString.end(), 00199 DeleteVSplitableHadron()); 00200 } 00201 theAdditionalString.clear(); 00202 //G4cout<<" End Init theProjectile.GetMomentum()"<<theProjectile.GetMomentum()<<G4endl; 00203 }
void G4FTFModel::ModelDescription | ( | std::ostream & | ) | const [virtual] |
Reimplemented from G4VPartonStringModel.
Definition at line 1745 of file G4FTFModel.cc.
References G4endl.
01746 { 01747 desc << "please add description here" << G4endl; 01748 }