00001 // 00002 // ******************************************************************** 00003 // * License and Disclaimer * 00004 // * * 00005 // * The Geant4 software is copyright of the Copyright Holders of * 00006 // * the Geant4 Collaboration. It is provided under the terms and * 00007 // * conditions of the Geant4 Software License, included in the file * 00008 // * LICENSE and available at http://cern.ch/geant4/license . These * 00009 // * include a list of copyright holders. * 00010 // * * 00011 // * Neither the authors of this software system, nor their employing * 00012 // * institutes,nor the agencies providing financial support for this * 00013 // * work make any representation or warranty, express or implied, * 00014 // * regarding this software system or assume any liability for its * 00015 // * use. Please see the license in the file LICENSE and URL above * 00016 // * for the full disclaimer and the limitation of liability. * 00017 // * * 00018 // * This code implementation is the result of the scientific and * 00019 // * technical work of the GEANT4 collaboration. * 00020 // * By using, copying, modifying or distributing the software (or * 00021 // * any work based on the software) you agree to acknowledge its * 00022 // * use in resulting scientific publications, and indicate your * 00023 // * acceptance of all terms of the Geant4 Software license. * 00024 // ******************************************************************** 00025 // 00026 // $Id$ 00027 // 00028 // ------------------------------------------------------------------- 00029 // 00030 // GEANT4 Class file 00031 // 00032 // 00033 // File name: G4IonProtonCrossSection 00034 // 00035 // Author Ivantchenko, Geant4, 30 July 2010 00036 // 00037 // Modifications: 00038 // 00039 00040 #include "G4IonProtonCrossSection.hh" 00041 #include "G4SystemOfUnits.hh" 00042 #include "G4ProtonInelasticCrossSection.hh" 00043 #include "G4DynamicParticle.hh" 00044 #include "G4Element.hh" 00045 #include "G4HadTmpUtil.hh" 00046 00047 using namespace std; 00048 00049 G4IonProtonCrossSection::G4IonProtonCrossSection() 00050 : G4VCrossSectionDataSet("AxenWellischIonH") 00051 { 00052 theForward = new G4ProtonInelasticCrossSection(); 00053 } 00054 00055 G4IonProtonCrossSection::~G4IonProtonCrossSection() 00056 {} 00057 00058 G4bool 00059 G4IonProtonCrossSection::IsElementApplicable(const G4DynamicParticle* dp, 00060 G4int Z, const G4Material*) 00061 { 00062 return ((1 == Z) && (dp->GetDefinition()->GetPDGCharge()/eplus > 1.5)); 00063 } 00064 00065 00066 G4double 00067 G4IonProtonCrossSection::GetElementCrossSection( 00068 const G4DynamicParticle* dp, 00069 G4int, const G4Material*) 00070 { 00071 const G4ParticleDefinition* p = dp->GetDefinition(); 00072 G4double e = dp->GetKineticEnergy()*CLHEP::proton_mass_c2/p->GetPDGMass(); 00073 return 00074 theForward->GetProtonCrossSection(e, G4lrint(p->GetPDGCharge()/eplus)); 00075 } 00076 00077 void 00078 G4IonProtonCrossSection::CrossSectionDescription(std::ostream& outFile) const 00079 { 00080 outFile << "G4IonProtonCrossSection calculates the inelastic cross section\n" 00081 << "for ions scattering from protons using inverse kinematics and\n" 00082 << "the Axen-Wellisch inelastic cross sections in the\n" 00083 << "G4ProtonInelasticCrossSection class.\n"; 00084 } 00085