I am using source.f and mgdraw.f to emit a beam of thermal neutrons onto a sheet of cadmium. The resultant gammas pair produce in Tungsten mesh. The positron KE at the instant of pair production is recorded by the mgdraw.f code.
I noticed that I get error message (positron_maker005.err (86.0 KB) )whenever I increase the beam energy in the BEAM card. At lower energies (<= 1e-8 GeV) there is no problem. Can someone please explain the reason? Is it because the energy limit, as set by BEAM card, is more than the energies that I am sampling?
positron_maker.inp (9.3 KB) source1.f (8.4 KB) mgdraw_pos_yield.f (3.8 KB)
The content of spectrum.dat file that I use in source.f----
the issue is that your input, has geometry errors.
The message gives an approximate location of the problem.
Geofar: [...] in position -3.942257245E+00 -7.147018950E+00 2.115680910E+08
In your case – given the Z coordinate – it is easy to find the problem in the VOID region.
Zone 2 and 3 of the VOID overlapping with BLKBODY region.
To fix the issue, you just need to add +void for these zones, like:
VOID 5 +void -cyl1
| +void +cyl1 -pln8
| +void +cyl1 +pln1
The reason that you only get the error at higher energies can be explained easily.
FLUKA doesn’t see geometry errors, unless a particle it trying to enter an the problematic (overlapping or undefined) part of the geometry.
At low energies, most likely all particles stopped or scattered away from the error. While higher energies, it is more likely, that particles pass straight trough your geometry, reaching the error.
I hope this clarifies the issue.
thanks for the answer. that cleared things up. Just to confirm one more thing. the energy in the BEAM card should be more than the energy being sampled by the source.f routine? Is this correct?
yes, that is correct. The energy given on the BEAM card is used to initialize the cross section tables.