Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

lambda, edex problems

68 views
Skip to first unread message

Eric Chad Harley

unread,
Dec 3, 2001, 1:34:46 PM12/3/01
to Egs4-L Discussion Group
Hello, EGS users.

I am using EGSnrc and have been running some simulations successfully for a
while. After making some minor modifications to my user code (basically I
am introducing an additional material -- made new pegs4 input file, ran
pegs4, concatenated result with the old data file, changed relevant lines
in user code to add material) I have been having this error:

lambda > lambda_max: 0.505799 NaN
eke dedx: 7.99859 0.
medium blcc: 2 51186.0

Evidently dedx is being set to 0 somehow, which causes a problem when
trying to calculate lambda_max, since dedx is in the denominator.

Despite the fact that I have changed very little in the code, I can't seem
to figure out what is causing this error. (It probably doesn't help that I
don't really know what the above variables are.)

Does anyone have an idea of what might be causing this?

Thanks,
Eric Harley
grad student, UNC Physics

Iwan Kawrakow

unread,
Dec 3, 2001, 3:52:45 PM12/3/01
to eha...@physics.unc.edu, egs...@mailbox.slac.stanford.edu

Eric,

the most common mistakes that lead to problems like
yours are:

- your arrays are not big enough to hold the number of media
you want to use => check the value of $MXMED
- the energy range of the PEGS data sets does not cover
the energy range of the particles in your simulations
=> check UE(medium) and UP(medium) (max. electron and photon
energy of the PEGS data sets)
- attempts to run EGSnrc at energies lower than the minimum
EGSnrc energy (1 keV).
- attempts to use cut-off energies (AE) less than two times
the mean ionization energy of a medium (restricted stopping
power doesn't make sense).

In your particular case there is an additional possibility:
since lambda_max is NaN, and there are no sqrt,log, etc.,
involved in its calculation, it must be the result of
0/0 => dedx and blccl are both zero.
Since blccl is blcc(medium)*rhof and blcc(medium) has
a reasonable value, rhof must be zero (dedx is also multiplied
by rhof). rhof can become zero if a) there are zero density
regions in your geometry that are not vacuum or
b) the particle has left the geometry
without being discarded and so the region index is out of bounds.

In case a): you must define regions with zero mass density
as vacuum (medium number 0), EGSnrc can not handle zero density
materials that are not vacuum.

In case b): check and repair you geometry routines.

Hope this helps,
Iwan

--

---------------------

I. Kawrakow, PhD
Ionizing Radiation Standards
Institute for National Measurement Standards
National Research Council of Canada
Ottawa, ON, K1A 0R6
Canada

Tel. (613) 993 2197
fax (613) 952 9865
e-mail iw...@irs.phy.nrc.ca

dylanmann...@gmail.com

unread,
Mar 16, 2017, 6:13:00 PM3/16/17
to
Good day,

Were you able to find a solution to your problem? I am experiencing similar complications.

Thanks.
0 new messages