111 if (GetVerboseLevel()>0) {
112 G4cout <<
"G4DPMJET2_5Model default constructor" <<
G4endl;
121 PrintWelcomeMessage();
125 theExcitationHandler = 0;
126 SetDefaultPreCompoundModel();
132 SetMinEnergy(5.0*
GeV);
133 SetMaxEnergy(1000.0*
TeV);
135 SetEnergyMomentumCheckLevels(100*
perCent, 1*
TeV);
157 theGlauberDataSetHandler->SetMaxGlauberDataSets(-1);
160 theIonTable = const_cast <
G4IonTable *> (theParticleTable->GetIonTable());
165 const std::pair<G4double, G4double>
169 return std::pair<G4double, G4double>(100.*
perCent, 500 *
GeV);
199 theInitType = initType;
200 PrintWelcomeMessage();
204 theExcitationHandler = 0;
268 theInitType = initType;
269 PrintWelcomeMessage();
273 theExcitationHandler = aExcitationHandler;
338 theInitType = initType;
339 PrintWelcomeMessage();
343 theExcitationHandler = 0;
344 thePreComp = aPreComp;
389 if (theExcitationHandler)
delete theExcitationHandler;
390 if (thePreComp)
delete thePreComp;
415 if (AP >= 2 && ZP >= 1 && AT >= 2 && ZT >=1) {
490 G4cout <<
"########################################"
491 <<
"########################################"
496 G4cout <<
"Initial projectile (A,Z) = (" <<AP <<
", " <<ZP <<
")" <<
G4endl;
497 G4cout <<
"Initial target (A,Z) = (" <<AT <<
", " <<ZT <<
")" <<
G4endl;
522 if (AP1 > 1 && AP1 == ZP1) {
527 G4cout <<
"PROJECTILE WITH AP = " <<AP1 <<
" == ZP = " <<ZP1
529 G4cout <<
"########################################"
530 <<
"########################################"
561 G4double ppn = std::sqrt((epn-mpn)*(epn+mpn));
587 nncms_.
umo = std::sqrt(mpn*mpn + mpnt*mpnt + 2.0*mpnt*epn);
626 if ( theInitType ==
DEFAULT ) {
635 }
else if ( theInitType ==
CORSIKA ) {
645 else if ( theInitType ==
DPM2_5 ) {
657 else if ( theInitType ==
DPM3 ) {
756 G4cout <<
"REJECTED KKINC EVENT. RETRY # = " <<evtcnt <<
G4endl;
765 kkinc_ (&epn, &AT1, &ZT1, &AP1, &ZP1, &iiipro, &kkmat, &iiitar, &nhkkh1,
770 }
while (irej == 1 && ++evtcnt <100);
773 theGlauberDataSetHandler->ResetCurrentGlauberDataSet();
780 theParticleChange.SetStatusChange(
isAlive);
783 if (verboseLevel >= 2) {
784 G4cout <<
"Event rejected and original track maintained" <<
G4endl;
785 G4cout <<
"########################################"
786 <<
"########################################"
789 return &theParticleChange;
799 if (verboseLevel >= 2) DumpVerboseInformation1 (n);
804 for (
G4int ii=0; ii<
n; ii++)
826 theParticleChange.AddSecondary (theDynamicParticle);
828 if (verboseLevel >= 2)
845 if (nucA>0 && nucZ>0) {
851 G4double ionMass = theIonTable->GetIonMass(nucZ,nucA);
854 if (dpmMass > ionMass) ionMass = dpmMass;
855 G4double et = std::sqrt(px*px + py*py + pz*pz + ionMass*ionMass);
858 if (verboseLevel >= 2)
859 DumpVerboseInformation3 (M1, nucA, nucZ, lv.
vect(),
867 if (fragment && (thePreComp || theExcitationHandler))
870 if (thePreComp && fragment->
GetA() > 1.5)
871 products = thePreComp->DeExcite(*fragment);
873 products = theExcitationHandler->BreakItUp(*fragment);
876 G4ReactionProductVector::iterator iter;
877 for (iter = products->begin(); iter != products->end(); ++iter)
881 (*iter)->GetTotalEnergy(), (*iter)->GetMomentum());
882 theParticleChange.AddSecondary (secondary);
884 (*iter)->GetDefinition()->GetParticleName();
886 if (verboseLevel >= 2) {
887 if (particleName.find(
"[",0) < particleName.size())
888 DumpVerboseInformation4 (
m, particleName,
892 else DumpVerboseInformation2 (particleName,
913 theParticleChange.AddSecondary (theDynamicParticle);
921 if (verboseLevel >= 3) {
933 G4int nSecondaries = theParticleChange.GetNumberOfSecondaries();
934 for (
G4int j=0; j<nSecondaries; j++) {
935 TotalEPost += theParticleChange.GetSecondary(j)->
936 GetParticle()->GetTotalEnergy();
937 TotalPPost += theParticleChange.GetSecondary(j)->
938 GetParticle()->GetMomentum();
940 GetParticle()->GetDefinition();
946 G4cout <<
"----------------------------------------"
947 <<
"----------------------------------------"
949 G4cout <<
"Total energy before collision = " <<TotalEPre/
MeV
951 G4cout <<
"Total energy after collision = " <<TotalEPost/
MeV
953 G4cout <<
"Total momentum before collision = " <<pP/
MeV
955 G4cout <<
"Total momentum after collision = " <<TotalPPost/
MeV
957 if (verboseLevel >= 4) {
958 G4cout <<
"Total charge before collision = " <<(ZP+ZT)*
eplus
960 G4cout <<
"Total charge after collision = " <<charge
962 G4cout <<
"Total baryon number before collision = "<<AP+AT
964 G4cout <<
"Total baryon number after collision = "<<baryon
966 G4cout <<
"Total lepton number before collision = 0"
968 G4cout <<
"Total lepton number after collision = "<<lepton
971 G4cout <<
"----------------------------------------"
972 <<
"----------------------------------------"
976 if (verboseLevel >= 2)
977 G4cout <<
"########################################"
978 <<
"########################################"
981 return &theParticleChange;
999 if (theExcitationHandler)
1001 delete theExcitationHandler;
1002 theExcitationHandler = 0;
1077 if (filename ==
"" || filename ==
"stdo" ||
1078 filename ==
"stdout" || filename ==
"std::out" )
1080 verboseFortranFile =
"std::out";
1085 G4int namelen = filename.length();
1086 char *ptr =
new char[namelen+1];
1087 filename.copy(ptr,namelen,0);
1088 ptr[namelen] =
'\0';
1094 if (opened == LTRUE) {
1095 verboseFortranFile = filename;
1098 verboseFortranFile =
"std::out";
1107 void G4DPMJET2_5Model::PrintWelcomeMessage ()
const
1110 G4cout <<
" *****************************************************************"
1112 G4cout <<
" Interface to DPMJET2.5 for nuclear-nuclear interactions activated"
1114 G4cout <<
" Version number : 00.00.0B File date : 23/05/08" <<
G4endl;
1115 G4cout <<
" (Interface written by QinetiQ Ltd for the European Space Agency)"
1118 G4cout <<
" Initialisation of DPMJET-II.5 variables will be according to "
1120 G4cout <<
" *****************************************************************"
1133 void G4DPMJET2_5Model::DumpVerboseInformation1 (
const G4int n)
const
1135 G4cout <<
"----------------------------------------"
1136 <<
"----------------------------------------" <<
G4endl;
1137 G4cout <<n <<
" INTERMEDIATE AND FINAL-STATE SECONDARIES PRODUCED" <<
G4endl;
1140 G4cout <<
"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
1141 <<
"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~" <<
G4endl;
1142 G4cout <<
"ORIGINAL DPMJET-II.5 OUTPUT FOR EVENT:" <<
G4endl;
1143 G4cout <<
"Note that (1) the particles are yet to be transformed according"
1146 G4cout <<
" (2) the units of energy, momentum and mass are GeV,"
1160 for (
G4int i=0; i<
n; i++)
1162 G4cout.unsetf(std::ios::scientific);
1165 G4cout <<std::setw(5) <<i
1170 G4cout.unsetf(std::ios::fixed);
1180 G4cout <<
"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
1181 <<
"~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~" <<
G4endl;
1183 G4cout.setf(std::ios::fixed);
1184 G4cout <<
" THE FOLLOWING LISTS ONLY THE FINAL-STATE SECONDARIES" <<
G4endl;
1189 void G4DPMJET2_5Model::DumpVerboseInformation2
1201 G4cout <<
" Transverse mass = " <<std::sqrt(E*E-pz*pz)/
MeV
1205 <<0.5*std::log((E+pz)/(E-pz)) <<
G4endl;
1211 void G4DPMJET2_5Model::DumpVerboseInformation3 (
const G4int i,
1215 G4cout <<
"----------------------------------------"
1216 <<
"----------------------------------------" <<
G4endl;
1217 G4cout <<
"The nuclear fragment #" <<i <<
" before" <<
G4endl;
1218 G4cout <<
"----------------------------------------"
1219 <<
"----------------------------------------" <<
G4endl;
1221 std::ostringstream tmpStream;
1222 tmpStream <<
"(A = " <<A <<
", Z = " <<Z <<
")";
1225 DumpVerboseInformation2(AZ, p, E, T, pinit);
1230 void G4DPMJET2_5Model::DumpVerboseInformation4 (
const G4int i,
1234 G4cout <<
"----------------------------------------"
1235 <<
"----------------------------------------" <<
G4endl;
1236 G4cout <<
"The nuclear fragment #" <<i <<
" after" <<
G4endl;
1237 G4cout <<
"----------------------------------------"
1238 <<
"----------------------------------------" <<
G4endl;
1240 DumpVerboseInformation2(particleName, p, E, T, pinit);
1253 void G4DPMJET2_5Model::Initialise ()
1279 for (
G4int i=0; i<50; i++)
1317 for (
G4int i=0; i<7; i++)
1323 for (
G4int i=0; i<3; i++)
1384 parpt_ (&i,&pt1,&pt2,&ipt,&nevt);
1405 if ( theInitType ==
DEFAULT ) {
1408 }
else if ( theInitType ==
CORSIKA ) {
1411 }
else if ( theInitType ==
DPM2_5 ) {
1414 }
else if ( theInitType ==
DPM3 ) {
1431 if ( theInitType ==
DEFAULT ) {
1437 }
else if ( theInitType ==
CORSIKA ) {
1443 }
else if ( theInitType ==
DPM2_5 ) {
1449 }
else if ( theInitType ==
DPM3 ) {
1468 if ( theInitType ==
DEFAULT ) {
1473 }
else if ( theInitType ==
CORSIKA ) {
1478 }
else if ( theInitType ==
DPM2_5 ) {
1483 }
else if ( theInitType ==
DPM3 ) {
1496 if ( theInitType ==
DEFAULT ) {
1498 }
else if ( theInitType ==
CORSIKA ) {
1500 }
else if ( theInitType ==
DPM2_5 ) {
1502 }
else if ( theInitType ==
DPM3 ) {
1514 if ( theInitType ==
DEFAULT ) {
1518 }
else if ( theInitType ==
CORSIKA ) {
1522 }
else if ( theInitType ==
DPM2_5 ) {
1526 }
else if ( theInitType ==
DPM3 ) {
1579 }
else if ( theInitType ==
DPM2_5 ) {
1581 }
else if ( theInitType ==
DPM3 ) {
1627 if ( theInitType ==
DEFAULT ) {
1632 }
else if ( theInitType ==
CORSIKA ) {
1637 }
else if ( theInitType ==
DPM2_5 ) {
1642 }
else if ( theInitType ==
DPM3 ) {
1707 if ( theInitType ==
DEFAULT ) {
1714 }
else if ( theInitType ==
CORSIKA ) {
1721 }
else if ( theInitType ==
DPM2_5 ) {
1728 }
else if ( theInitType ==
DPM3 ) {
1739 verboseFortranFile =
"fort.6";
1740 G4int namelen = verboseFortranFile.length();
1741 char *ptr1 =
new char[namelen+1];
1742 verboseFortranFile.copy(ptr1,namelen,0);
1743 ptr1[namelen] =
'\0';
1748 if (opened == LFALSE)
1750 G4cout <<
"ATTEMPTED TO OPEN fort.6 TO OUTPUT VERBOSE FORTRAN TEXT"
1757 G4cout <<
"AT G4DPMJET2_5Model::Initialise: before NUCLEAR.BIN" <<
G4endl;
1758 G4cout <<
"OPENING NUCLEAR.BIN ON FILE UNIT " <<lunber <<
G4endl;
1761 if ( !getenv(
"G4DPMJET2_5DATA") )
1763 G4cout <<
"ENVIRONMENT VARIABLE G4DPMJET2_5DATA NOT SET " <<
G4endl;
1765 "Please setenv G4DPMJET2_5DATA to point to the dpmjet2.5 data files.");
1767 defaultDirName =
G4String(getenv(
"G4DPMJET2_5DATA")) +
"/NUCLEAR.BIN";
1768 namelen = defaultDirName.length();
1769 ptr1 =
new char[namelen+1];
1770 defaultDirName.copy(ptr1,namelen,0);
1771 ptr1[namelen] =
'\0';
1776 if (opened == LFALSE)
1782 G4cout <<
"NUCLEAR.BIN FILE NOT FOUND IN DIRECTORY " <<defaultDirName
1785 "NUCLEAR.BIN file not present.");
1789 G4cout <<
"AT G4DPMJET2_5Model::Initialise: after NUCLEAR.BIN" <<
G4endl;
1798 G4cout <<
"AT G4DPMJET2_5Model::Initialise: before INCINI" <<
G4endl;
1803 G4cout <<
"AT G4DPMJET2_5Model::Initialise: after INCINI" <<
G4endl;
1809 G4cout <<
"AT G4DPMJET2_5Model::Initialise: NUCLEAR.BIN closed" <<
G4endl;
1825 G4cout <<
"Printout of important Parameters before DPMJET2.5" <<
G4endl;
1826 G4cout <<
"Please note for DPMJET input all numbers are floating point!"
1843 G4cout <<
"RANDOMIZ " <<iseed1 <<
" "
1847 G4cout <<
"SELHARD " <<0 <<
" "
1853 G4cout <<
"SIGMAPOM " <<0 <<
" "
struct ccdpm25cmhico cmhico_
G4bool IsGlauberDataSetAvailable(const G4int AP, const G4int AT) const
struct ccdpm25sigma sigma_
G4double AtomicMass(const G4double A, const G4double Z) const
void SetMaxGlauberDataSets(const G4int n)
struct ccdpm25colle colle_
struct ccdpm25ncoucs ncoucs_
struct ccdpm25evappp evappp_
struct ccdpm25pydat1 pydat1_
G4double GetKineticEnergy() const
G4double GetTotalEnergy() const
double dot(const Hep3Vector &) const
struct ccdpm25pomtyp pomtyp_
struct ccdpm25nncms nncms_
struct ccdpm25diqsum diqsum_
struct ccdpm25parevt parevt_
G4bool SetVerboseFortranOutput(const G4String filename)
struct ccdpm25final final_
struct ccdpm25paname paname_
struct ccdpm25strufu strufu_
virtual ~G4DPMJET2_5Model()
void g4dpmjet_open_nuclear_bin_(int *, int *, int *, char *)
struct ccdpm25bufues bufues_
struct ccdpm25nstari nstari_
struct ccdpm25secint secint_
struct ccdpm25taufo taufo_
double rd2out_(int *, int *)
struct ccdpm25user1 user1_
struct ccdpm25coulo coulo_
const G4String & GetParticleName() const
void g4dpmjet_close_nuclear_bin_(int *)
struct ccdpm25ferfor ferfor_
struct ccdpm25xseadi xseadi_
struct ccdpm25cronin cronin_
void SetStatusChange(G4HadFinalStateStatus aS)
struct ccdpm25pomtab pomtab_
std::vector< G4ReactionProduct * > G4ReactionProductVector
struct ccdpm25dtumat dtumat_
void g4dpmjet_open_fort6_(int *, int *, char *)
struct ccdpm25seadiq seadiq_
void SetMinEnergy(G4double anEnergy)
void g4dpmjet_close_fort6_()
struct ccdpm25vxsvd vxsvd_
struct ccdpm25ptsamp ptsamp_
G4IonTable * GetIonTable() const
void SetDefaultPreCompoundModel()
G4GLOB_DLL std::ostream G4cout
virtual G4int GetVerboseLevel() const
const G4ParticleDefinition * GetDefinition() const
virtual G4bool IsApplicable(const G4HadProjectile &theTrack, G4Nucleus &theTarget)
struct ccdpm25zentra zentra_
struct ccdpm25casadi casadi_
void SetVerboseLevel(G4int)
G4double GetKineticEnergy() const
void SetFermiModel(G4VFermiBreakUp *ptr)
struct ccdpm25xsecpt xsecpt_
struct ccdpm25inpflg inpflg_
struct ccdpm25nucimp nucimp_
G4ErrorTarget * theTarget
virtual G4HadFinalState * ApplyYourself(const G4HadProjectile &, G4Nucleus &)
G4int UnloadAllGlauberData()
void csj1mi_(double *, double *)
struct ccdpm25sincha sincha_
struct ccdpm25extevt extevt_
struct ccdpm25hdjase hdjase_
struct ccdpm25dropjj dropjj_
struct ccdpm25seasu3 seasu3_
void SetNoPreCompoundModel()
struct ccdpm25ptlarg ptlarg_
const G4LorentzVector & Get4Momentum() const
struct ccdpm25droppt droppt_
struct ccdpm25kglaub kglaub_
void g4dpmjet_initialise_block_data_()
void parpt_(int *, double *, double *, int *, int *)
void kkinc_(double *, int *, int *, int *, int *, int *, int *, int *, int *, int *)
struct ccdpm25popcck popcck_
void SetEnergyChange(G4double anEnergy)
struct ccdpm25stars stars_
void defaul_(double *, double *)
struct ccdpm25frbkcm frbkcm_
struct ccdpm25collap collap_
G4double GetPDGMass() const
static G4ParticleTable * GetParticleTable()
struct ccdpm25diffra diffra_
struct ccdpm25ifragm ifragm_
void SetMaxAandZForFermiBreakUp(G4int anA, G4int aZ)
struct ccdpm25user2 user2_
G4bool SetCurrentGlauberDataSet(const G4int AP, const G4int AT, const G4double ppn=0.0)
struct ccdpm25collis collis_
Definition of the G4DPMJET2_5Interface class.
void SetEvaporation(G4VEvaporation *ptr)
struct ccdpm25diqrej diqrej_
void SetMaxEnergy(const G4double anEnergy)
G4HadFinalState theParticleChange
struct ccdpm25hkkevt hkkevt_
struct ccdpm25seaqxx seaqxx_
virtual const std::pair< G4double, G4double > GetFatalEnergyCheckLevels() const
struct ccdpm25nuclea nuclea_
Definition of the G4GlaubAADataSetHandler class.
struct ccdpm25pshow pshow_
G4DPMJET2_5InitialisationType
void SetDefaultDeexcitation()
static G4GlaubAADataSetHandler * getInstance()
struct ccdpm25dprin dprin_
struct ccdpm25edens edens_
G4double GetPDGCharge() const
void SetPhotonEvaporation(G4VEvaporationChannel *ptr)
struct ccdpm25promu promu_
void defaux_(double *, double *)
void SetMomentumChange(const G4ThreeVector &aV)
G4int GetLeptonNumber() const
struct ccdpm25gluspl gluspl_
struct ccdpm25diquax diquax_
struct ccdpm25popcor popcor_
struct ccdpm25fluctu fluctu_
G4ThreeVector GetMomentum() const
struct ccdpm25hettp hettp_
void samppt_(int *, double *)
G4int GetBaryonNumber() const
Definition of the G4DPMJET2_5Model class.
struct ccdpm25hadthr hadthr_
G4double GetTotalEnergy() const
CLHEP::HepLorentzVector G4LorentzVector
struct ccdpm25recom recom_