Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-09-17 08:59:13

0001 //
0002 // ********************************************************************
0003 // * License and Disclaimer                                           *
0004 // *                                                                  *
0005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
0006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
0007 // * conditions of the Geant4 Software License,  included in the file *
0008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
0009 // * include a list of copyright holders.                             *
0010 // *                                                                  *
0011 // * Neither the authors of this software system, nor their employing *
0012 // * institutes,nor the agencies providing financial support for this *
0013 // * work  make  any representation or  warranty, express or implied, *
0014 // * regarding  this  software system or assume any liability for its *
0015 // * use.  Please see the license in the file  LICENSE  and URL above *
0016 // * for the full disclaimer and the limitation of liability.         *
0017 // *                                                                  *
0018 // * This  code  implementation is the result of  the  scientific and *
0019 // * technical work of the GEANT4 collaboration.                      *
0020 // * By using,  copying,  modifying or  distributing the software (or *
0021 // * any work based  on the software)  you  agree  to acknowledge its *
0022 // * use  in  resulting  scientific  publications,  and indicate your *
0023 // * acceptance of all terms of the Geant4 Software license.          *
0024 // ********************************************************************
0025 //
0026 //
0027 // GEANT4 physics class: G4PhotoNuclearCrossSection -- header file
0028 // Created: M.V. Kossov, CERN/ITEP(Moscow), 10-OCT-01
0029 // The last update: M.V. Kossov, CERN/ITEP (Moscow) 17-May-02
0030 
0031 #ifndef G4PhotoNuclearCrossSection_h
0032 #define G4PhotoNuclearCrossSection_h 1
0033 
0034 #include "G4VCrossSectionDataSet.hh"
0035 #include "G4DynamicParticle.hh"
0036 #include "G4Element.hh"
0037 #include "G4ParticleTable.hh"
0038 #include "G4NucleiProperties.hh"
0039 #include "G4NistManager.hh"
0040 #include <vector>
0041 
0042 class G4PhotoNuclearCrossSection : public G4VCrossSectionDataSet
0043 {
0044 public:
0045     
0046     G4PhotoNuclearCrossSection();
0047     ~G4PhotoNuclearCrossSection() override;
0048     
0049     static const char* Default_Name() {return "PhotoNuclearXS";}
0050     
0051     void CrossSectionDescription(std::ostream&) const override;
0052 
0053     G4bool IsIsoApplicable(const G4DynamicParticle*, G4int Z, G4int A,
0054                            const G4Element* elm = nullptr,
0055                const G4Material* mat = nullptr) override;
0056     
0057     G4bool IsElementApplicable(const G4DynamicParticle*, G4int Z,
0058                                const G4Material* mat = nullptr) override;
0059 
0060     G4double GetIsoCrossSection(const G4DynamicParticle*,
0061                                 G4int Z, G4int A,
0062                                 const G4Isotope* iso = nullptr,
0063                                 const G4Element* elm = nullptr,
0064                                 const G4Material* mat = nullptr) override;
0065     
0066     G4double GetElementCrossSection(const G4DynamicParticle*, G4int Z,
0067                                     const G4Material*) override;
0068 
0069     G4double ComputeElementXSection(G4double energy, G4int Z);
0070 
0071     G4double ComputeIsoXSection(G4double energy, G4int Z, G4int A);
0072 
0073     G4PhotoNuclearCrossSection& operator=
0074     (const G4PhotoNuclearCrossSection& right) = delete;
0075     G4PhotoNuclearCrossSection(const G4PhotoNuclearCrossSection&) = delete;
0076 
0077 private:
0078     
0079     G4int GetFunctions(G4double a, G4double* y, G4double* z);
0080     G4double EquLinearFit(G4double X, G4int N, const G4double X0,
0081                           const G4double XD, const G4double* Y);
0082     G4double ThresholdEnergy(G4int Z, G4int N);
0083     
0084     G4int     lastZ = 0;         // The last Z of calculated nucleus
0085     G4double  lastSig = 0.0;     // Last value of the Cross Section
0086     G4double* lastGDR = nullptr; // Pointer to the last array of GDR cross sections
0087     G4double* lastHEN = nullptr; // Pointer to the last array of HEn cross sections
0088     G4double  lastE = 0.0;       // Last used in the cross section Energy
0089     G4double  lastTH = 0.0;      // Last value of the Energy Threshold (A-dependent)
0090     G4double  lastSP = 0.0;      // Last value of the ShadowingPomeron (A-dependent)
0091     
0092     // Vector of pointers to the GDRPhotonuclearCrossSection
0093     std::vector <G4double*> GDR;
0094 
0095     // store deuteron, triton, He3 XS
0096     G4double* deuteron_GDR = nullptr;
0097     G4double* deuteron_HR = nullptr;
0098     G4double deuteron_TH = 0.0;
0099     G4double deuteron_SP = 0.0;
0100     G4double* triton_GDR = nullptr;
0101     G4double* triton_HR = nullptr;
0102     G4double triton_TH = 0.0;
0103     G4double triton_SP = 0.0;
0104     G4double* he3_GDR = nullptr;
0105     G4double* he3_HR = nullptr;
0106     G4double he3_TH = 0.0;
0107     G4double he3_SP = 0.0;
0108     
0109     // Vector of pointers to the HighEnPhotonuclearCrossSect
0110     std::vector <G4double*> HEN;
0111     
0112     std::vector <G4double> spA;  // shadowing coefficients (A-dependent)
0113     std::vector <G4double> eTH;    // energy threshold (A-dependent)
0114     
0115     G4NistManager* nistmngr;
0116     
0117     G4double mNeut;
0118     G4double mProt;
0119 };
0120 
0121 #endif