02.05.2014 Views

PENELOPE 2003 - OECD Nuclear Energy Agency

PENELOPE 2003 - OECD Nuclear Energy Agency

PENELOPE 2003 - OECD Nuclear Energy Agency

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

3.3. Bremsstrahlung emission 117<br />

This sampling algorithm is exact and very fast [notice that the binary search in step<br />

(i) requires at most 5 comparisons], but is only applicable for the energies in the grid<br />

where χ is tabulated.<br />

To simulate bremsstrahlung emission by electrons with energies E not included in the<br />

grid, we should first obtain the PDF p(E, κ) by interpolation along the energy axis and<br />

then perform the random sampling of κ from this PDF using the algorithm described<br />

above. This procedure is too time consuming. A faster method consists of assuming<br />

that the grid of energies is dense enough so that linear interpolation in ln E is sufficiently<br />

accurate. If E i < E < E i+1 , we can express the interpolated PDF as<br />

with<br />

p int (E, κ) = π i p(E i , κ) + π i+1 p(E i+1 , κ) (3.157)<br />

π i = ln E i+1 − ln E<br />

ln E i+1 − ln E i<br />

, π i+1 = ln E − ln E i<br />

ln E i+1 − ln E i<br />

. (3.158)<br />

These “interpolation weights” are positive and add to unity, i.e. they can be interpreted<br />

as point probabilities. Therefore, to perform the random sampling of κ from p int (E, κ)<br />

we can employ the composition method (section 1.2.5), which leads to the following<br />

algorithm:<br />

(i) Sample the integer variable I, which can take the values i or i + 1 with point<br />

probabilities π i and π i+1 , respectively.<br />

(ii) Sample κ from the distribution p int (E I , κ).<br />

With this “interpolation by weight” method we only need to sample κ from the tabulated<br />

PDFs, i.e. for the energies E i of the grid.<br />

Angular distribution of emitted photons<br />

The random sampling of cos θ is simplified by noting that the PDF given by eq. (3.151)<br />

results from a Lorentz transformation, with speed β ′ , of the PDF (3.148). This means<br />

that we can sample the photon direction cos θ ′ in the reference frame K ′ from the PDF<br />

(3.148) and then apply the transformation (3.149) (with β ′ instead of β) to get the<br />

direction cos θ in the laboratory frame.<br />

To generate random values of cos θ from (3.151) we use the following algorithm,<br />

which combines the composition and rejection methods,<br />

(i) Sample a random number ξ 1 .<br />

(ii) If ξ 1 < A, then<br />

1) Sample a random number ξ and set cos θ ′ = −1 + 2ξ.<br />

2) Sample a random number ξ.<br />

3) If 2ξ > 1 + cos 2 θ ′ , go to 1).

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!