22 mPndPidChargedCand(0),
65 cout <<
"-E- " <<
"EicEventAssembler::Init(): "
66 <<
"FairRootManager not instantiated!" << endl;
72 std::cout <<
"-E- EicSmearTask::Init: No MCTrack array found!" << std::endl;
81 extraTree->Add(ioman->
GetInFile()->GetName());
98 cout <<
"-E- " <<
"EicEventAssembler::Init(): "
99 <<
"EicRootManager failed to instantiate!" << endl;
118 for(
unsigned cl=0; cl<particle->
mCellGroups.size(); cl++) {
131 for(std::map<std::pair<UInt_t, UInt_t>, Double_t>::iterator
it=group->
mEnergyPerParent.begin();
149 for(
unsigned eh=0; eh<2; eh++) {
163 #define _PHOTON_PDG_CODE_ 22
164 #define _PION_PDG_CODE_ 211
165 #define _POSITRON_PDG_CODE_ (-11)
194 if (diff > 0.0 || fabs(diff/sigma) < 3.0)
256 if (particle->
mHCal) {
258 double fullCalorimeterEnergy = 0.0, fullCalorimeterEnergySigma = 0.0;
259 for(
unsigned eh=0; eh<2; eh++) {
262 fullCalorimeterEnergy += hit->
mEnergy;
265 fullCalorimeterEnergySigma = sqrt(fullCalorimeterEnergySigma);
268 double wtE = 1./(fullCalorimeterEnergySigma*fullCalorimeterEnergySigma);
271 double E = (wtE*fullCalorimeterEnergy + wtP*particle->
mRcVtxMomentum.Mag())/(wtE+wtP);
285 if (!beamLepton)
return;
324 TTree *outputTree =
new TTree(
_EIC_RC_TREE_,
"A tree of reconstructed events");
401 for(
unsigned cl=0; cl<chub->
mClusters->GetEntriesFast(); cl++) {
411 for(std::map<std::pair<UInt_t, UInt_t>, Double_t>::iterator
it=group->
mEnergyPerParent.begin();
416 particle->
mCellGroups.push_back(std::pair<unsigned, unsigned>(ct, cl));
435 std::set<unsigned> registered;
437 for(std::map<std::pair<UInt_t, UInt_t>, Double_t>::iterator
it=group->
mEnergyPerParent.begin();
439 if (registered.find(
it->first.second) == registered.end()) {
443 particle->
mCellGroups.push_back(std::pair<unsigned, unsigned>(ct, cl));
446 registered.insert(
it->first.second);
482 smearedTree->Write();