G4CHIPSElastic Class Reference

#include <G4CHIPSElastic.hh>

Inheritance diagram for G4CHIPSElastic:

G4HadronElastic G4HadronicInteraction

Public Member Functions

 G4CHIPSElastic ()
virtual ~G4CHIPSElastic ()
virtual G4double SampleInvariantT (const G4ParticleDefinition *p, G4double plab, G4int Z, G4int A)
virtual void Description () const

Detailed Description

Definition at line 47 of file G4CHIPSElastic.hh.


Constructor & Destructor Documentation

G4CHIPSElastic::G4CHIPSElastic (  ) 

Definition at line 64 of file G4CHIPSElastic.cc.

References G4QKaonMinusElasticCrossSection::GetPointer(), G4QKaonPlusElasticCrossSection::GetPointer(), G4QPionMinusElasticCrossSection::GetPointer(), G4QPionPlusElasticCrossSection::GetPointer(), G4QAntiBaryonElasticCrossSection::GetPointer(), G4QNeutronElasticCrossSection::GetPointer(), and G4QProtonElasticCrossSection::GetPointer().

00064                                : G4HadronElastic("hElasticCHIPS")
00065 {
00066   if(!pxsManager)
00067   {
00068     pxsManager    = G4QProtonElasticCrossSection::GetPointer();
00069     nxsManager    = G4QNeutronElasticCrossSection::GetPointer();
00070 
00071     PBARxsManager = G4QAntiBaryonElasticCrossSection::GetPointer(); // Uzhi
00072     PIPxsManager  = G4QPionPlusElasticCrossSection::GetPointer();   // Uzhi
00073     PIMxsManager  = G4QPionMinusElasticCrossSection::GetPointer();  // Uzhi
00074     KPxsManager   = G4QKaonPlusElasticCrossSection::GetPointer();   // Uzhi
00075     KMxsManager   = G4QKaonMinusElasticCrossSection::GetPointer();  // Uzhi
00076   }
00077   //Description();
00078 }

G4CHIPSElastic::~G4CHIPSElastic (  )  [virtual]

Definition at line 80 of file G4CHIPSElastic.cc.

00081 {}


Member Function Documentation

void G4CHIPSElastic::Description (  )  const [virtual]

Reimplemented from G4HadronElastic.

Definition at line 83 of file G4CHIPSElastic.cc.

References G4HadronicInteraction::GetModelName().

00084 {
00085   char* dirName = getenv("G4PhysListDocDir");
00086   if (dirName) {
00087     std::ofstream outFile;
00088     G4String outFileName = GetModelName() + ".html";
00089     G4String pathName = G4String(dirName) + "/" + outFileName;
00090     outFile.open(pathName);
00091     outFile << "<html>\n";
00092     outFile << "<head>\n";
00093 
00094     outFile << "<title>Description of G4CHIPSElastic</title>\n";
00095     outFile << "</head>\n";
00096     outFile << "<body>\n";
00097 
00098     outFile << "The G4CHIPSElastic model performs hadron-nucleus elastic\n"
00099             << "scattering using the parameterized elastic cross sections\n"
00100             << "of M. Kossov\n";
00101 
00102     outFile << "</body>\n";
00103     outFile << "</html>\n";
00104     outFile.close();
00105   }
00106 }

G4double G4CHIPSElastic::SampleInvariantT ( const G4ParticleDefinition p,
G4double  plab,
G4int  Z,
G4int  A 
) [virtual]

Reimplemented from G4HadronElastic.

Definition at line 110 of file G4CHIPSElastic.cc.

References G4VQCrossSection::GetCrossSection(), G4VQCrossSection::GetExchangeT(), G4ParticleDefinition::GetPDGEncoding(), and G4HadronElastic::SampleInvariantT().

00112 {
00113   G4int N = A - Z;
00114   if(Z == 1 && N == 2)      { N = 1; }
00115   else if(Z == 2 && N == 1) { N = 2; }
00116   G4int projPDG = p->GetPDGEncoding();
00117   G4double cs = 0.;
00118   if     (projPDG==2212) { cs = pxsManager->GetCrossSection(false,plab,Z,N,projPDG); }
00119   else if(projPDG==2112) { cs = nxsManager->GetCrossSection(false,plab,Z,N,projPDG); }
00120   else if(projPDG==-2212){ cs = PBARxsManager->GetCrossSection(false,plab,Z,N,projPDG); } //Pbar
00121   else if(projPDG== 211) { cs = PIPxsManager->GetCrossSection(false,plab,Z,N,projPDG); } // Pi+
00122   else if(projPDG==-211) { cs = PIMxsManager->GetCrossSection(false,plab,Z,N,projPDG); } // Pi-
00123   else if(projPDG== 321) { cs = KPxsManager->GetCrossSection(false,plab,Z,N,projPDG); } // K+
00124   else if(projPDG==-321) { cs = KMxsManager->GetCrossSection(false,plab,Z,N,projPDG); } // K-
00125 
00126   G4double t = 0.0;
00127   if(cs > 0.0)
00128   {
00129     if     (projPDG== 2212) { t = pxsManager->GetExchangeT(Z,N,projPDG); }
00130     else if(projPDG== 2112) { t = nxsManager->GetExchangeT(Z,N,projPDG); }
00131     else if(projPDG==-2212) { t = PBARxsManager->GetExchangeT(Z,N,projPDG); } // Pbar
00132     else if(projPDG==  211) { t = PIPxsManager->GetExchangeT(Z,N,projPDG); }  // Pi+
00133     else if(projPDG== -211) { t = PIMxsManager->GetExchangeT(Z,N,projPDG); }  // Pi-
00134     else if(projPDG==  321) { t = KPxsManager->GetExchangeT(Z,N,projPDG); }   // K+
00135     else if(projPDG== -321) { t = KMxsManager->GetExchangeT(Z,N,projPDG); }   // K-
00136   }
00137   else  { t = G4HadronElastic::SampleInvariantT(p, plab, Z, A); }
00138   return t;
00139 }


The documentation for this class was generated from the following files:
Generated on Mon May 27 17:51:37 2013 for Geant4 by  doxygen 1.4.7