45 catch(UInt_t iparticle){
46 std::cerr <<
"ERROR(StructuredG4Tree::GetParticle): index out of bounds (NSim =" 47 <<
NSim() <<
" vs. requested index = " << iparticle <<
")" <<
std::endl;
78 auto v =
new vector<const TLorentzVector*>();
79 for(
size_t ireg=0; ireg<
NRegions(iparticle); ireg++){
80 v->push_back(
GetParticle(iparticle)->MomentumEnter(ireg));
86 auto v =
new vector<const TLorentzVector*>();
87 for(
size_t ireg=0; ireg<
NRegions(iparticle); ireg++){
88 v->push_back(
GetParticle(iparticle)->MomentumExit(ireg));
94 auto v =
new vector<const TLorentzVector*>();
95 for(
size_t ireg=0; ireg<
NRegions(iparticle); ireg++){
96 v->push_back(
GetParticle(iparticle)->PositionEnter(ireg));
102 auto v =
new vector<const TLorentzVector*>();
103 for(
size_t ireg=0; ireg<
NRegions(iparticle); ireg++){
104 v->push_back(
GetParticle(iparticle)->PositionExit(ireg));
const int ParentPDG(const UInt_t &iparticle) const override
parent particle's PDG code
const TLorentzVector * MomentumEnter(const size_t &iregion) const
int const & NPoints() const
const UInt_t NSim() const override
number of particles
int const & ProcessI() const
const int ParentTrackID(const UInt_t &iparticle) const override
G4 track ID of parent particle.
const UInt_t NPoints(const UInt_t &iparticle) const override
number of G4 steps (i.e. trajectory points)
TTree * fTreeIn
pointer to the analyzed TTree or TChain
const TLorentzVector * MomentumExit(const size_t &iregion) const
int const & ParentTrackID() const
const bool IsPrimary(const UInt_t &iparticle) const override
did particle come from generator?
const vector< const TLorentzVector * > * SimMomEnter(const UInt_t &iparticle) const override
particle 4-momentum at entry point, all regions
vector< UInt_t > * fG4TruthIndex
const Int_t ProcessF(const UInt_t &iparticle) const override
code for process that killed this one
const TLorentzVector * PositionExit(const size_t &iregion) const
int const & ParentPDG() const
const vector< const TLorentzVector * > * SimMomExit(const UInt_t &iparticle) const override
particle 4-momentum at exit point, all regions
int const & ProcessF() const
const UInt_t NRegions(const UInt_t &iparticle) const override
number of regions traversed by particle
vector< G4Particle > * fG4Particles
'condensed' nusimdata::MCParticles from G4
StructuredG4Tree(TTree *tree=0)
const TLorentzVector * PositionEnter(const size_t &iregion) const
int const & TrackID() const
void SetupRead(TTree *tree)
bool SetBranchAddresses() override
const Int_t ProcessI(const UInt_t &iparticle) const override
code for process that created this one
const Int_t PDG(const UInt_t &iparticle) const override
particle PDG code
int Region(const size_t &iregion) const
const vector< const TLorentzVector * > * SimPosEnter(const UInt_t &iparticle) const override
particle 4-position at entry point, all regions
const G4Particle * GetParticle(const UInt_t &iparticle) const
const Int_t Region(const UInt_t &iparticle, const UInt_t &iregion) const override
region number
const int TrackID(const UInt_t &iparticle) const override
G4 track ID (can be <0 if it fell below trking threshold)
const vector< const TLorentzVector * > * SimPosExit(const UInt_t &iparticle) const override
particle 4-position at exit point, all regions
const int ProgenitorTrackID(const UInt_t &iparticle) const override
G4 track ID of primary that led this one.
int const & ProgenitorPDG() const
const int ProgenitorPDG(const UInt_t &iparticle) const override
PDG of primary that led this one.
Int_t fEvent
event number for tree entry
int const & ProgenitorTrackID() const
QTextStream & endl(QTextStream &s)