|Message: Re: Sensitive detector to secondary particles||Not Logged In (login)|
Click on the Forum title, e.g. on the "Forums by Category" page, to read a sequence of postings to the Forum and its threads all in one page. If you are only interested in one thread or the thread following a specific posting, click the thread or the posting, which takes you to a smaller page, which contains only the part you are interested in and may be easier to navigate.
Messages are "chained" if there are only replies at the first level, i.e. 1/1.html, 1/1/1.html etc. In case of "chained" messages the message number is replaced by the icon and there is no indentation.
Inline: Display the subject line only or also the text of the posting(s); for the choice "All" the "Outline" choices are switched off.
|1||0||1||no text / full text of posting|
|2||1||All||text for level 1 only / text for All postings|
Outline: Choose the depth of the posting thread, successive toggle controls provide increasing detail.
|1||2||1||2 levels / 1 level (original posting)|
|2||3||2||3 levels / 2 levels|
|3||3||All||3 levels / all levels (all postings)|
Dear Annette, Please let me remind a few basics of how the simulation works. Geant4 starts with -say- a primary particle generated by the primary generator action. This primary is then tracked, step by step, by Geant4. When doing a step, Geant4 invokes all necessary physics computation, and leads to: - an energy deposit in the current material during this current step - a change of energy/momentum of this primary - a potential creation of secondary particles, coming from interactions during this step. This step by step progression continues up to the point the primary is killed (by interaction, or leaving the world volume). Then one of the produced secondary (by default the last one) is taken by Geant4, and this becomes the current primary particle. The same above step by step game is played, with secondaries creation, etc. The event simulation is finished when the particles (generated by the primary generator action, or subsequently by any interactions) have been all tracked and finally killed. The secondary particles are, as you understood, G4Track objects. You can actually know in your G4VSensitiveDetector what are the secondary particles produced by the current primary. But please note, at the very point it has been created, that you will not be able to get any information on a secondary energy deposit: this will and can only come when this secondary will be tracked. I hope these explanations will help you to reconsider how to organize your sensitive detector code. Also, for further help, you may provide a bit more information on your setup. Cheers, Marc On 04/09/2013 12:34 PM, Annette Pressman wrote: > *** Discussion title: Event and Track Management > > I've been looking at alternatives to making the detector sensitive and > would like to check - it seems that secondary particles are G4Track > objects. Does this mean that I cannot get the TotalEnergyDepost G4Step > information about the secondaries in the way I can for the primaries? I > am very much a novice programmer and really want to find out if I'm > going down a dead end or not. Thanks for your help. Annette > > On Mon, 01 Apr 2013 20:45:40 GMT, Annette Pressman wrote: > >> Hi, I'm trying to make an absorber sensitive to synchrotron radiation >> from an electron beam to obtain the deposited energy. I've tried >> emulating examples B2 and B4d from the basic examples but in both >> versions of my code I get a segmentation violation at >> SensitiveDetector::ProcessHits(G4Step*, G4TouchableHistory*)() (in the >> B2 version) and at G4PSEnergyDeposit::ProcessHits(G4Step*, >> G4TouchableHistory*)() in the B4d version. I feel I must be missing >> something, probably quite simple, could anyone point me in the right >> direction? Many thanks! Annette >> > ------------------------------------------------------------- > Visit this GEANT4 at hypernews.slac.stanford.edu message (to reply or unsubscribe) at: > http://hypernews.slac.stanford.edu/HyperNews/geant4/get/eventtrackmanage/1105/1.html
|Inline Depth:||Outline Depth:||Add message:|