CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_3_9_patch3/src/SimG4Core/PhysicsLists/src/CMSHadronElasticPhysicsXS.cc

Go to the documentation of this file.
00001 //
00002 // CHIPS for sampling scattering for p and n
00003 // Glauber model for samplimg of high energy pi+- (E > 1GeV)
00004 // LHEP sampling model for the other particle
00005 // BBG cross sections for p and pi+- 
00006 // XS cross sections for neutrons
00007 // LHEP cross sections for other particles
00008 
00009 #include "SimG4Core/PhysicsLists/interface/CMSHadronElasticPhysicsXS.h"
00010 
00011 #include "G4ParticleDefinition.hh"
00012 #include "G4ProcessManager.hh"
00013 
00014 #include "G4MesonConstructor.hh"
00015 #include "G4BaryonConstructor.hh"
00016 #include "G4IonConstructor.hh"
00017 #include "G4Neutron.hh"
00018 
00019 #include "G4WHadronElasticProcess.hh"
00020 #include "G4VHadronElastic.hh"
00021 #include "G4CHIPSElastic.hh"
00022 #include "G4ElasticHadrNucleusHE.hh"
00023 #include "G4BGGNucleonElasticXS.hh"
00024 #include "G4BGGPionElasticXS.hh"
00025 #include "G4NeutronElasticXS.hh"
00026 
00027 CMSHadronElasticPhysicsXS::CMSHadronElasticPhysicsXS(G4int ver)
00028   : G4VPhysicsConstructor("hElasticWEL_CHIPS_XS"), verbose(ver), 
00029     wasActivated(false)
00030 {
00031   if(verbose > 1) { 
00032     G4cout << "### G4HadronElasticPhysicsHP: " << GetPhysicsName() 
00033            << G4endl; 
00034   }
00035 }
00036 
00037 CMSHadronElasticPhysicsXS::~CMSHadronElasticPhysicsXS()
00038 {}
00039 
00040 void CMSHadronElasticPhysicsXS::ConstructParticle()
00041 {
00042   // G4cout << "G4HadronElasticPhysics::ConstructParticle" << G4endl;
00043   G4MesonConstructor pMesonConstructor;
00044   pMesonConstructor.ConstructParticle();
00045 
00046   G4BaryonConstructor pBaryonConstructor;
00047   pBaryonConstructor.ConstructParticle();
00048 
00049   //  Construct light ions
00050   G4IonConstructor pConstructor;
00051   pConstructor.ConstructParticle();  
00052 }
00053 
00054 void CMSHadronElasticPhysicsXS::ConstructProcess()
00055 {
00056   if(wasActivated) return;
00057   wasActivated = true;
00058 
00059   G4double elimit = 1.0*GeV;
00060   if(verbose > 1) {
00061     G4cout << "### HadronElasticPhysics Construct Processes with HE limit " 
00062            << elimit << " MeV" << G4endl;
00063   }
00064 
00065   G4VHadronElastic* plep0 = new G4VHadronElastic();
00066   G4VHadronElastic* plep1 = new G4VHadronElastic();
00067   plep1->SetMaxEnergy(elimit);
00068 
00069   G4CHIPSElastic* chipsp = new G4CHIPSElastic();
00070   G4CHIPSElastic* chipsn = new G4CHIPSElastic();
00071 
00072   G4ElasticHadrNucleusHE* he = new G4ElasticHadrNucleusHE(); 
00073   he->SetMinEnergy(elimit);
00074 
00075   theParticleIterator->reset();
00076   while( (*theParticleIterator)() )
00077   {
00078     G4ParticleDefinition* particle = theParticleIterator->value();
00079     G4String pname = particle->GetParticleName();
00080     if(pname == "anti_lambda"  ||
00081        pname == "anti_neutron" ||
00082        pname == "anti_omega-"  || 
00083        pname == "anti_proton"  || 
00084        pname == "anti_sigma-"  || 
00085        pname == "anti_sigma+"  || 
00086        pname == "anti_xi-"  || 
00087        pname == "anti_xi0"  || 
00088        pname == "kaon-"     || 
00089        pname == "kaon+"     || 
00090        pname == "kaon0S"    || 
00091        pname == "kaon0L"    || 
00092        pname == "lambda"    || 
00093        pname == "omega-"    || 
00094        pname == "pi-"       || 
00095        pname == "pi+"       || 
00096        pname == "proton"    || 
00097        pname == "sigma-"    || 
00098        pname == "sigma+"    || 
00099        pname == "xi-"       || 
00100        pname == "alpha"     ||
00101        pname == "deuteron"  ||
00102        pname == "triton") {
00103       
00104       G4ProcessManager* pmanager = particle->GetProcessManager();
00105       G4WHadronElasticProcess* hel = new G4WHadronElasticProcess();
00106       if(pname == "proton") { 
00107         hel->AddDataSet(new G4BGGNucleonElasticXS(particle));
00108         hel->RegisterMe(chipsp);
00109       } else if (pname == "pi+" || pname == "pi-") { 
00110         hel->AddDataSet(new G4BGGPionElasticXS(particle));
00111         hel->RegisterMe(plep1);
00112         hel->RegisterMe(he);
00113       } else {
00114         hel->RegisterMe(plep0);
00115       }
00116       pmanager->AddDiscreteProcess(hel);
00117       if(verbose > 1) {
00118         G4cout << "### HadronElasticPhysicsXS: " << hel->GetProcessName()
00119                << " added for " << particle->GetParticleName() << G4endl;
00120       }
00121 
00122       // neutron case
00123     } else if(pname == "neutron") {   
00124 
00125       G4ProcessManager* pmanager = particle->GetProcessManager();
00126       G4WHadronElasticProcess* hel = new G4WHadronElasticProcess();
00127       hel->AddDataSet(new G4NeutronElasticXS());
00128       hel->RegisterMe(chipsn);
00129 
00130       pmanager->AddDiscreteProcess(hel);
00131 
00132       if(verbose > 1) {
00133         G4cout << "### HadronElasticPhysicsXS: " << hel->GetProcessName()
00134                << " added for " << particle->GetParticleName() << G4endl;
00135       }
00136     }
00137   }
00138 }
00139 
00140