Message: Problem with angular distribution of primary particles Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

Question Problem with angular distribution of primary particles 

Forum: Geometry
Date: 24 Oct, 2013
From: Kendall <Kendall>

Hi everyone,

I am experiencing a subtle problem in generating the proper direction of my primary particles. I am at a point in my problem solving where I thought it would be best to ask for some advice.

A very quick overview of my set up is as follows: I have a 6 layered detector that is meant to detect cosmic ray muons. These particles have a fairly well-defined angular and energy distribution. The muons are generated at random positions on the top plane of the world in my simulation and the angle should follow a cos squared theta distribution for the angle from the vertical (phi is generated randomly between 0 and 2pi). For theta, if you consider 0 to be in the "up" direction, then you expect to see particles generated between theta = 90 degrees and theta = 180 degrees.

theta is sampled from a cos squared distribution. phi is sampled uniformly between 0 and 2pi.

From these angles I then calculate the unit direction vector to give to the particleGun.

u = sin(theta)*cos(phi) v = cos(theta) w = sin(theta)*sin(phi)


I am certain that theta and phi are being generated properly. But when I look at the angle from vertical of the particles within the simulation (ie as soon as they have entered the world) there is a problem. Looking at a histogram of theta within the simulation, there are a significant number of bins that are empty very close to the 180 degree point (these bins should have thousands of entries). And the "180 degree" bin is far too full. Is it possible that the particle gun is only able to take a certain number of decimal places for its momentum direction vector? The only solution I feel is left is that the particle gun is rounding my u, v and w values. Though, I could be very very wrong with this.

If anyone has any insight I would be extremely thankful. And if I haven't explained the problem with enough clarity, please don't hesitate to ask for more information.

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

1 None: Re: Problem with angular distribution of primary particles   (Kendall - 28 Oct, 2013)
2 Question: Re: Problem with angular distribution of primary particles   (Vahagn Ivanyan - Jan 02, 09:01)
 Add Message Add Message
to: "Problem with angular distribution of primary particles"

 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 ]