Message: Re: Counting particles entering a volume. Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: Counting particles entering a volume. 

Keywords: counting, photons
Forum: Event and Track Management
Re: Question Counting particles entering a volume. (Kostas Kousouris)
Date: 09 Feb, 2004
From: michel maire <michel maire>

User Kostas Kousouris wrote:

>> Hello everybody,
>> I am doing a very simple simulation: if I throw some photons on a piece
>> of Au, of some thikness, I want to count how many of them will pass
>> without interacting (obviously I want to measure the corresponding
>> efficiency !!). Does anybody know how to count the passing photons
>> easily? Thank's, in advance.
>> Kostas Kousouris

 In examples/extended/electromagnetic/TestEm3, you will find the


 void SteppingAction::UserSteppingAction(const G4Step* aStep)
  const G4Track* track = aStep->GetTrack();
  G4VPhysicalVolume* volume = aStep->GetPreStepPoint()->GetPhysicalVolume();

  // energy leaving each volume
  if (track->GetNextVolume() != volume) {


 In TestEm5, there are another examples of such counting.

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

1 Question: Re: Counting particles entering a volume.   (Mayur Paunipagar - Feb 19, 03:22)
 Add Message Add Message
to: "Re: Counting particles entering a volume."

 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 ]