19 #include "TEveTrack.h"
20 #include "TParticle.h"
21 #include "TDatabasePDG.h"
43 static Bool_t bAdded = kFALSE;
49 TDatabasePDG* pdgDB = TDatabasePDG::Instance();
50 const Int_t kspe = 50000000;
55 const Int_t kion = 1000000000;
61 const Double_t khSlash = 1.0545726663e-27;
62 const Double_t kErg2Gev = 1 / 1.6021773349e-3;
63 const Double_t khShGev = khSlash * kErg2Gev;
64 const Double_t kYear2Sec = 3600 * 24 * 365.25;
70 pdgDB->AddParticle(
"Upsilon(3S)",
"Upsilon(3S)", 10.3552, kTRUE, 0, 1,
"Bottonium", 200553);
73 pdgDB->AddParticle(
"rho_diff0",
"rho_diff0", 0, kTRUE, 0, 0,
"QCD diffr. state", 9900110);
74 pdgDB->AddParticle(
"pi_diffr+",
"pi_diffr+", 0, kTRUE, 0, 1,
"QCD diffr. state", 9900210);
75 pdgDB->AddParticle(
"omega_di",
"omega_di", 0, kTRUE, 0, 0,
"QCD diffr. state", 9900220);
76 pdgDB->AddParticle(
"phi_diff",
"phi_diff", 0, kTRUE, 0, 0,
"QCD diffr. state", 9900330);
77 pdgDB->AddParticle(
"J/psi_di",
"J/psi_di", 0, kTRUE, 0, 0,
"QCD diffr. state", 9900440);
78 pdgDB->AddParticle(
"n_diffr0",
"n_diffr0", 0, kTRUE, 0, 0,
"QCD diffr. state", 9902110);
79 pdgDB->AddParticle(
"p_diffr+",
"p_diffr+", 0, kTRUE, 0, 1,
"QCD diffr. state", 9902210);
82 pdgDB->AddParticle(
"PSID ",
" ", 3.7699, kFALSE, 0.0, 0,
"meson", 30443);
84 pdgDB->AddParticle(
"A_00 ",
" ", 0.9960, kFALSE, 0.0, 0,
"meson", 9000111);
85 pdgDB->AddParticle(
"A_0+ ",
" ", 0.9960, kFALSE, 0.0, +3,
"meson", 9000211);
86 pdgDB->AddParticle(
"A_0- ",
" ", 0.9960, kFALSE, 0.0, -3,
"meson", -9000211);
88 pdgDB->AddParticle(
"F0P0 ",
" ", 0.9960, kFALSE, 0.0, 0,
"meson", 9010221);
90 pdgDB->AddParticle(
"KDL_2+ ",
" ", 1.773, kFALSE, 0.0, +3,
"meson", 10325);
91 pdgDB->AddParticle(
"KDL_2- ",
" ", 1.773, kFALSE, 0.0, -3,
"meson", -10325);
93 pdgDB->AddParticle(
"KDL_20 ",
" ", 1.773, kFALSE, 0.0, 0,
"meson", 10315);
94 pdgDB->AddParticle(
"KDL_2BR0",
" ", 1.773, kFALSE, 0.0, 0,
"meson", -10315);
96 pdgDB->AddParticle(
"PI_2+ ",
" ", 1.670, kFALSE, 0.0, +3,
"meson", 10215);
97 pdgDB->AddParticle(
"PI_2- ",
" ", 1.670, kFALSE, 0.0, -3,
"meson", -10215);
98 pdgDB->AddParticle(
"PI_20 ",
" ", 1.670, kFALSE, 0.0, 0,
"meson", 10115);
100 pdgDB->AddParticle(
"KD*+ ",
" ", 1.717, kFALSE, 0.0, +3,
"meson", 30323);
101 pdgDB->AddParticle(
"KD*- ",
" ", 1.717, kFALSE, 0.0, -3,
"meson", -30323);
103 pdgDB->AddParticle(
"KD*0 ",
" ", 1.717, kFALSE, 0.0, 0,
"meson", 30313);
104 pdgDB->AddParticle(
"KDBR*0 ",
" ", 1.717, kFALSE, 0.0, 0,
"meson", -30313);
106 pdgDB->AddParticle(
"RHOD+ ",
" ", 1.700, kFALSE, 0.0, +3,
"meson", 30213);
107 pdgDB->AddParticle(
"RHOD- ",
" ", 1.700, kFALSE, 0.0, -3,
"meson", -30213);
108 pdgDB->AddParticle(
"RHOD0 ",
" ", 1.700, kFALSE, 0.0, 0,
"meson", 30113);
110 pdgDB->AddParticle(
"ETA_2(L)",
" ", 1.632, kFALSE, 0.0, 0,
"meson", 10225);
111 pdgDB->AddParticle(
"ETA_2(H)",
" ", 1.854, kFALSE, 0.0, 0,
"meson", 10335);
112 pdgDB->AddParticle(
"OMEGA(H)",
" ", 1.649, kFALSE, 0.0, 0,
"meson", 30223);
114 pdgDB->AddParticle(
"KDH_2+ ",
" ", 1.816, kFALSE, 0.0, +3,
"meson", 20325);
115 pdgDB->AddParticle(
"KDH_2- ",
" ", 1.816, kFALSE, 0.0, -3,
"meson", -20325);
117 pdgDB->AddParticle(
"KDH_20 ",
" ", 1.816, kFALSE, 0.0, 0,
"meson", 20315);
118 pdgDB->AddParticle(
"KDH_2BR0",
" ", 1.816, kFALSE, 0.0, 0,
"meson", -20315);
120 pdgDB->AddParticle(
"KD_3+ ",
" ", 1.773, kFALSE, 0.0, +3,
"meson", 327);
121 pdgDB->AddParticle(
"KD_3- ",
" ", 1.773, kFALSE, 0.0, -3,
"meson", -327);
123 pdgDB->AddParticle(
"KD_30 ",
" ", 1.773, kFALSE, 0.0, 0,
"meson", 317);
124 pdgDB->AddParticle(
"KD_3BR0 ",
" ", 1.773, kFALSE, 0.0, 0,
"meson", -317);
126 pdgDB->AddParticle(
"RHO_3+ ",
" ", 1.691, kFALSE, 0.0, +3,
"meson", 217);
127 pdgDB->AddParticle(
"RHO_3- ",
" ", 1.691, kFALSE, 0.0, -3,
"meson", -217);
128 pdgDB->AddParticle(
"RHO_30 ",
" ", 1.691, kFALSE, 0.0, 0,
"meson", 117);
129 pdgDB->AddParticle(
"OMEGA_3 ",
" ", 1.667, kFALSE, 0.0, 0,
"meson", 227);
130 pdgDB->AddParticle(
"PHI_3 ",
" ", 1.854, kFALSE, 0.0, 0,
"meson", 337);
132 pdgDB->AddParticle(
"CHI2P_B0",
" ", 10.232, kFALSE, 0.0, 0,
"meson", 110551);
133 pdgDB->AddParticle(
"CHI2P_B1",
" ", 10.255, kFALSE, 0.0, 0,
"meson", 120553);
134 pdgDB->AddParticle(
"CHI2P_B2",
" ", 10.269, kFALSE, 0.0, 0,
"meson", 100555);
135 pdgDB->AddParticle(
"UPSLON4S",
" ", 10.580, kFALSE, 0.0, 0,
"meson", 300553);
143 Int_t ionCode = kion + 10020;
144 if (!pdgDB->GetParticle(ionCode)) {
145 pdgDB->AddParticle(
"Deuteron",
"Deuteron", 1.875613, kTRUE, 0, 3,
"Ion", ionCode);
147 pdgDB->AddAntiParticle(
"AntiDeuteron", -ionCode);
149 ionCode = kion + 10030;
150 if (!pdgDB->GetParticle(ionCode)) {
151 pdgDB->AddParticle(
"Triton",
"Triton", 2.80925, kFALSE, khShGev / (12.33 * kYear2Sec), 3,
"Ion", ionCode);
153 pdgDB->AddAntiParticle(
"AntiTriton", -ionCode);
155 ionCode = kion + 20030;
156 if (!pdgDB->GetParticle(ionCode)) {
157 pdgDB->AddParticle(
"HE3",
"HE3", 2.80923, kFALSE, 0, 6,
"Ion", ionCode);
159 pdgDB->AddAntiParticle(
"AntiHE3", -ionCode);
161 ionCode = kion + 20040;
162 if (!pdgDB->GetParticle(ionCode)) {
163 pdgDB->AddParticle(
"Alpha",
"Alpha", 3.727417, kTRUE, khShGev / (12.33 * kYear2Sec), 6,
"Ion", ionCode);
165 pdgDB->AddAntiParticle(
"AntiAlpha", -ionCode);
169 pdgDB->AddParticle(
"Cherenkov",
"Cherenkov", 0, kFALSE, 0, 0,
"Special", kspe + 50);
170 pdgDB->AddParticle(
"FeedbackPhoton",
"FeedbackPhoton", 0, kFALSE, 0, 0,
"Special", kspe + 51);
171 pdgDB->AddParticle(
"Lambda1520",
"Lambda1520", 1.5195, kFALSE, 0.0156, 0,
"Resonance", 3124);
172 pdgDB->AddAntiParticle(
"Lambda1520bar", -3124);
179 iItem->
get(collection);
181 if (
nullptr == collection) {
193 for (std::vector<SimTrack>::const_iterator it = collection->begin(),
end = collection->end(); it !=
end; ++it) {
201 vx = hitColl->at(vInd).position().x();
202 vy = hitColl->at(vInd).position().y();
203 vz = hitColl->at(vInd).position().z();
204 vt = hitColl->at(vInd).position().t();
207 TParticle* particle =
new TParticle;
208 particle->SetPdgCode(iData.
type());
210 particle->SetProductionVertex(vx, vy, vz, vt);
212 TEveTrack*
track =
new TEveTrack(particle, ++i, propagator);
213 if (iData.
charge() == 0) {
214 track->SetLineStyle(7);
216 track->AddPathMark(TEvePathMark(
217 TEvePathMark::kReference,
const math::XYZVectorD & trackerSurfacePosition() const
const fireworks::Context & context() const
#define REGISTER_PROXYBUILDER_METHODS()
#define REGISTER_FWPROXYBUILDER(_name_, _type_, _purpose_, _view_)
FWSimTrackProxyBuilder(void)
static const int kAllRPZBits
void setupAddElement(TEveElement *el, TEveElement *parent, bool set_color=true) const
void get(const T *&oData) const
TEveTrackPropagator * getTrackPropagator() const
float charge() const
charge
const FWEventItem * item() const
static const int kAll3DBits
~FWSimTrackProxyBuilder(void) override
int vertIndex() const
index of the vertex in the Event container (-1 if no vertex)
const edm::EventBase * getEvent() const
const math::XYZTLorentzVectorD & trackerSurfaceMomentum() const
int type() const
particle type (HEP PDT convension)
bool getByLabel(InputTag const &, Handle< T > &) const
const math::XYZTLorentzVectorD & momentum() const
void addParticlesToPdgDataBase(void)
const FWSimTrackProxyBuilder & operator=(const FWSimTrackProxyBuilder &)=delete
std::vector< SimTrack > SimTrackContainer