Skip to content

Commit ee38f1f

Browse files
committed
Central PbPb generator with strangeness
1 parent ba91459 commit ee38f1f

File tree

5 files changed

+697
-0
lines changed

5 files changed

+697
-0
lines changed
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[Diamond]
2+
width[2]=6.0
3+
4+
[GeneratorExternal]
5+
fileName=${O2DPG_MC_CONFIG_ROOT}/MC/config/ALICE3/pythia8/generator_pythia8_central_strangeness_gun_PbPb.C
6+
funcName=generatePYTHIA()
7+
8+
[GeneratorPythia8]
9+
config=${O2DPG_MC_CONFIG_ROOT}/MC/config/ALICE3/pythia8/generator/pythia8_central_hi.cfg
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
int External()
2+
{
3+
std::string path{"o2sim_Kine.root"};
4+
5+
TFile file(path.c_str(), "READ");
6+
if (file.IsZombie()) {
7+
std::cerr << "Cannot open ROOT file " << path << "\n";
8+
return 1;
9+
}
10+
11+
auto tree = (TTree *)file.Get("o2sim");
12+
if (!tree) {
13+
std::cerr << "Cannot find tree o2sim in file " << path << "\n";
14+
return 1;
15+
}
16+
17+
std::vector<o2::MCTrack> *tracks{};
18+
tree->SetBranchAddress("MCTrack", &tracks);
19+
auto nEvents = tree->GetEntries();
20+
int nTracks = 0;
21+
for (int i = 0; i < nEvents; i++) {
22+
tree->GetEntry(i);
23+
nTracks += tracks->size();
24+
}
25+
26+
const int meanNTracksPerEvent = nTracks / nEvents;
27+
28+
// Expecting only events with a 0-10% centrality
29+
// 0-100% gives a mean of ~1350
30+
31+
if (meanNTracksPerEvent < 1300) {
32+
return 1;
33+
}
34+
35+
return 0;
36+
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
### Specify beams
2+
Beams:idA = 1000822080
3+
Beams:idB = 1000822080
4+
Beams:eCM = 5520.0 ### energy
5+
6+
Beams:frameType = 1
7+
ParticleDecays:limitTau0 = on
8+
ParticleDecays:tau0Max = 10. ### match alice: 1cm/c = 10.0mm/c
9+
10+
### Initialize the Angantyr model to fit the total and semi-includive
11+
### cross sections in Pythia within some tolerance.
12+
HeavyIon:SigFitErr = 0.02,0.02,0.1,0.05,0.05,0.0,0.1,0.0
13+
14+
### These parameters are typicall suitable for sqrt(S_NN)=5TeV
15+
HeavyIon:SigFitNGen = 0
16+
HeavyIon:SigFitDefPar = 13.88,1.84,0.22,0.0,0.0,0.0,0.0,0.0
17+
HeavyIon:bWidth = 4.43
18+
19+
20+
Random:setSeed = on
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
### beams
2+
Beams:idA 1000822080 # Pb
3+
Beams:idB 1000822080 # Pb
4+
Beams:eCM 5520. # GeV
5+
6+
### heavy-ion settings (valid for Pb-Pb 5520 only)
7+
HeavyIon:SigFitNGen = 0
8+
HeavyIon:SigFitDefPar = 13.88,1.84,0.22,0.0,0.0,0.0,0.0,0.0
9+
HeavyIon:bWidth = 4.43
10+
11+
### processes (apparently not to be defined)
12+
13+
### decays
14+
ParticleDecays:limitTau0 on
15+
ParticleDecays:tau0Max 0.001
16+
17+
! 2) Seed settings
18+
! Seed is set inside the generator
19+
! If run on the grid, seed is set to job id
20+
! If run locally, seed is set to 0
21+
Random:setSeed = on ! Random seed on

0 commit comments

Comments
 (0)