|Message: Re: How to retrieve various informations||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)|
Hi Maria, A good place to start is to compile some of the "NOVICE" examples that accompany the GEANT4 source code distribution. Its best to compile and run them, and get a feel for what the programs and then start rooting through the source code to see how the programs actually work. Example "N03" is probably the best place to start.
For your information retrieval purposes I'd specifically recommend looking at user action classes "ExN03EventAction.cc" and "ExN03SteppingAction.cc". These are classes where you, the user, have access to a veritable cornicopia of GEANT4-produced information. In the steppingAction class, you have access to the the G4Step pointer, which provides you with information such as energy depostion, step lengths, etc, but you can also use the member function "step -> GetTrack()" to obtain even more information (total trackLength, trackID, momentum, Kinetic Energy, all relevant particle creation("vertex") information)m etc). In the eventAction class, you'll find access to the G4Event pointer from which you can retrieve things like particleID etc.
You may find that in eventAction or your other user action classes that you'll want access to the pointers that you don't automatically get passed by GEANT4 (for instance, I make heavy use of the G4Track pointer in my eventAction classes). A handy little trick to grab the current pointers is to add the snippet of code found below :
currentTrack = G4RunManagerKernel::GetRunManagerKernel() -> GetTrackingManager() -> GetTrack(); (substitute "event" for "track" and "Tracking"and you'll get the current event ptr.)
Hope this helps! Good luck!
|Inline Depth:||Outline Depth:||Add message:|