4 #include "boost/lexical_cast.hpp"
18 #include "HepMC/GenEvent.h"
19 #include "HepMC/HeavyIon.h"
20 #include "HepMC/SimpleVector.h"
21 #include "CLHEP/Random/RandomEngine.h"
23 static const double pi = 3.14159265358979;
46 bmax_(
pset.getParameter<double>(
"bMax")),
47 bmin_(
pset.getParameter<double>(
"bMin")),
48 efrm_(
pset.getParameter<double>(
"comEnergy")),
52 iap_(
pset.getParameter<
int>(
"iap")),
53 izp_(
pset.getParameter<
int>(
"izp")),
54 iat_(
pset.getParameter<
int>(
"iat")),
55 izt_(
pset.getParameter<
int>(
"izt")),
56 amptmode_(
pset.getParameter<
int>(
"amptmode")),
57 ntmax_(
pset.getParameter<
int>(
"ntmax")),
58 dt_(
pset.getParameter<double>(
"dt")),
59 stringFragA_(
pset.getParameter<double>(
"stringFragA")),
60 stringFragB_(
pset.getParameter<double>(
"stringFragB")),
61 popcornmode_(
pset.getParameter<
bool>(
"popcornmode")),
62 popcornpar_(
pset.getParameter<double>(
"popcornpar")),
63 shadowingmode_(
pset.getParameter<
bool>(
"shadowingmode")),
64 quenchingmode_(
pset.getParameter<
bool>(
"quenchingmode")),
65 quenchingpar_(
pset.getParameter<double>(
"quenchingpar")),
66 pthard_(
pset.getParameter<double>(
"pthard")),
67 mu_(
pset.getParameter<double>(
"mu")),
68 izpc_(
pset.getParameter<
int>(
"izpc")),
69 alpha_(
pset.getParameter<double>(
"alpha")),
70 dpcoal_(
pset.getParameter<double>(
"dpcoal")),
71 drcoal_(
pset.getParameter<double>(
"drcoal")),
72 ks0decay_(
pset.getParameter<
bool>(
"ks0decay")),
73 phidecay_(
pset.getParameter<
bool>(
"phidecay")),
74 deuteronmode_(
pset.getParameter<
int>(
"deuteronmode")),
75 deuteronfactor_(
pset.getParameter<
int>(
"deuteronfactor")),
76 deuteronxsec_(
pset.getParameter<
int>(
"deuteronxsec")),
77 minijetpt_(
pset.getParameter<double>(
"minijetpt")),
78 maxmiss_(
pset.getParameter<
int>(
"maxmiss")),
79 doInitialAndFinalRadiation_(
pset.getParameter<
int>(
"doInitialAndFinalRadiation")),
80 ktkick_(
pset.getParameter<
int>(
"ktkick")),
81 diquarkembedding_(
pset.getParameter<
int>(
"diquarkembedding")),
82 diquarkpx_(
pset.getParameter<double>(
"diquarkpx")),
83 diquarkpy_(
pset.getParameter<double>(
"diquarkpy")),
84 diquarkx_(
pset.getParameter<double>(
"diquarkx")),
85 diquarky_(
pset.getParameter<double>(
"diquarky")),
89 rotate_(
pset.getParameter<
bool>(
"rotateEventPlane")) {}
100 HepMC::HeavyIon*
hi =
new HepMC::HeavyIon(
hmain1.jatt,
114 evt->set_heavy_ion(*
hi);
138 p->suggest_barcode(barcode);
145 HepMC::GenVertex*
vertex =
new HepMC::GenVertex(HepMC::FourVector(0, 0, 0, 0),
id);
170 HepMC::GenVertex* vertice;
173 vector<int> mother_ids;
174 vector<HepMC::GenVertex*> prods;
176 vertice =
new HepMC::GenVertex(HepMC::FourVector(0, 0, 0, 0), 0);
177 evt->add_vertex(vertice);
178 if (!
evt->signal_process_vertex())
179 evt->set_signal_process_vertex(vertice);
181 const unsigned int knumpart =
hbt.nlast;
182 for (
unsigned int ipart = 0; ipart < knumpart; ipart++) {
186 mother_ids.push_back(mid);
187 LogDebug(
"DecayChain") <<
"Mother index : " << mid;
192 for (
unsigned int ipart = 0; ipart <
particles.size(); ipart++) {
195 int mid = mother_ids[ipart];
196 LogDebug(
"DecayChain") <<
"Particle " << ipart;
197 LogDebug(
"DecayChain") <<
"Mother's ID " << mid;
198 LogDebug(
"DecayChain") <<
"Particle's PDG ID " <<
part->pdg_id();
201 vertice->add_particle_out(
part);
207 LogDebug(
"DecayChain") <<
"Mother's PDG ID " << mother->pdg_id();
209 HepMC::GenVertex* prod_vertex = mother->end_vertex();
211 prod_vertex = prods[ipart];
212 prod_vertex->add_particle_in(mother);
213 evt->add_vertex(prod_vertex);
214 prods[ipart] =
nullptr;
216 prod_vertex->add_particle_out(
part);
221 for (
unsigned int i = 0;
i < prods.size();
i++) {
241 strlen(
frame.data()),
243 strlen(
targ.data()));