Message: Specify GPS energy distribution using an ASCII file Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Specify GPS energy distribution using an ASCII file 

Forum: Event and Track Management
Date: 24 Jan, 2014
From: C Griffin <C Griffin>

Dear all,

I am currently trying to simulate an experiment carried out by a colleague in which the energy distribution of the primary 
particles is known, and for which I have an ASCII file.

I have read through the manual and examples provided by QinetiQ (
and, from my understanding of the user manual, I must specify that I want to use a user-defined histogram of type energy. Thus, 
the relevant section of my current macro file reads:

/gps/position 0 0 -10 cm
/gps/direction 0 0 1
/gps/ene/type User
/gps/hist/type energy
/gps/hist/file file_name.dat 

But, after much work, I am still unable to get the simulation to use the ASCII file as the source for the energy distribution, 
it merely assigns the default value of 1MeV to all primary particles generated.

(Note: the ASCII file is simply two columns, the first being the energy bin in MeV, 
the seond the weight of that bin)

Any help is much appreciated,
Thanks in advance,


 Add Message Add Message
to: "Specify GPS energy distribution using an ASCII file"

 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 ]