SND@LHC Software
Loading...
Searching...
No Matches
g4Ex_gap.MyTrackingAction Class Reference
Inheritance diagram for g4Ex_gap.MyTrackingAction:
Collaboration diagram for g4Ex_gap.MyTrackingAction:

Public Member Functions

 PostUserTrackingAction (self, atrack)
 
 PreUserTrackingAction (self, atrack)
 

Detailed Description

Definition at line 295 of file g4Ex_gap.py.

Member Function Documentation

◆ PostUserTrackingAction()

g4Ex_gap.MyTrackingAction.PostUserTrackingAction (   self,
  atrack 
)

Definition at line 296 of file g4Ex_gap.py.

296 def PostUserTrackingAction(self,atrack):
297 pass

◆ PreUserTrackingAction()

g4Ex_gap.MyTrackingAction.PreUserTrackingAction (   self,
  atrack 
)

Definition at line 298 of file g4Ex_gap.py.

298 def PreUserTrackingAction(self,atrack):
299# need to be careful with energy cut, anti-protons and anti-neutrons can always produce pions and kaons
300 part = atrack.GetDynamicParticle()
301 pid = part.GetPDGcode()
302 muCut = JpsiMainly and abs(pid)!=13
303 qed = pid in qedlist # use cut only for photons, electrons, protons and neutrons
304 if (atrack.GetKineticEnergy()/GeV < ecut and (qed or allPart) ) or muCut :
305 G4TrackingManager().SetStoreTrajectory(False)
306 atrack.SetTrackStatus(atrack.GetTrackStatus().fStopAndKill)
307
308# ------------------------------------------------------------------

The documentation for this class was generated from the following file: