Problem 798

Summary: uniform external source for G4GeneralParticleSource
Product: Geant4 Reporter: jasondet
Component: eventAssignee: Fan.Lei
Status: RESOLVED INVALID    
Severity: enhancement    
Priority: P2    
Version: 7.1   
Hardware: All   
OS: All   

Description jasondet 2005-09-27 18:47:53 CEST
It would be nice if there were a way to produce a uniform external source using
the GPS. This would be useful, for example, for simulating cosmic muon spectra
or external gamma rays.

The idea is as follows: the user would provide the radius R of a bounding sphere
for his/her volume. When it is time to generate an event, first a momentum
direction p^hat is simulated (according to whatever angular distribution the
user prefers). Then the position of the event is chosen randomly on a disk of
radius R whose normal points in the direction p^hat and whose center is at the
vertex -R*p^hat. This gives a uniform flux of events impingent on the detector
in the direction p^hat.

Jason
Comment 1 flei 2005-09-29 03:14:59 CEST
All these are already possible in GPS,if I understood your requirments
correctly. Please refer to the helps available at the command line or its
user manual(http://reat.space.qinetiq.com/gps/new_gps_sum_files/gps_sum.htm).
Further examples  GPS usage can be found in the "exgps" extended example.