Message: killing a G4Track and recording the energy Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question killing a G4Track and recording the energy 

Forum: Event and Track Management
Date: 24 Apr, 2013
From: Jeremy McCormick <Jeremy McCormick>

Hello,

I would like to implement functionalty in my extension of the G4Region class for killing tracks. I would also like to somehow record the energy of the stopped track by getting the processHits() method called on the sensitive detector assigned to that volume, where the track is killed.

I think I know what to try in order to kill the track, but what is the best way of getting the energy readout using the sensitive detector? I know that I can directly access the track's energy using GetKineticEnergy(), GetTotalEnergy(), but how can I get the track to deposit its energy into the volume when it is killed? My main goal would be to avoid any custom code for recording the energy, e.g. in SteppingAction, as I would prefer to activate the sensitive detector that has been assigned to the volume.

I found an old thread asking a similar question here:

http://hypernews.slac.stanford.edu:5090/HyperNews/geant4/get/eventtrackmanage/90/1.html

But there's no follow-up to the reply which asks how to record the energy.

Thanks.

--Jeremy

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Feedback: Re: killing a G4Track and recording the energy   (Gumplinger Peter - 24 Apr, 2013)
1 More: Re: killing a G4Track and recording the energy   (Gumplinger Peter - 24 Apr, 2013)
1 None: Re: killing a G4Track and recording the energy   (michel maire - 25 Apr, 2013)
2 Question: Re: killing a G4Track and recording the energy   (Jeremy McCormick - 29 Apr, 2013)
1 Feedback: Re: killing a G4Track and recording the energy   (Gumplinger Peter - 29 Apr, 2013)
3 Question: Re: killing a G4Track and recording the energy   (Jeremy McCormick - 29 Apr, 2013)
1 Feedback: Re: killing a G4Track and recording the energy   (Gumplinger Peter - 29 Apr, 2013)
 Add Message Add Message
to: "killing a G4Track and recording the energy"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]