ne.gif (2791 bytes)     NE582 Monte Carlo
                            Spring semester 1998

Return to Course Outline


 

Lesson 5 - Techniques for Common PDFs

We will wrap up our study of techniques for choosing random numbers according to PDFs with a quick overview of the choices that we will be normally making in the course of following a particle in a Monte Carlo transport calculation. 

The lifecycle decisions that we will look at are: 

  1. Particle initial position
  2. Particle initial direction
  3. Particle initial energy
  4. Distance to next collision
  5. Type of collision
  6. Outcome of a scattering event

Particle initial position

Decisions about the initial position of a particle is usually at multidimensional parameter determination based on a given position distribution over volume, wpeB8.gif (1062 bytes).  The mathematical approach to this is to define this function in terms of an appropriate coordinate system and then independently choose random numbers in each of the dimensions according to that dimension's "part" of the total distribution.  This is best demonstrated by example, so we shall look at the three typical spatial coordinate systems: Cartesian, cylindrical, and spherical.

Cartesian coordinate system

The classic shape in Cartesian coordinate system is a right parallelpiped (i.e., 3D rectangle) in (x,y,z) with upper and lower limits of wpeDF.gif (886 bytes)and wpeE0.gif (881 bytes) in x, wpeEF.gif (892 bytes) and wpeF0.gif (889 bytes) in y, and wpeF1.gif (879 bytes) and wpeF2.gif (872 bytes) in z:

wpeF7.gif (3358 bytes)





A differential volume element would be defined by:

wpeF4.gif (1144 bytes)

If we want to pick a point with a flat distribution (i.e., each volume element equally likely), then the total distribution would be:

wpeF6.gif (1597 bytes)

with

wpeF8.gif (1025 bytes)

then we must have:

wpeF9.gif (1345 bytes)

This means, of course, that each of the dimensions x, y, and z would be chosen according to constant distributions over their respective ranges, giving us:

wpeFA.gif (1861 bytes)

where wpeFB.gif (896 bytes) is the wpeFC.gif (901 bytes) pseudo-random number.
 
 

Cylindrical coordinate system

For a cylinder of radius wpeFD.gif (874 bytes) and z limits wpeF1.gif (879 bytes) and wpeF2.gif (872 bytes):

wpe107.gif (2297 bytes)





The volume element is:

wpeFF.gif (1166 bytes)

where wpe100.gif (870 bytes) is the azimuthal angle, which goes from 0 to wpe101.gif (902 bytes).  The distributions for each of the dimensions, then are:

wpe104.gif (1398 bytes)





Use of these PDFs over the ranges of the dimensions would result in the following equations for choosing the position variables.

wpe105.gif (1607 bytes)

In the Cartesian coordinate system (that most Monte Carlo codes run in) these would be translated into:

wpe106.gif (1346 bytes)

Spherical coordinate system

For a sphere of radius wpeFD.gif (874 bytes) with dimensions r (distance from origin), wpe100.gif (870 bytes) (polar angle), and wpe108.gif (883 bytes) (azimuthal angle):

wpe109.gif (4139 bytes)





The volume element is:

wpe10B.gif (1763 bytes)

The distributions for each of the dimensions, then are:

wpe10C.gif (1709 bytes)





Use of these PDFs over the ranges of the dimensions would result in the following equations for choosing the position variables.

wpe10D.gif (1642 bytes)

In the Cartesian coordinate system (that most Monte Carlo codes run in) these would be translated into:

wpe10E.gif (1622 bytes)



Choosing an initial point from multiple sources

For a situation in which source particles are chosen from multiple source (possibly of various shapes, sizes, and source rate density), the user should apply a probability mixing strategy whereby:
    A source is chosen from the multiple sources using the total source rates in each source (in units of particles/sec) to choose among the sources.

    The point within the chosen source is picked using the appropriate shape's equations from above.

Non-uniform spatial distributions

One additional consideration is what should be done if the spatial source distribution is not uniform.  In this case, the PDFs for the individual dimensions would be multiplied by the non-uniform distribution. 

Example:  How would you choose a point inside a spherical source if the source is distributed in volume according to wpe118.gif (1199 bytes)?

Answer: In this case, the probability for differential volume element would be:

wpe119.gif (1917 bytes)





The distributions for each of the dimensions, then would become:

wpe11A.gif (1438 bytes)





Use of these PDFs over the ranges of the dimensions would result in the following equations for choosing the position variables.

wpe11B.gif (1410 bytes)


Particle initial direction

The choice of direction is based on probabilities on wpe10F.gif (923 bytes), which is a differential element of solid angle on the surface of a unit sphere:

wpe110.gif (3294 bytes)

with the value:

