Skip to content
Snippets Groups Projects
Commit c2006a22 authored by John Kenneth Anders's avatar John Kenneth Anders Committed by Atlas Nightlybuild
Browse files

Merge branch '21.0_RHadronStableSim' into '21.0'

Updates to R-Hadron simulation for stable particles

See merge request atlas/athena!22260

(cherry picked from commit 14eab4a8c9dd22641625dca562e66f3615153d6d)

b7ae9c40 Updates to R-Hadron simulation for stable particles
64573c26 Fixing a typo
parent 43c54beb
No related branches found
No related tags found
No related merge requests found
...@@ -113,11 +113,19 @@ G4ProcessHelper::G4ProcessHelper() ...@@ -113,11 +113,19 @@ G4ProcessHelper::G4ProcessHelper()
G4cout<<"Gamma = "<<gamma/CLHEP::GeV<<" GeV"<<G4endl; G4cout<<"Gamma = "<<gamma/CLHEP::GeV<<" GeV"<<G4endl;
G4cout<<"Amplitude = "<<amplitude/CLHEP::millibarn<<" millibarn"<<G4endl; G4cout<<"Amplitude = "<<amplitude/CLHEP::millibarn<<" millibarn"<<G4endl;
G4cout<<"ReggeSuppression = "<<100*suppressionfactor<<" %"<<G4endl; G4cout<<"ReggeSuppression = "<<100*suppressionfactor<<" %"<<G4endl;
G4cout<<"HadronLifeTime = "<<hadronlifetime; if (doDecays) G4cout<<" ns"<<G4endl; else G4cout<<" s"<<G4endl; G4cout<<"HadronLifeTime = "<<hadronlifetime;
if (doDecays) G4cout<<" ns"<<G4endl;
else G4cout<<" s"<<G4endl;
G4cout<<"ReggeModel = "<< reggemodel <<G4endl; G4cout<<"ReggeModel = "<< reggemodel <<G4endl;
G4cout<<"Mixing = "<< mixing*100 <<" %"<<G4endl; G4cout<<"Mixing = "<< mixing*100 <<" %"<<G4endl;
G4cout<<"DoDecays = "<< doDecays << G4endl; G4cout<<"DoDecays = "<< doDecays << G4endl;
if ((!doDecays && hadronlifetime>0.) ||
(doDecays && hadronlifetime<=0.) ){
G4cout << "WARNING: Inconsistent treatment of R-Hadron properties! Lifetime of " << hadronlifetime
<< " and doDecays= " << doDecays << G4endl;
}
checkfraction = 0; checkfraction = 0;
n_22 = 0; n_22 = 0;
n_23 = 0; n_23 = 0;
......
...@@ -174,16 +174,22 @@ load_files_for_rhadrons_scenario('SLHA_INPUT.DAT',spectrum) ...@@ -174,16 +174,22 @@ load_files_for_rhadrons_scenario('SLHA_INPUT.DAT',spectrum)
# Add any lines that were missing # Add any lines that were missing
# In case we want to use Pythia8 for decays during simulation # In case we want to use Pythia8 for decays during simulation
lifetime = float(simdict['LIFETIME']) if simdict.has_key("LIFETIME") else -1. lifetime = float(simdict['LIFETIME']) if simdict.has_key("LIFETIME") else -1.
if lifetime<1. and hasattr(runArgs,'outputEVNT_TRFile'): if lifetime>0.:
rhlog.warning('Lifetime specified at <1ns, but you are writing stopped particle positions.') if lifetime<1. and hasattr(runArgs,'outputEVNT_TRFile'):
rhlog.warning('Assuming that you mean to use infinite lifetimes, and ignoring the setting') rhlog.warning('Lifetime specified at <1ns, but you are writing stopped particle positions.')
rhlog.warning('Assuming that you mean to use infinite lifetimes, and ignoring the setting')
else:
addLineToPhysicsConfiguration("DoDecays","1")
addLineToPhysicsConfiguration("HadronLifeTime", str(lifetime))
# If we reading particle records, and the lifetime is short, stop them as well
if lifetime<1. and hasattr(runArgs,'inputEVNT_TRFile'):
addLineToPhysicsConfiguration("DoDecays","1")
addLineToPhysicsConfiguration("HadronLifeTime", 0.000001)
else: else:
addLineToPhysicsConfiguration("DoDecays","1") # Stable case. Can be unset lifetime or lifetime=0 or lifetime=-1
addLineToPhysicsConfiguration("HadronLifeTime", str(lifetime)) addLineToPhysicsConfiguration("DoDecays","0")
# If we reading particle records, and the lifetime is short, stop them as well addLineToPhysicsConfiguration("HadronLifeTime", -1)
if lifetime<1. and hasattr(runArgs,'inputEVNT_TRFile'):
addLineToPhysicsConfiguration("DoDecays","1")
addLineToPhysicsConfiguration("HadronLifeTime", 0.000001)
# Capture Pythia8 commands # Capture Pythia8 commands
# Set up R-hadron masses in Pythia8 # Set up R-hadron masses in Pythia8
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment