Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-07-13 08:21:04

0001 
0002 #ifndef G4HepEmElectronInteractionBrem_HH
0003 #define G4HepEmElectronInteractionBrem_HH
0004 
0005 #include "G4HepEmMacros.hh"
0006 
0007 class  G4HepEmTLData;
0008 class  G4HepEmRandomEngine;
0009 struct G4HepEmData;
0010 struct G4HepEmElectronData;
0011 
0012 
0013 // Bremsstrahlung interaction based on:
0014 // 1. SB: - the numerical Seltzer-Berger DCS for the emitted photon energy.
0015 //        - used between 1 keV - 1 GeV primary e-/e+ kinetic energies.
0016 //        NOTE: the core part i.e. sampling the emitted photon energy is different than
0017 //          that in the G4SeltzerBergerModel. I implemented here my rejection free,
0018 //          memory effcicient (tables only per Z and not per mat-cuts) sampling.
0019 //          Rejection is used only to account dielectric supression and e+ correction.
0020 // 2. RB: - the Bethe-Heitler DCS with modifications such as screening and Coulomb
0021 //          corrections, emission in the field of the atomic electrons and LPM suppression.
0022 //          Used between 1 GeV - 100 TeV primary e-/e+ kinetic energies.
0023 class G4HepEmElectronInteractionBrem {
0024 private:
0025   G4HepEmElectronInteractionBrem() = delete;
0026 
0027 public:
0028   static void Perform(G4HepEmTLData* tlData, struct G4HepEmData* hepEmData, bool iselectron, bool isSBmodel);
0029 
0030 
0031   // Sampling of the energy transferred to the emitted photon using the numerical
0032   // Seltzer-Berger DCS.
0033   G4HepEmHostDevice
0034   static double SampleETransferSB(struct G4HepEmData* hepEmData, double thePrimEkin, double theLogEkin,
0035                                   int theIMCIndx, G4HepEmRandomEngine* rnge, bool iselectron);
0036 
0037   // Sampling of the energy transferred to the emitted photon using the Bethe-Heitler
0038   // DCS.
0039   G4HepEmHostDevice
0040   static double SampleETransferRB(struct G4HepEmData* hepEmData, double thePrimEkin, double theLogEkin,
0041                                   int theIMCIndx, G4HepEmRandomEngine* rnge, bool iselectron);
0042 
0043 
0044   // Target atom selector for the above bremsstrahlung intercations in case of
0045   // materials composed from multiple elements.
0046   G4HepEmHostDevice
0047   static int SelectTargetAtom(const struct G4HepEmElectronData* elData, const int imc, const double ekin,
0048                               const double lekin, const double urndn, const bool isbremSB);
0049 
0050 
0051   G4HepEmHostDevice
0052   static void SampleDirections(const double thePrimEkin, const double theSecGammaEkin, double* theSecGammaDir,
0053                                double* thePrimElecDir, G4HepEmRandomEngine* rnge);
0054 
0055 
0056   // Simple linear search (with step of 3!) used in the photon energy sampling part
0057   // of the SB (Seltzer-Berger) brem model.
0058   G4HepEmHostDevice
0059   static int LinSearch(const double* vect, const int size, const double val);
0060 };
0061 
0062 #endif // G4HepEmElectronInteractionBrem_HH