wpe111.gif (1211 bytes)

where we note that the specification of the polar axis to be the z axis in this figure is completely arbitrary.  The polar axis can be oriented in any direction that the analyst desires.  If we define wpe113.gif (1013 bytes), this becomes:

wpe114.gif (1127 bytes)

where the minus sign is present because wpe115.gif (872 bytes) decreases as wpe116.gif (870 bytes) increases.
 
 

This gives us a dimensional PDFs of:

wpe119.gif (1247 bytes)

Since wpe115.gif (872 bytes)varies from -1 to 1 and wpe117.gif (883 bytes) from 0 to wpe118.gif (902 bytes), the resulting equations for the variables are:

wpe11A.gif (1244 bytes)





Generally, Monte Carlo methods require directions in the form of direction cosines, which would be:

wpe11B.gif (1711 bytes)


Particle initial energy

Generally, choice of the initial particle energy is based on either a continuous, discrete, or multigroup source spectrum. 

If the source distribution is continuous, the particular distribution (in units of wpe11C.gif (927 bytes) or wpe11D.gif (995 bytes)) must be dealt with in the usual ways -- either by a direct approach (if the distribution can be integrated and inverted) or with a rejection method.

If the source distribution is discrete - which is common for photon production from decay of radioactive sources - the data is usually in the form of particular particle energies coupled with the yield (i.e., the percentage of decay events that produce a gamma of the particular energy).  In this situation, the yield values for the various possible emitted energies serve as the probabilities (wpe11E.gif (901 bytes)) used for choosing from a discrete distribution.

Similarly, if the source distribution is in multigroup form, the individual source contribution in a given group is the integrated source over the group (and therefore is not a distribution in "per unit energy" units).   Therefore, the individual group source values are exactly analogous to discrete yields, so would be used as the wpe11E.gif (901 bytes) probabilities in a discrete distribution.
 
 

Expected distance to next collision

For an infinite material with a known total cross section, wpe124.gif (891 bytes), the probability distribution for collision inside a differential path element dx a distance x from the previous collision is:

wpe126.gif (3726 bytes)

Therefore the PDF is:

wpe127.gif (1124 bytes)

which is already normalized over the range wpe128.gif (991 bytes).

The associated CDF is:

wpe129.gif (1513 bytes)

which inverts to give us the formula:

wpe12A.gif (1209 bytes)

In terms of the optical path length, wpe12B.gif (851 bytes), defined by:

wpe12C.gif (972 bytes)

(which corresponds to the number of mean free paths traveled) we can use:

wpe12D.gif (1094 bytes)

Actually since  is "as random" as wpe12F.gif (871 bytes), it is traditional to simplify this to:

wpe130.gif (1060 bytes)

Type of collision

Once a collision is known to have occurred, the choice of reaction type is based on the reaction macroscopic cross sections at the particle energy.  Generally, the reactions of interests are scattering, fission, and capture, with relative probabilities based on ratios with the total cross section:

wpe120.gif (1486 bytes),

which gives us probabilities of:

wpe11F.gif (2012 bytes)

We make the choice between reaction types by using these probabilities as a discrete distribution.
 
 

Outcome of scattering event

The outcome of a scattering event by a particle with initial energy E is given (formally) by the double differential distribution:

wpe103.gif (1305 bytes)

where M = material and the primed variables are associated with the particle after the collision.

Mathematically, this is handled as described in the text for multi-dimensional distributions -- we reduce it to a one dimensional choice by integrating over the other dimension.  Typically, for continuous energy representations (like MCNP),it is the outgoing energy that is eliminated to give us a distribution over the cosine of the deflection angle, wpe112.gif (1080 bytes):

wpe120.gif (1618 bytes)

Once this distribution is sampled to give us a particular deflection cosine (which can be translated into a polar angle of deflection), we would choose an azimuthal angle uniformly from 0 to wpe121.gif (902 bytes).   From this, we can determine the outgoing direction wpe122.gif (901 bytes).

Knowing this value, then the outgoing energy is then chosen from:

wpe123.gif (1345 bytes)

It should be noted that for elastic scattering events (and inelastic scattering from known nuclear levels) there is a unique relationship among scattering deflection angle, initial energy, and final energy.  This situation would, of course, reduce this last distribution to a single value (times a Dirac delta).

For multigroup energy representations in which the angular dependence of the group-to-group scattering is represented by a Legendre expansion in deflection angle, the energy group of the outgoing distribution is generally determined first -- using the 0th order Legendre cross sections -- and then the direction is chosen from the angular expansion of the chosen groups, using the particular group-to-group Legendre coefficients.



Return to Course Outline                                                                                                                   © 2006 by Ronald E. Pevey.  All rights reserved.