Message: Problem again about generating multiple primary events Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Problem again about generating multiple primary events 

Keywords: multiple primary events
Forum: Event and Track Management
Date: 02 Oct, 2003
From: Yoshihisa Yamamoto <>


I'm describing program for beaming 100 keV gamma ray into scintillator with the interval of 500mm 300 times. So I wrote this way...

  void T00PrimaryGeneratorAction::GeneratePrimaries(G4Event* anEvent)
  G4int nPrimaries = 300;
       for(int i=0;i<nPrimaries;i++)
  G4double x0 = 0.5*i*mm;    
  G4double y0 = 0.*mm; 
  G4double z0 = 1.*m;

But it does not work as follows.
First I shoot photn $/run/beamOn 300 and set gamma ray energy 10 keV 
But the output is 
Edep= 0.829925 MeV
Edep= 0.8 MeV
    (three hundred lines)   
Edep= 0.789872 MeV
Edep= 0.82971 MeV

The input energy is 10 keV. So it is incredible! Maybe I must make mistake anywhere. My guess is that trying another nPrimaries Edep is according to the nPrimaries,so Edep is counted as sum of nPrimaries gamma ray. But I don't have solution. Plese give me advice.

 Best regards.
                                  Yoshihisa Yamamoto
                                Tokyo Institute of Technology

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

 Add Message Add Message
to: "Problem again about generating multiple primary events"

 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 ]