Changeset 1055 for trunk/source/processes/hadronic/cross_sections
- Timestamp:
- May 28, 2009, 4:26:57 PM (15 years ago)
- Location:
- trunk/source/processes/hadronic/cross_sections
- Files:
-
- 32 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/processes/hadronic/cross_sections/History
r1007 r1055 15 15 --------------------------------------------------------------- 16 16 17 01 December 2008 Vladimir Ivantchenko (hadr-cross-V09-01-07) 17 21 March 2009 Vladimir Ivanchenko (hadr-cross-V09-02-04) 18 ------------------------------------------------------------ 19 - G4IonsKoxCrossSection, G4IonsShenCrossSection, G4TripathiCrossSection, 20 G4TripathiLightCrossSection - added protections against numerical 21 exceptions (V.Grichine) 22 - G4GGNuclNuclCrossSection - Glauber-Gribov new cross section for ions 23 (V.Grichine) 24 25 25 February 2009 Vladimir Ivanchenko (hadr-cross-V09-02-03) 26 ------------------------------------------------------------ 27 - G4CrossSectionDataStore - added protection to the Clean method 28 29 14 February 2009 Vladimir Ivanchenko (hadr-cross-V09-02-02) 30 ------------------------------------------------------------ 31 - G4CrossSectionDataStore - added Clean method 32 33 06 February 2009 Vladimir Ivanchenko (hadr-cross-V09-02-01) 34 ------------------------------------------------------------ 35 36 24 January 2009 Vladimir Ivanchenko (hadr-cross-V09-02-00) 37 ------------------------------------------------------------ 38 - G4CrossSectionDataStore - moved constructor and destructor to source, 39 added destruction of data sets, use STL 40 vector instead of C-array 41 - G4CrossSectionDataSetRegistry - new singleton to keep pointers to 42 cross section data sets 43 - G4VCrossSectiondataSet - constructor and detructor moved to source and 44 registration/deregistration added 45 46 01 December 2008 Vladimir Ivanchenko (hadr-cross-V09-01-07) 18 47 ------------------------------------------------------------ 19 48 G4BGGPionElasticXS, G4BGGPionInelasticXS, G4BGGNucleonInelasticXS, -
trunk/source/processes/hadronic/cross_sections/include/G4BGGNucleonElasticXS.hh
r1007 r1055 25 25 // 26 26 // $Id: G4BGGNucleonElasticXS.hh,v 1.2 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/include/G4BGGNucleonInelasticXS.hh
r1007 r1055 25 25 // 26 26 // $Id: G4BGGNucleonInelasticXS.hh,v 1.2 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/include/G4BGGPionElasticXS.hh
r1007 r1055 25 25 // 26 26 // $Id: G4BGGPionElasticXS.hh,v 1.2 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/include/G4BGGPionInelasticXS.hh
r1007 r1055 25 25 // 26 26 // $Id: G4BGGPionInelasticXS.hh,v 1.2 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/include/G4CrossSectionDataSetRegistry.hh
r966 r1055 25 25 // 26 26 // $Id: G4CrossSectionDataSetRegistry.hh,v 1.2 2009/02/14 19:22:19 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2-ref-02$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/include/G4CrossSectionDataStore.hh
r1007 r1055 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4CrossSectionDataStore.hh,v 1.14 2009/01/24 11:54:47 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 // 29 // ------------------------------------------------------------------- 30 // 31 // GEANT4 Class header file 32 // 33 // 34 // File name: G4CrossSectionDataStore 35 // 36 // 37 // Modifications: 38 // 23.01.2009 V.Ivanchenko move constructor and destructor to source, 39 // use STL vector instead of C-array 40 // 41 26 42 // Class Description 27 43 // This is the class to which cross section data sets may be registered. … … 40 56 #include "G4Material.hh" 41 57 #include "G4VCrossSectionDataSet.hh" 58 #include <vector> 42 59 43 60 class G4Nucleus; … … 47 64 public: 48 65 49 G4CrossSectionDataStore() : 50 NDataSetList(0), verboseLevel(0) 51 {} 66 G4CrossSectionDataStore(); 52 67 53 ~G4CrossSectionDataStore() 54 {} 68 ~G4CrossSectionDataStore(); 55 69 56 57 70 G4double GetCrossSection(const G4DynamicParticle*, 71 const G4Element*, G4double aTemperature); 58 72 59 60 73 G4double GetCrossSection(const G4DynamicParticle*, 74 const G4Isotope*, G4double aTemperature); 61 75 62 63 76 G4double GetCrossSection(const G4DynamicParticle*, 77 G4double Z, G4double A, G4double aTemperature); 64 78 65 66 79 // to replace GetMicroscopicCrossSection 80 G4double GetCrossSection(const G4DynamicParticle*, const G4Material*); 67 81 68 69 SelectRandomIsotope(const G4DynamicParticle*, const G4Material*);82 //std::pair<G4double/*Z*/, G4double/*A*/> 83 // SelectRandomIsotope(const G4DynamicParticle*, const G4Material*); 70 84 71 72 85 G4Element* SampleZandA(const G4DynamicParticle*, const G4Material*, 86 G4Nucleus& target); 73 87 74 88 void AddDataSet(G4VCrossSectionDataSet*); 75 89 76 90 void BuildPhysicsTable(const G4ParticleDefinition&); 77 91 78 92 void DumpPhysicsTable(const G4ParticleDefinition&); 79 93 80 void SetVerboseLevel(G4int value)81 82 83 94 inline void SetVerboseLevel(G4int value) 95 { 96 verboseLevel = value; 97 } 84 98 85 G4int GetVerboseLevel()86 87 88 99 inline G4int GetVerboseLevel() 100 { 101 return verboseLevel; 102 } 89 103 90 104 private: 91 105 106 G4VCrossSectionDataSet* whichDataSetInCharge(const G4DynamicParticle*, 107 const G4Element*); 92 108 93 G4VCrossSectionDataSet* whichDataSetInCharge(const G4DynamicParticle*, 94 const G4Element*); 95 96 enum { NDataSetMax = 100 }; 97 G4VCrossSectionDataSet* DataSetList[NDataSetMax]; 98 G4int NDataSetList; 99 G4int verboseLevel; 109 std::vector<G4VCrossSectionDataSet*> DataSetList; 110 G4int NDataSetList; 111 G4int verboseLevel; 100 112 }; 101 113 -
trunk/source/processes/hadronic/cross_sections/include/G4ElectroNuclearCrossSection.hh
r1007 r1055 25 25 // 26 26 // 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // -
trunk/source/processes/hadronic/cross_sections/include/G4GGNuclNuclCrossSection.hh
r966 r1055 71 71 G4double Z, G4double A, 72 72 G4double aTemperature = 0.0); 73 74 G4double GetCoulombBarier(const G4DynamicParticle*, 75 G4double Z, G4double A, G4double pR, G4double tR); 73 76 74 77 virtual -
trunk/source/processes/hadronic/cross_sections/include/G4HadronCrossSections.hh
r1007 r1055 25 25 // 26 26 // 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // -
trunk/source/processes/hadronic/cross_sections/include/G4PhotoNuclearCrossSection.hh
r1007 r1055 25 25 // 26 26 // 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // -
trunk/source/processes/hadronic/cross_sections/include/G4VCrossSectionDataSet.hh
r1007 r1055 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4VCrossSectionDataSet.hh,v 1.13 2009/01/24 11:54:47 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 26 28 // 27 // GEANT4 physics abstract class: G4VCrossSectionData -- header file 28 // F.W. Jones, TRIUMF, 20-JAN-97 29 // ------------------------------------------------------------------- 30 // 31 // GEANT4 Class header file 32 // 33 // 34 // File name: G4VCrossSectionDataSet 35 // 36 // Author F.W. Jones, TRIUMF, 20-JAN-97 37 // 38 // Modifications: 39 // 23.01.2009 V.Ivanchenko move constructor and destructor to source 40 // 41 29 42 // 30 43 // Class Description … … 43 56 class G4VCrossSectionDataSet 44 57 { 45 public:46 47 G4VCrossSectionDataSet() :48 verboseLevel(0)49 {}50 51 virtual ~G4VCrossSectionDataSet()52 {}53 54 58 public: //with description 55 59 56 // The following methods need to be implemented for each new data set. 57 virtual 58 G4bool IsApplicable(const G4DynamicParticle*, const G4Element*) = 0; 60 G4VCrossSectionDataSet(); 59 61 60 virtual 61 G4bool IsZAApplicable(const G4DynamicParticle*, G4double /*Z*/, G4double /*A*/); 62 virtual ~G4VCrossSectionDataSet(); 62 63 63 virtual 64 G4double GetCrossSection(const G4DynamicParticle*, 65 const G4Element*, 66 G4double aTemperature = 0.) = 0; 64 // The following methods need to be implemented for each new data set. 65 virtual 66 G4bool IsApplicable(const G4DynamicParticle*, const G4Element*) = 0; 67 67 68 virtual 69 G4double GetIsoCrossSection(const G4DynamicParticle*, const G4Isotope*, 70 G4double aTemperature = 0.); 68 virtual 69 G4bool IsZAApplicable(const G4DynamicParticle*, G4double /*Z*/, G4double /*A*/); 71 70 72 virtual 73 G4double GetIsoZACrossSection(const G4DynamicParticle*, G4double /*Z*/, 74 G4double /*A*/, G4double aTemperature = 0.); 71 virtual 72 G4double GetCrossSection(const G4DynamicParticle*, 73 const G4Element*, 74 G4double aTemperature = 0.) = 0; 75 75 76 virtual 77 void BuildPhysicsTable(const G4ParticleDefinition&) = 0; 76 virtual 77 G4double GetIsoCrossSection(const G4DynamicParticle*, const G4Isotope*, 78 G4double aTemperature = 0.); 78 79 79 virtual 80 void DumpPhysicsTable(const G4ParticleDefinition&) = 0; 80 virtual 81 G4double GetIsoZACrossSection(const G4DynamicParticle*, G4double /*Z*/, 82 G4double /*A*/, G4double aTemperature = 0.); 83 84 virtual 85 void BuildPhysicsTable(const G4ParticleDefinition&) = 0; 86 87 virtual 88 void DumpPhysicsTable(const G4ParticleDefinition&) = 0; 81 89 82 90 public: // Without Description 83 91 84 void SetVerboseLevel(G4int value)85 86 87 92 inline void SetVerboseLevel(G4int value) 93 { 94 verboseLevel = value; 95 } 88 96 89 G4int GetVerboseLevel()90 91 92 97 inline G4int GetVerboseLevel() 98 { 99 return verboseLevel; 100 } 93 101 94 102 protected: 95 103 96 104 G4int verboseLevel; 97 105 }; 98 106 -
trunk/source/processes/hadronic/cross_sections/src/G4BGGNucleonElasticXS.cc
r1007 r1055 25 25 // 26 26 // $Id: G4BGGNucleonElasticXS.cc,v 1.3 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/src/G4BGGNucleonInelasticXS.cc
r1007 r1055 25 25 // 26 26 // $Id: G4BGGNucleonInelasticXS.cc,v 1.3 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/src/G4BGGPionElasticXS.cc
r1007 r1055 25 25 // 26 26 // $Id: G4BGGPionElasticXS.cc,v 1.3 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/src/G4BGGPionInelasticXS.cc
r1007 r1055 25 25 // 26 26 // $Id: G4BGGPionInelasticXS.cc,v 1.3 2008/12/01 16:50:23 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/src/G4CrossSectionDataSetRegistry.cc
r968 r1055 26 26 // 27 27 // $Id: G4CrossSectionDataSetRegistry.cc,v 1.3 2009/02/25 16:27:36 vnivanch Exp $ 28 // GEANT4 tag $Name: geant4-09-0 2-ref-02$28 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 29 29 // 30 30 // ------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/src/G4CrossSectionDataStore.cc
r1007 r1055 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4CrossSectionDataStore.cc,v 1.16 2009/01/24 11:54:47 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 // 29 // ------------------------------------------------------------------- 30 // 31 // GEANT4 Class file 32 // 33 // 34 // File name: G4CrossSectionDataStore 35 // 36 // 37 // Modifications: 38 // 23.01.2009 V.Ivanchenko add destruction of data sets 39 // 26 40 // 27 41 … … 33 47 #include "G4Nucleus.hh" 34 48 49 G4CrossSectionDataStore::G4CrossSectionDataStore() : 50 NDataSetList(0), verboseLevel(0) 51 {} 52 53 G4CrossSectionDataStore::~G4CrossSectionDataStore() 54 {} 35 55 36 56 G4double … … 392 412 return anElement; 393 413 } 394 */395 414 396 415 std::pair<G4double, G4double> … … 513 532 return std::pair<G4double, G4double>(ZZ, AA); 514 533 } 515 534 */ 516 535 517 536 void 518 537 G4CrossSectionDataStore::AddDataSet(G4VCrossSectionDataSet* aDataSet) 519 538 { 520 if (NDataSetList == NDataSetMax) { 521 G4cout << "WARNING: G4CrossSectionDataStore::AddDataSet: "<<G4endl; 522 G4cout << " reached maximum number of data sets"; 523 G4cout << " data set not added !!!!!!!!!!!!!!!!"; 524 return; 525 } 526 DataSetList[NDataSetList] = aDataSet; 527 NDataSetList++; 528 } 529 539 DataSetList.push_back(aDataSet); 540 NDataSetList++; 541 } 530 542 531 543 void … … 533 545 BuildPhysicsTable(const G4ParticleDefinition& aParticleType) 534 546 { 535 if (NDataSetList == 0) 536 { 537 G4Exception("G4CrossSectionDataStore", "007", FatalException, 538 "BuildPhysicsTable: no data sets registered"); 539 return; 540 } 541 for (G4int i = NDataSetList-1; i >= 0; i--) { 547 if(NDataSetList > 0) { 548 for (G4int i=0; i<NDataSetList; i++) { 542 549 DataSetList[i]->BuildPhysicsTable(aParticleType); 543 } 550 } 551 } 544 552 } 545 553 … … 549 557 DumpPhysicsTable(const G4ParticleDefinition& aParticleType) 550 558 { 551 if (NDataSetList == 0) { 552 G4cout << "WARNING - G4CrossSectionDataStore::DumpPhysicsTable: no data sets registered"<<G4endl; 553 return; 554 } 555 for (G4int i = NDataSetList-1; i >= 0; i--) { 556 DataSetList[i]->DumpPhysicsTable(aParticleType); 557 } 558 } 559 if (NDataSetList == 0) { 560 G4cout << "WARNING - G4CrossSectionDataStore::DumpPhysicsTable: " 561 << " no data sets registered"<<G4endl; 562 return; 563 } 564 for (G4int i = NDataSetList-1; i >= 0; i--) { 565 DataSetList[i]->DumpPhysicsTable(aParticleType); 566 } 567 } -
trunk/source/processes/hadronic/cross_sections/src/G4ElectroNuclearCrossSection.cc
r1007 r1055 26 26 // 27 27 // $Id: G4ElectroNuclearCrossSection.cc,v 1.29 2008/10/24 19:15:17 dennis Exp $ 28 // GEANT4 tag $Name: geant4-09-0 2$28 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 29 29 // 30 30 // -
trunk/source/processes/hadronic/cross_sections/src/G4GGNuclNuclCrossSection.cc
r968 r1055 42 42 G4GGNuclNuclCrossSection::G4GGNuclNuclCrossSection() 43 43 : fUpperLimit( 100000 * GeV ), 44 fLowerLimit( 0.1 * GeV ),44 fLowerLimit( 0.1 * MeV ), 45 45 fRadiusConst( 1.08*fermi ) // 1.1, 1.3 ? 46 46 { … … 115 115 GetIsoZACrossSection(const G4DynamicParticle* aParticle, G4double tZ, G4double tA, G4double) 116 116 { 117 G4double xsection, sigma, cofInelastic = 2.4, cofTotal = 2.0, nucleusSquare, ratio;117 G4double xsection, sigma, cofInelastic = 2.4, cofTotal = 2.0, nucleusSquare, cB, ratio; 118 118 119 119 G4double pZ = aParticle->GetDefinition()->GetPDGCharge(); … … 132 132 G4double pR = GetNucleusRadius(pA); 133 133 134 sigma = (pZ*tZ+pN*tN)*GetHadronNucleonXscNS(theProton, pTkin, theProton) + 134 cB = GetCoulombBarier(aParticle, tZ, tA, pR, tR); 135 136 if(cB > 0.) 137 { 138 139 sigma = (pZ*tZ+pN*tN)*GetHadronNucleonXscNS(theProton, pTkin, theProton) + 135 140 (pZ*tN+pN*tZ)*GetHadronNucleonXscNS(theProton, pTkin, theNeutron); 136 141 137 nucleusSquare = cofTotal*pi*( pR*pR + tR*tR ); // basically 2piRR 138 139 ratio = sigma/nucleusSquare; 140 141 xsection = nucleusSquare*std::log( 1. + ratio ); 142 143 fTotalXsc = xsection; 144 145 fInelasticXsc = nucleusSquare*std::log( 1. + cofInelastic*ratio )/cofInelastic; 146 147 fElasticXsc = fTotalXsc - fInelasticXsc; 148 149 G4double difratio = ratio/(1.+ratio); 150 151 fDiffractionXsc = 0.5*nucleusSquare*( difratio - std::log( 1. + difratio ) ); 152 153 // production to be checked !!! edit MK xsc 154 155 sigma = (pZ*tZ+pN*tN)*GetHadronNucleonXscMK(theProton, pTkin, theProton) + 142 nucleusSquare = cofTotal*pi*( pR*pR + tR*tR ); // basically 2piRR 143 144 ratio = sigma/nucleusSquare; 145 146 xsection = nucleusSquare*std::log( 1. + ratio ); 147 148 fTotalXsc = xsection; 149 150 fTotalXsc *= cB; 151 152 fInelasticXsc = nucleusSquare*std::log( 1. + cofInelastic*ratio )/cofInelastic; 153 154 fInelasticXsc *= cB; 155 156 fElasticXsc = fTotalXsc - fInelasticXsc; 157 158 // if (fElasticXsc < DBL_MIN) fElasticXsc = DBL_MIN; 159 /* 160 G4double difratio = ratio/(1.+ratio); 161 162 fDiffractionXsc = 0.5*nucleusSquare*( difratio - std::log( 1. + difratio ) ); 163 */ 164 // production to be checked !!! edit MK xsc 165 166 sigma = (pZ*tZ+pN*tN)*GetHadronNucleonXscMK(theProton, pTkin, theProton) + 156 167 (pZ*tN+pN*tZ)*GetHadronNucleonXscMK(theProton, pTkin, theNeutron); 157 168 158 ratio = sigma/nucleusSquare; 159 160 fProductionXsc = nucleusSquare*std::log( 1. + cofInelastic*ratio )/cofInelastic; 161 162 if (fElasticXsc < 0.) fElasticXsc = 0.; 163 164 return xsection; 165 } 169 ratio = sigma/nucleusSquare; 170 171 fProductionXsc = nucleusSquare*std::log( 1. + cofInelastic*ratio )/cofInelastic; 172 173 if (fElasticXsc < 0.) fElasticXsc = 0.; 174 } 175 else 176 { 177 fInelasticXsc = 0.; 178 fTotalXsc = 0.; 179 fElasticXsc = 0.; 180 fProductionXsc = 0.; 181 } 182 return fInelasticXsc; // xsection; 183 } 184 185 //////////////////////////////////////////////////////////////////////////////////////// 186 // 187 // 188 189 G4double G4GGNuclNuclCrossSection:: 190 GetCoulombBarier(const G4DynamicParticle* aParticle, G4double tZ, G4double tA, G4double pR, G4double tR) 191 { 192 G4double ratio; 193 G4double pZ = aParticle->GetDefinition()->GetPDGCharge(); 194 195 196 G4double pTkin = aParticle->GetKineticEnergy(); 197 // G4double pPlab = aParticle->GetTotalMomentum(); 198 G4double pM = aParticle->GetDefinition()->GetPDGMass(); 199 // G4double tM = tZ*proton_mass_c2 + (tA-tZ)*neutron_mass_c2; // ~ 1% accuracy 200 G4double tM = G4ParticleTable::GetParticleTable()->GetIonTable()->GetIonMass( G4int(tZ), G4int(tA) ); 201 G4double pElab = pTkin + pM; 202 G4double totEcm = std::sqrt(pM*pM + tM*tM + 2.*pElab*tM); 203 // G4double pPcm = pPlab*tM/totEcm; 204 // G4double pTcm = std::sqrt(pM*pM + pPcm*pPcm) - pM; 205 G4double totTcm = totEcm - pM -tM; 206 207 G4double bC = fine_structure_const*hbarc*pZ*tZ; 208 bC /= pR + tR; 209 bC /= 2.; // 4., 2. parametrisation cof ??? vmg 210 211 // G4cout<<"pTkin = "<<pTkin/GeV<<"; pPlab = " 212 // <<pPlab/GeV<<"; bC = "<<bC/GeV<<"; pTcm = "<<pTcm/GeV<<G4endl; 213 214 if( totTcm <= bC ) ratio = 0.; 215 else ratio = 1. - bC/totTcm; 216 217 // if(ratio < DBL_MIN) ratio = DBL_MIN; 218 if( ratio < 0.) ratio = 0.; 219 220 // G4cout <<"ratio = "<<ratio<<G4endl; 221 return ratio; 222 } 223 166 224 167 225 ////////////////////////////////////////////////////////////////////////// -
trunk/source/processes/hadronic/cross_sections/src/G4HadronCaptureDataSet.cc
r1007 r1055 26 26 // 27 27 // $Id: G4HadronCaptureDataSet.cc,v 1.8 2006/06/29 19:57:35 gunter Exp $ 28 // GEANT4 tag $Name: geant4-09-0 2$28 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 29 29 // 30 30 // -
trunk/source/processes/hadronic/cross_sections/src/G4HadronCrossSections.cc
r1007 r1055 25 25 // 26 26 // 27 // GEANT4 tag $Name: geant4-09-0 2$27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 28 // 29 29 // -
trunk/source/processes/hadronic/cross_sections/src/G4HadronElasticDataSet.cc
r1007 r1055 26 26 // 27 27 // $Id: G4HadronElasticDataSet.cc,v 1.8 2006/06/29 19:57:39 gunter Exp $ 28 // GEANT4 tag $Name: geant4-09-0 2$28 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 29 29 // 30 30 // -
trunk/source/processes/hadronic/cross_sections/src/G4HadronFissionDataSet.cc
r1007 r1055 26 26 // 27 27 // $Id: G4HadronFissionDataSet.cc,v 1.8 2006/06/29 19:57:41 gunter Exp $ 28 // GEANT4 tag $Name: geant4-09-0 2$28 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 29 29 // 30 30 // -
trunk/source/processes/hadronic/cross_sections/src/G4HadronInelasticDataSet.cc
r1007 r1055 26 26 // 27 27 // $Id: G4HadronInelasticDataSet.cc,v 1.8 2006/06/29 19:57:43 gunter Exp $ 28 // GEANT4 tag $Name: geant4-09-0 2$28 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 29 29 // 30 30 // -
trunk/source/processes/hadronic/cross_sections/src/G4IonsKoxCrossSection.cc
r819 r1055 44 44 45 45 // Apply energy check, if less than lower limit then 0 value is returned 46 if ( ke_per_N < lowerLimit ) 47 return xsection; 46 // if ( ke_per_N < lowerLimit ) return xsection; 48 47 49 48 G4int At = int (AA + 0.5); … … 57 56 58 57 G4double Bc = Zt * Zp / ( ( rc / fermi ) * ( cubicrAp + cubicrAt ) ); // rc divide fermi 58 G4double targ_mass = G4ParticleTable::GetParticleTable()->GetIonTable()->GetIonMass( Zt , At ); 59 G4double proj_mass = aParticle->GetMass(); 60 G4double proj_momentum = aParticle->GetMomentum().mag(); 61 62 G4double Ecm = calEcm ( proj_mass , targ_mass , proj_momentum ); 63 if( Ecm <= Bc) return xsection; 59 64 60 65 G4double Rvol = r0 * ( cubicrAp + cubicrAt ); … … 69 74 70 75 G4double Rint = Rvol + Rsurf; 71 72 G4double targ_mass = G4ParticleTable::GetParticleTable()->GetIonTable()->GetIonMass( Zt , At );73 G4double proj_mass = aParticle->GetMass();74 G4double proj_momentum = aParticle->GetMomentum().mag();75 76 G4double Ecm = calEcm ( proj_mass , targ_mass , proj_momentum );77 76 78 77 xsection = pi * Rint * Rint * ( 1 - Bc / ( Ecm / MeV ) ); -
trunk/source/processes/hadronic/cross_sections/src/G4IonsShenCrossSection.cc
r819 r1055 47 47 48 48 // Apply energy check, if less than lower limit then 0 value is returned 49 if ( ke_per_N < lowerLimit ) 50 return xsection; 49 // if ( ke_per_N < lowerLimit ) return xsection; 51 50 52 51 G4int At = G4int(AA); … … 63 62 G4double r = Rt + Rp + 3.2; // in fm 64 63 G4double b = 1.0; // in MeV/fm 64 G4double targ_mass = G4ParticleTable::GetParticleTable()->GetIonTable()->GetIonMass( Zt , At ); 65 G4double proj_mass = aParticle->GetMass(); 66 G4double proj_momentum = aParticle->GetMomentum().mag(); 67 68 G4double Ecm = calEcmValue ( proj_mass , targ_mass , proj_momentum ); 65 69 66 70 G4double B = 1.44 * Zt * Zp / r - b * Rt * Rp / ( Rt + Rp ); 67 71 if(Ecm <= B) return xsection; 68 72 //G4double ke_per_N = aParticle->GetKineticEnergy() / Ap; 69 73 … … 74 78 G4double R2 = 1.0 * ( At - 2 * Zt ) * Zp / ( Ap * At ); 75 79 76 G4double targ_mass = G4ParticleTable::GetParticleTable()->GetIonTable()->GetIonMass( Zt , At );77 G4double proj_mass = aParticle->GetMass();78 G4double proj_momentum = aParticle->GetMomentum().mag();79 80 G4double Ecm = calEcmValue ( proj_mass , targ_mass , proj_momentum );81 80 82 81 G4double R3 = 0.176 / std::pow ( G4double(Ecm) , G4double(one_third) ) * cubicrAt * cubicrAp / ( cubicrAt + cubicrAp ); -
trunk/source/processes/hadronic/cross_sections/src/G4PhotoNuclearCrossSection.cc
r1007 r1055 26 26 // 27 27 // The lust update: M.V. Kossov, CERN/ITEP(Moscow) 17-June-02 28 // GEANT4 tag $Name: geant4-09-0 2$28 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 29 29 // 30 30 // -
trunk/source/processes/hadronic/cross_sections/src/G4PiData.cc
r1007 r1055 24 24 // ******************************************************************** 25 25 // 26 // GEANT4 tag $Name: geant4-09-0 2$26 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 27 27 // 28 28 // -------------------------------------------------------------------- -
trunk/source/processes/hadronic/cross_sections/src/G4TripathiCrossSection.cc
r819 r1055 39 39 G4double /*temperature*/) 40 40 { 41 G4double result = 0 ;41 G4double result = 0.; 42 42 43 43 const G4double targetAtomicNumber = AA; … … 60 60 pTarget = pTarget+pProjectile; 61 61 G4double E_cm = (pTarget.mag()-targetMass-pProjectile.m())/MeV; 62 62 if(E_cm <= DBL_MIN) return result; 63 63 // done 64 64 G4double r_rms_p = 0.6 * myNuleonRadius * … … 78 78 //done 79 79 G4double B = 1.44*nProjProtons*nTargetProtons/Radius; 80 80 if(E_cm <= B) return result; 81 81 // done 82 82 G4double Energy = kineticEnergy/projectileAtomicNumber; … … 133 133 (1-B/E_cm); 134 134 135 if(result < 0 ) result = 0;135 if(result < 0.) result = 0.; 136 136 return result*m2; 137 137 -
trunk/source/processes/hadronic/cross_sections/src/G4TripathiLightCrossSection.cc
r819 r1055 153 153 pT = pT + pP; 154 154 G4double E_cm = (pT.mag()-mT-pP.m())/MeV; 155 if(E_cm <= DBL_MIN) return result; 156 157 155 158 // 156 159 // … … 169 172 170 173 G4double B = 1.44 * ZP * ZT / Radius; 171 // 174 if(E_cm <= B) return result; 175 172 176 // 173 177 // Now determine other parameters associated with the parametric … … 289 293 if (!lowEnergyCheck) 290 294 { 291 if (result < 0.0) 292 result = 0.0; 295 if (result < 0.0) result = 0.0; 293 296 else if (E < 6.0*MeV) 294 297 { -
trunk/source/processes/hadronic/cross_sections/src/G4VCrossSectionDataSet.cc
r1007 r1055 24 24 // ******************************************************************** 25 25 // 26 // $Id: G4VCrossSectionDataSet.cc,v 1.7 2006/12/29 02:05:48 dennis Exp $ 27 // 26 // $Id: G4VCrossSectionDataSet.cc,v 1.8 2009/01/24 11:54:47 vnivanch Exp $ 27 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ 28 // 29 // ------------------------------------------------------------------- 30 // 31 // GEANT4 Class file 32 // 33 // 34 // File name: G4VCrossSectionDataSet 35 // 36 // Author F.W. Jones, TRIUMF, 20-JAN-97 37 // 38 // Modifications: 39 // 23.01.2009 V.Ivanchenko move constructor and destructor to source 40 // 28 41 29 42 #include "G4VCrossSectionDataSet.hh" 43 #include "G4CrossSectionDataSetRegistry.hh" 44 45 G4VCrossSectionDataSet::G4VCrossSectionDataSet() : 46 verboseLevel(0) 47 { 48 G4CrossSectionDataSetRegistry::Instance()->Register(this); 49 } 50 51 G4VCrossSectionDataSet::~G4VCrossSectionDataSet() 52 { 53 G4CrossSectionDataSetRegistry::Instance()->DeRegister(this); 54 } 30 55 31 56 // Override this method to test for particle and isotope applicability
Note: See TracChangeset
for help on using the changeset viewer.