18#ifndef GENERATORMODULESEVTDECAY_H
19#define GENERATORMODULESEVTDECAY_H
21#include "HepMC/GenEvent.h"
22#include "HepMC/GenParticle.h"
30#include "GaudiKernel/Algorithm.h"
31#include "GaudiKernel/ISvcLocator.h"
32#include "GaudiKernel/NTuple.h"
34#include "CLHEP/Random/Ranlux64Engine.h"
41#include "DataInfoSvc/IDataInfoSvc.h"
42#include "DataInfoSvc/DataInfoSvc.h"
62 HepRandomEngine* m_engine;
68 EvtDecay(
const string& name, ISvcLocator* pSvcLocator);
77double ampsLenu(vector<double> Vexp,std::vector<double> vpars);
78double ampsLbenu(vector<double> Vexp,std::vector<double> vpars);
79double HV(
double i,
double j,vector<double> Vexp, std::vector<double> vpars);
80double HA(
double i,
double j,vector<double> Vexp, std::vector<double> vpars);
84 StatusCode callEvtGen( HepMC::GenEvent* hepMCevt );
85 StatusCode callBesEvtGen( HepMC::GenEvent* hepMCevt );
86 StatusCode makeHepMC(
EvtParticle*, HepMC::GenEvent*, HepMC::GenParticle*);
91 void MeVToGeV(HepMC::GenEvent* hepMCevt);
92 void GeVToMeV(HepMC::GenEvent* hepMCevt);
94 void ReadTruth(
EvtParticle* part,std::vector<std::vector<string> > mylist);
97 int isNumber(
double d);
105 vector<long int> m_seeds;
109string m_DecayDec, m_PdtTable, userDecFileName,m_DecayTop,m_DecayRec, m_ParentPart;
111 std::ofstream outfile,outfile2,truth;
112 std::vector<int> m_InSeeds;
114 bool _mDIY,m_RdMeasuredEcms;
117 bool m_Ncharge,m_NtupleFile, m_Psi4040OpenCharm, m_Psi2openCharm, m_statDecays;
119 int AllTrk_index,Trk_index[500];
127 string m_SB3File, m_SB3HT;
133 int pdg0,pdg1,pdg2,pdg,multi;
140 string m_FDPparticle;
146 int br[500],vbr[500];
148 bool isCharmonium(
EvtId xid);
149 bool isCharm(
EvtId xid);
157 std::vector<std::string> m_mystring;
158 std::vector<double> m_wind0,m_wind1,m_wind2;
159 std::vector<int> m_cluster0,m_cluster1,m_cluster2;
161 std::vector<std::vector<std::string> > m_ReadTruth;
163 double m_eBeamPolarization;
166 std::vector<double> m_polarization;
167 std::string m_truthFile,m_truthPart;
169NTuple::Tuple* m_tuple;
170NTuple::Item<int> TotNumTrk;
171NTuple::Item<int> m_nchr;
172NTuple::Item<int> m_nchr_e;
173NTuple::Item<int> m_nchr_mu;
174NTuple::Item<int> m_nchr_pi;
175NTuple::Item<int> m_nchr_k;
176NTuple::Item<int> m_nchr_p;
177NTuple::Item<int> m_gamma;
178NTuple::Item<int> m_gammaFSR;
179NTuple::Item<int> m_flag1;
181NTuple::Array<int> m_Trk_index;
182NTuple::Array<int> m_fst;
183NTuple::Array<double> m_px_trk;
184NTuple::Array<double> m_py_trk;
185NTuple::Array<double> m_pz_trk;
186NTuple::Array<double> m_en_trk;
188NTuple::Tuple* mass_tuple;
189NTuple::Item<double> m_m12;
190NTuple::Item<double> m_m13;
191NTuple::Item<double> m_m23;
192NTuple::Item<double> m_m1;
193NTuple::Item<double> m_m2;
194NTuple::Item<double> m_m3;
195NTuple::Item<double> m_cos1;
196NTuple::Item<double> m_cos2;
197NTuple::Item<double> m_cos3;
198NTuple::Item<int> m_ich;
199NTuple::Tuple* massgen_tuple;
200NTuple::Item<double> _m12;
201NTuple::Item<double> _m13;
202NTuple::Item<double> _m23;
203NTuple::Item<double> _m1;
204NTuple::Item<double> _m2;
205NTuple::Item<double> _m3;
206NTuple::Item<double> _cos1;
207NTuple::Item<double> _cos2;
208NTuple::Item<double> _cos3;
209NTuple::Item<int> _ich;
double ampsLenu(vector< double > Vexp, std::vector< double > vpars)
DataInfoSvc * dataInfoSvc
IDataInfoSvc * tmpInfoSvc
double getObsXsection(double mhds, int mode)
double ampsLbenu(vector< double > Vexp, std::vector< double > vpars)
double HV(double i, double j, vector< double > Vexp, std::vector< double > vpars)
double HA(double i, double j, vector< double > Vexp, std::vector< double > vpars)
manage multiple CLHEP random engines as named streams