8 eCM = runArgs.ecmEnergy
9 eBeam = runArgs.ecmEnergy*0.5
11 if runArgs.trfSubstepName ==
'afterburn':
13 msg.info(
"Running in Afterburner mode, beam eCM is not set")
14 elif 'Pythia' in evgenConfig.generators:
15 genSeq.Pythia.PythiaCommand.append(
"pyinit win %s" % eCM)
16 elif 'PythiaB' in evgenConfig.generators:
17 genSeq.PythiaB.PythiaCommand.append(
"pyinit win %s" % eCM)
18 elif 'PythiaRhad' in evgenConfig.generators:
19 genSeq.PythiaRhad.PythiaCommand.append(
"pyinit win %s" % eCM)
20 elif 'PythiaChL' in evgenConfig.generators:
21 genSeq.PythiaChL.PythiaCommand.append(
"pyinit win %s" % eCM)
22 elif 'PythiaGS' in evgenConfig.generators:
23 genSeq.PythiaGS.PythiaCommand.append(
"pyinit win %s" % eCM)
24 elif 'PythiaResMod' in evgenConfig.generators:
25 genSeq.PythiaResMod.PythiaCommand.append(
"pyinit win %s" % eCM)
26 elif 'PythiaTopMdiff' in evgenConfig.generators:
27 genSeq.PythiaTopMdiff.PythiaCommand.append(
"pyinit win %s" % eCM)
28 elif 'Pythia8' in evgenConfig.generators:
29 genSeq.Pythia8.CollisionEnergy = eCM
30 elif 'Pythia8B' in evgenConfig.generators:
31 genSeq.Pythia8B.CollisionEnergy = eCM
32 elif 'Herwig' in evgenConfig.generators:
33 genSeq.Herwig.HerwigCommand.append(
"beam1energy %s" % eBeam)
34 genSeq.Herwig.HerwigCommand.append(
"beam2energy %s" % eBeam)
35 elif 'Herwigpp' in evgenConfig.generators:
36 genSeq.Herwigpp.Commands.append(
"set /Herwig/Generators/LHCGenerator:EventHandler:LuminosityFunction:Energy %s" % eCM)
39 elif 'Sherpa' in evgenConfig.generators:
40 if os.environ[
"SHERPAVER"].startswith(
'3.'):
41 genSeq.Sherpa_i.BaseFragment = genSeq.Sherpa_i.BaseFragment.replace(
"$(EBEAMSETBYATHENA)",
"%s" % eBeam)
43 genSeq.Sherpa_i.Parameters.append(
"BEAM_ENERGY_1=%s" % eBeam)
44 genSeq.Sherpa_i.Parameters.append(
"BEAM_ENERGY_2=%s" % eBeam)
45 elif 'Epos' in evgenConfig.generators:
46 genSeq.Epos.BeamMomentum = -eBeam
47 genSeq.Epos.TargetMomentum = eBeam
48 elif 'QGSJet' in evgenConfig.generators:
49 genSeq.QGSJet.BeamMomentum = -eBeam
50 genSeq.QGSJet.TargetMomentum = eBeam