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4.p3 ] [ 10.5 ] [ 10.5.p1 ] [ 10.6 ] [ 10.6.p1 ] [ 10.6.p2 ] [ 10.6.p3 ] [ 10.7 ] [ 10.7.p1 ] [ 10.7.p2 ] [ 10.7.p3 ] [ 10.7.p4 ] [ 11.0 ] [ 11.0.p1 ] [ 11.0.p2 ] [ 11.0.p3, ] [ 11.0.p4 ] [ 11.1 ] [ 11.1.1 ] [ 11.1.2 ] [ 11.1.3 ] [ 11.2 ] [ 11.2.1 ] [ 11.2.2 ] [ 11.3.0 ]

Diff markup

Differences between /examples/extended/hadronic/Hadr02/include/HadronicInelasticModelCRMC.hh (Version 11.3.0) and /examples/extended/hadronic/Hadr02/include/HadronicInelasticModelCRMC.hh (Version 10.7.p2)


  1 // *******************************************      1 // ********************************************************************
  2 // * License and Disclaimer                         2 // * License and Disclaimer                                           *
  3 // *                                                3 // *                                                                  *
  4 // * The  Geant4 software  is  copyright of th      4 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
  5 // * the Geant4 Collaboration.  It is provided      5 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
  6 // * conditions of the Geant4 Software License      6 // * conditions of the Geant4 Software License,  included in the file *
  7 // * LICENSE and available at  http://cern.ch/      7 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
  8 // * include a list of copyright holders.           8 // * include a list of copyright holders.                             *
  9 // *                                                9 // *                                                                  *
 10 // * Neither the authors of this software syst     10 // * Neither the authors of this software system, nor their employing *
 11 // * institutes,nor the agencies providing fin     11 // * institutes,nor the agencies providing financial support for this *
 12 // * work  make  any representation or  warran     12 // * work  make  any representation or  warranty, express or implied, *
 13 // * regarding  this  software system or assum     13 // * regarding  this  software system or assume any liability for its *
 14 // * use.  Please see the license in the file      14 // * use.  Please see the license in the file  LICENSE  and URL above *
 15 // * for the full disclaimer and the limitatio     15 // * for the full disclaimer and the limitation of liability.         *
 16 // *                                               16 // *                                                                  *
 17 // * This  code  implementation is the result      17 // * This  code  implementation is the result of  the  scientific and *
 18 // * technical work of the GEANT4 collaboratio     18 // * technical work of the GEANT4 collaboration.                      *
 19 // * By using,  copying,  modifying or  distri     19 // * By using,  copying,  modifying or  distributing the software (or *
 20 // * any work based  on the software)  you  ag     20 // * any work based  on the software)  you  agree  to acknowledge its *
 21 // * use  in  resulting  scientific  publicati     21 // * use  in  resulting  scientific  publications,  and indicate your *
 22 // * acceptance of all terms of the Geant4 Sof     22 // * acceptance of all terms of the Geant4 Software license.          *
 23 // *******************************************     23 // ********************************************************************
 24 //                                                 24 //
 25 /// \file hadronic/Hadr02/include/HadronicInel     25 /// \file hadronic/Hadr02/include/HadronicInelasticModelCRMC.hh
 26 /// \brief Definition of the HadronicInelastic     26 /// \brief Definition of the HadronicInelasticModelCRMC class
 27 //                                                 27 //
 28 //                                                 28 //
 29 // -------------------------------------------     29 // ------------------------------------------------------------
 30 //                                                 30 //
 31 //              CRMC interface to GEANT4           31 //              CRMC interface to GEANT4
 32 //              for more details on CRMC, see:     32 //              for more details on CRMC, see:
 33 //              https://web.ikp.kit.edu/rulric     33 //              https://web.ikp.kit.edu/rulrich/crmc.html
 34 //                                                 34 //
 35 //                                                 35 //
 36 // Author:      Andrii Tykhonov  (University o     36 // Author:      Andrii Tykhonov  (University of Geneva)
 37 // Email:       andrii.tykhonov@cern.ch            37 // Email:       andrii.tykhonov@cern.ch
 38 // Created:     14.02.2018                         38 // Created:     14.02.2018
 39 //                                                 39 //
 40 //                                                 40 //
 41 // (                                               41 // (
 42 //   A few, trivial modifications made by A. R     42 //   A few, trivial modifications made by A. Ribon in May 2021
 43 //   in order to use it inside the Geant4 exam     43 //   in order to use it inside the Geant4 example Hadr02 :
 44 //   -  Copied here, instead of using the orig     44 //   -  Copied here, instead of using the original class
 45 //      G4HadronicInelasticModelCRMC as it is      45 //      G4HadronicInelasticModelCRMC as it is distributed
 46 //      with crmc-svn-geant4, to avoid some pr     46 //      with crmc-svn-geant4, to avoid some problems with CMake
 47 //      which is unable to find the library li     47 //      which is unable to find the library libGeantCrmc.
 48 //   -  Renamed the class as HadronicInelastic     48 //   -  Renamed the class as HadronicInelasticModelCRMC,
 49 //      to follow the Geant4 convention that c     49 //      to follow the Geant4 convention that classes whose
 50 //      names start with "G4" are only those d     50 //      names start with "G4" are only those distributed in
 51 //      source/ .                                  51 //      source/ .
 52 //   -  Fixed a few compilation warnings .         52 //   -  Fixed a few compilation warnings .
 53 //   -  Set the seed by hand, because the meth     53 //   -  Set the seed by hand, because the method
 54 //        CLHEP::HepRandom::getTheSeed()           54 //        CLHEP::HepRandom::getTheSeed()
 55 //      returns 0 which is not accepted.           55 //      returns 0 which is not accepted.
 56 // )                                               56 // )
 57 // -------------------------------------------     57 // ------------------------------------------------------------
 58                                                    58 
 59 #ifndef HadronicInelasticModelCRMC_h           <<  59 #ifndef  HadronicInelasticModelCRMC_h
 60 #define HadronicInelasticModelCRMC_h           <<  60 #define  HadronicInelasticModelCRMC_h
 61                                                    61 
 62 #include "CRMCinterface.h"                     << 
 63                                                << 
 64 #include "G4HadFinalState.hh"                  << 
 65 #include "G4HadronicInteraction.hh"                62 #include "G4HadronicInteraction.hh"
                                                   >>  63 #include "G4HadFinalState.hh"
 66 #include "G4SystemOfUnits.hh"                      64 #include "G4SystemOfUnits.hh"
 67                                                    65 
                                                   >>  66 #include "CRMCinterface.h"
 68 #include <string>                                  67 #include <string>
 69                                                    68 
                                                   >>  69 
 70 extern CRMCdata gCRMC_data;                        70 extern CRMCdata gCRMC_data;
 71                                                    71 
 72 class G4HadFinalState;                             72 class G4HadFinalState;
 73 class G4ParticleTable;                             73 class G4ParticleTable;
 74 class G4IonTable;                                  74 class G4IonTable;
 75                                                    75 
 76 class G4ParticleDefinition;  // class G4Dynami <<  76 
                                                   >>  77 class  G4ParticleDefinition; //class G4DynamicParticle; 
                                                   >>  78 
 77                                                    79 
 78 class HadronicInelasticModelCRMC : public G4Ha     80 class HadronicInelasticModelCRMC : public G4HadronicInteraction
 79 {                                                  81 {
 80   public:                                      <<  82 public:
 81     //! model:                                 <<  83   //! model: 
 82     //!         0  :  EPOS LHC                 <<  84   //!         0  :  EPOS LHC
 83     //!         1  :  EPOS 1.99                <<  85   //!         1  :  EPOS 1.99
 84     //!         12 :  DPMJET3                  <<  86   //!         12 :  DPMJET3
 85     HadronicInelasticModelCRMC(int model, cons <<  87   HadronicInelasticModelCRMC(int model, const G4String& modelName);
 86     ~HadronicInelasticModelCRMC();             <<  88   ~HadronicInelasticModelCRMC();
 87                                                <<  89 
 88     G4HadFinalState* ApplyYourself(const G4Had <<  90   G4HadFinalState * ApplyYourself (const G4HadProjectile &aTrack, G4Nucleus &targetNucleus);
 89     G4bool IsApplicable(const G4HadProjectile& <<  91   G4bool  IsApplicable (const G4HadProjectile &, G4Nucleus &);
 90                                                <<  92 
 91     void SetPrintDebug(bool printdebug) { fPri <<  93   void SetPrintDebug(bool printdebug) {fPrintDebug = printdebug;}
 92     G4ParticleDefinition* GetParticleDefinitio <<  94   G4ParticleDefinition* GetParticleDefinition(long particle_id,int& error_code); 
 93     void SplitMultiNeutrons(CRMCdata& CRMC_dat <<  95   void SplitMultiNeutrons(CRMCdata& CRMC_data);
 94     bool IsMultiNeutron(int Z, int A);         <<  96   bool IsMultiNeutron(int Z, int A);
 95                                                <<  97 
 96     virtual const std::pair<G4double, G4double <<  98   virtual const std::pair<G4double, G4double> GetFatalEnergyCheckLevels() const {
 97     {                                          <<  99     // possible energy non-coservations of up to 1 TeV are ignored
 98       // possible energy non-coservations of u << 100     return std::pair<G4double, G4double>( 10.0*perCent, 1000.0*GeV );
 99       return std::pair<G4double, G4double>(10. << 101   }
100     }                                          << 102 private:
101                                                << 103   CRMCinterface* fInterface;
102   private:                                     << 104   //CRMCdata fCRMCdata;
103     CRMCinterface* fInterface;                 << 105   int fTypeOutput;
104     // CRMCdata fCRMCdata;                     << 106   G4HadFinalState* finalState;
105     int fTypeOutput;                           << 107   G4ParticleTable* fParticleTable;
106     G4HadFinalState* finalState;               << 108   G4IonTable*      fIonTable;
107     G4ParticleTable* fParticleTable;           << 109 
108     G4IonTable* fIonTable;                     << 110   //std::vector<G4ParticleDefinition*> fParticleDefinitions;
109                                                << 111   //std::vector<G4DynamicParticle*>    fDynamicParticles;
110     // std::vector<G4ParticleDefinition*> fPar << 112   bool fPrintDebug;
111     // std::vector<G4DynamicParticle*>    fDyn << 113 
112     bool fPrintDebug;                          << 114   //
                                                   >> 115   std::string GetCrmcParamPath();
                                                   >> 116 
113                                                   117 
114     //                                         << 
115     std::string GetCrmcParamPath();            << 
116 };                                                118 };
117                                                   119 
118 #endif                                            120 #endif
119                                                   121