// // ******************************************************************** // * License and Disclaimer * // * * // * The Geant4 software is copyright of the Copyright Holders of * // * the Geant4 Collaboration. It is provided under the terms and * // * conditions of the Geant4 Software License, included in the file * // * LICENSE and available at http://cern.ch/geant4/license . These * // * include a list of copyright holders. * // * * // * Neither the authors of this software system, nor their employing * // * institutes,nor the agencies providing financial support for this * // * work make any representation or warranty, express or implied, * // * regarding this software system or assume any liability for its * // * use. Please see the license in the file LICENSE and URL above * // * for the full disclaimer and the limitation of liability. * // * * // * This code implementation is the result of the scientific and * // * technical work of the GEANT4 collaboration. * // * By using, copying, modifying or distributing the software (or * // * any work based on the software) you agree to acknowledge its * // * use in resulting scientific publications, and indicate your * // * acceptance of all terms of the Geant4 Software license. * // ******************************************************************** // // // The lust update: M.V. Kossov, CERN/ITEP(Moscow) 17-June-02 // GEANT4 tag $Name: geant4-09-03-beta-cand-01 $ // // // G4 Physics class: G4QPhotonNuclearCrossSection for gamma+A cross sections // Created: M.V. Kossov, CERN/ITEP(Moscow), 20-Dec-03 // The last update: M.V. Kossov, CERN/ITEP (Moscow) 15-Feb-04 // **************************************************************************************** // ********** This CLASS is temporary moved from the photolepton_hadron directory ********* // ******* DO NOT MAKE ANY CHANGE! With time it'll move back to photolepton...(M.K.) ****** // **************************************************************************************** // Short description: This is an original CHIPS process for photo-nuclear // interactions, which does not include "fast and dirty" corrections for // reactions near threshold, with respect to the GHAD application of CHIPS. // ------------------------------------------------------------------------ //#define debug //#define pdebug //#define debug3 //#define debugn //#define debugs #include "G4QPhotonNuclearCrossSection.hh" // Initialization of the static variables G4bool G4QPhotonNuclearCrossSection::onlyCS=true;// Flag to calculate only CS G4double G4QPhotonNuclearCrossSection::lastSig=0.;// Last value of the Cross Section G4double* G4QPhotonNuclearCrossSection::lastGDR=0; // Pointer to the lastArray of GDR CS G4double* G4QPhotonNuclearCrossSection::lastHEN=0; // Pointer to the last array of HEn CS G4double G4QPhotonNuclearCrossSection::lastE=0.; // LastUsed in CrossSections TheEnergy G4double G4QPhotonNuclearCrossSection::lastSP=0.; // Last value of ShadowingPomeron(A-dep) G4int G4QPhotonNuclearCrossSection::lastPDG=0; // The last PDG code of the projectile G4int G4QPhotonNuclearCrossSection::lastN=0; // The last N of calculated nucleus G4int G4QPhotonNuclearCrossSection::lastZ=0; // The last Z of calculated nucleus G4double G4QPhotonNuclearCrossSection::lastP=0.; // Last used in cross section Momentum G4double G4QPhotonNuclearCrossSection::lastTH=0.; // Last threshold momentum G4double G4QPhotonNuclearCrossSection::lastCS=0.; // Last value of the Cross Section G4int G4QPhotonNuclearCrossSection::lastI=0; // The last position in the DAMDB // Returns Pointer to the G4VQCrossSection class G4VQCrossSection* G4QPhotonNuclearCrossSection::GetPointer() { static G4QPhotonNuclearCrossSection theCrossSection; //**Static body of Cross Section** return &theCrossSection; } // The main member function giving the collision cross section (P is in IU, CS is in mb) // Make pMom in independent units ! (Now it is MeV) G4double G4QPhotonNuclearCrossSection::GetCrossSection(G4bool fCS, G4double pMom, G4int tgZ, G4int tgN, G4int pPDG) { static G4int j; // A#0f records found in DB for this projectile static std::vector colPDG;// Vector of the projectile PDG code static std::vector colN; // Vector of N for calculated nuclei (isotops) static std::vector colZ; // Vector of Z for calculated nuclei (isotops) static std::vector colP; // Vector of last momenta for the reaction static std::vector colTH; // Vector of energy thresholds for the reaction static std::vector colCS; // Vector of last cross sections for the reaction // ***---*** End of the mandatory Static Definitions of the Associative Memory ***---*** G4double pEn=pMom; #ifdef pdebug G4cout<<"G4QPhCS::GetCS:>>> f="< CS=0"< New (inDB) Calculated CS="<lastTH) // Correct the threshold { #ifdef pdebug G4cout<<"G4QPhCS::GetCS: New T="< Threshold="< Threshold="< CS=0 } // else if(std::fabs(lastP/pMom-1.)1&&Z>1&&G4NucleiProperties::IsInStableTable(A-4,Z-2)) mA=G4NucleiProperties::GetNuclearMass(A-4,Z-2)/MeV; // ResNucMass for an alpha G4double dP= mP +mProt - mT; G4double dN= mN +mNeut - mT; G4double dA= mA +mAlph - mT; #ifdef pdebug G4cout<<"G4QPhotoNucCS::ThreshEn: mP="< spA; // shadowing coefficients (A-dependent) static std::vector GDR;// Vector of pointers to GDRPhotonuclearCrossSection static std::vector HEN;// Vector of pointers to HighEnPhotonuclearCrossSect // onlyCS=CS; // Flag to calculate only CS (not Si/Bi) #ifdef pdebug G4cout<<"G4QPhotonNucCS::CalcCS: P="< G4QMuonNucCS::CalcCS: CS=0 as E="< RETRIEVE { lastGDR=GDR[I]; // Pointer to prepared GDR cross sections lastHEN=HEN[I]; // Pointer to prepared High Energy cross sections lastSP =spA[I]; // Shadowing coefficient for UHE } else // This isotope wasn't calculated previously => CREATE { G4double lnA=std::log(A); // The nucleus is not found in DB. It is new. if(A==1.) lastSP=1.; // The Reggeon shadowing (A=1) else lastSP=A*(1.-shc*lnA); // The Reggeon shadowing #ifdef debug G4cout<<">>>G4QPhotonNuclearCrossSect::CalcCS:lnA="<=nLA) k=nLA-1; // Extrapolation from the last bin (U) G4int k1=k-1; G4double xi=LA[k1]; G4double b=(a-xi)/(LA[k]-xi); for(G4int m=0; m1.5) { G4double yi=SL[k1][m]; y[m]=yi+(SL[k][m]-yi)*b; #ifdef debugs if(y[m]<0.)G4cout<<"G4QPhotNucCS::GetF:y="<