Re: FLUKA: Production of Hydrogen
Laurent,
thanks to you we have spotted an inconsistency which has arisen in the
code, and we are going to fix it (or at least to document it in the
manual).
Some years ago, in FLUKA particles were stopped at the end of the step
which brought them below cutoff energy and their energy was deposited at
that point (this is what was meant by "stopping particles"). Then there
has been an improvement: particles below cutoff make one further step
and are "ranged out" to zero energy. This step is done roughly, without
multiple scattering and all at once, whatever the value of the cutoff
energy (provided it be less than 100 MeV), and the residual energy is
uniformly distributed along such step. (If the cutoff is > 100 MeV, it
is assumed that the user is not interested in accurate energy deposition,
and the particle is stopped at cutoff and its energy dumped at one
point as before).
So, now there are no "stopping particles" anymore, except in the
case >100 MeV, but it has been forgotten to account for it in ENDRAW
scoring.
As I said, this will be fixed in a way or another, but for the time
being the way to get "ranged out" particles is the following.
Check in the main MGDRAW entry (i.e. after a "CALL MGDRAW"), when the
energy deposited in a step (DTRACK) is equal to kinetic energy of
the particle: this of course only happens when the particle is stopped.
Sorry for having given you wrong instructions before.
Alberto
PS Obviously your input is working fine on your machine, but I take this
opportunity to insist again on a point that most users tend to forget.
Unless you are using FREE input form, please write ALWAYS all the WHATs
with a decimal point, and if they are in exponential notation (e.g. 1.e4),
adjust them to the right of the field. In standard Fortran, in formatted
input BLANKS ARE TREATED AS ZEROS. Apparently, some platforms do not stick
to the standard, so your input works correctly all the same, but for
instance on IBM or VAX computers it would give you some surprises.
In your example:
*
BEAMPOS 0 0 -1
* |_________|_________|_________|_________|_________|_________|
^
|
this should be read as -10
* |_________|_________|_________|_________|_________|_________|
DUMPTHEM 100 49 0 1
should be read 1000 490 0 10
* |_________|_________|_________|_________|_________|_________|
START 1e4 9999999. 80. 0.0 9999999.
read as 1e4000000 ==> overflow exception!!!
On Wed, 12 Sep 2001, Laurent Aphecetche wrote:
> Alberto Fasso' wrote:
> >
> > Hi Laurent,
> >
> > please find attached:
> > - the include file for the TRACKR COMMON, with comments
> > - Chap. 22 of the manual, with instructions on how to write a
> > user routine.
> > - the include file for the FINUC COMMON, with comments
> > - a description of option DUMPTHEM, from the manual, describing how
> > to activate calls to various entries of the MGDRAW routine.
> >
> > Look at the instructions for routine MGDRAW (and its entries ENDRAW,
> > USDRAW)
> >
> > Stopping hadrons and muons are accessible trough calls to ENTRY ENDRAW
> > with ICODE=12. Protons are identified by JTRACK=1.
> >
> > Secondary particles from a low-energy neutron interactions are
> > accessible in COMMON FINUC after a call to ENTRY USDRAW with ICODE=300.
> >
> > Best regards,
> >
> > Alberto
>
> Hi Alberto,
>
> Thanks for your prompt and detailed answer.
> However, there's obviously something I did not understand properly.
> Please find attached a simple test.inp & endraw is like that :
>
> ENTRY ENDRAW ( ICODE, MREG, RULL, XSCO, YSCO, ZSCO )
>
> IF ( .NOT. LFCOPE ) THEN
> LFCOPE = .TRUE.
> IF ( KOMPUT .EQ. 2 ) THEN
> FILNAM = '/'//CFDRAW(1:8)//' DUMP A'
> ELSE
> FILNAM = CFDRAW
> END IF
> OPEN ( UNIT = IODRAW, FILE = FILNAM, STATUS = 'NEW', FORM =
> & 'FORMATTED')
> END IF
>
> IF (JTRACK.EQ.1) THEN
> EKINETIC = ETRACK - SQRT(ETRACK*ETRACK-PTRACK*PTRACK)
> EKINETIC = 1000*EKINETIC
> WRITE (IODRAW,10) ICODE,MREG,SNGL(ETRACK),SNGL(EKINETIC),
> & SNGL(WTRACK)
> ENDIF
> 10 FORMAT(2I4,(1X,G14.7),(1X,G14.7,' MeV'),(1X,G14.7))
>
>
> Running it I only get output with ICODE=10 (or 14), e.g :
> 10 1 0.9729540 34.68166 MeV 1.000000
> 10 1 0.9903744 52.10210 MeV 1.000000
> 10 1 0.9775165 39.24415 MeV 1.000000
> 10 1 1.023845 85.57234 MeV 1.000000
> 10 1 1.009392 71.11929 MeV 1.000000
> 10 1 1.035965 97.69282 MeV 1.000000
> 10 1 0.9560066 17.73435 MeV 1.000000
> etc...
>
> i.e. I never get 12=stopping particles. What am I missing here ?
>
> Thanks,
>
>
>
>
--
Alberto Fassò
CERN-EP/AIP, CH-1211 Geneve 23 (Switzerland)
Phone: (41 22) 767 2398 Fax: (41 22) 767 9480 Alberto.Fasso@cern.ch
Partial thread listing:
- Re: FLUKA: Production of Hydrogen, (continued)
foucher
FLUKA: Help me...plz...,
=?ks_c_5601-1987?B?wK+828Dn?=
FLUKA: Help me...
=?ks_c_5601-1987?B?wK+828Dn?=