Re: estimators

From: Alberto Fasso' <fasso_at_slac.stanford.edu>
Date: Mon, 9 Feb 2009 09:56:29 -0800 (PST)

Dear Emilia,

for the energy and the angular distribution, use the USRBDX estimator,
scoring one-way current of particle BEAMPART (or number 210).
For the spatial distribution, it is more complicated. You can use USRBIN,
still with particle BEAMPART, but that gives you two-way fluence, not current.
The difference in your case is probably minimal, but if you want to be 100%
sure, you can write a user routine mgdraw.f, ENTRY BXDRAW, which is called at
each boundary crossing.
The ENTRY has the following arguments:
       ENTRY BXDRAW ( ICODE, MREG, NEWREG, XSCO, YSCO, ZSCO )
where MREG is the upstream region, NEWREG the downstream one, and
XSCO, YSCO, ZSCO are the coordinates of the crossing point.
I assume here that your input is name-based.
You must write something of this kind:
       SUBROUTINE MGDRAW ( ICODE, MREG )
       .................................
       CHARACTER*8, MRGNAM, NRGNAM
       .................................
       ENTRY BXDRAW ( ICODE, MREG, NEWREG, XSCO, YSCO, ZSCO )
       IF ( .NOT. LFCOPE ) THEN
          LFCOPE = .TRUE.
          OPEN ( UNIT = 88, FILE = "collfile", STATUS = 'unknown')
       END IF
       IF(LTRACK .EQ. 1) THEN ! means first generation, beam particle
          CALL GEOR2N ( MREG, MRGNAM, IERR1 )
          CALL GEOR2N ( NEWREG, NRGNAM, IERR2 )
          IF(MRGNAM .EQ. "xxxxx " .AND. NRGNAM .EQ. "yyyyy ") THEN
             WRITE (88, *) XSCO, YSCO, ZSCO
          END IF
       END IF
Here, I have supposed that xxxxx and yyyyy are the names of the two regions.
If your input is number-based, suppress the two calls to GEOR2N, and
do the check directly on the region numbers:
          IF(MREG .EQ. 5 .and NEWREG .EQ. 6) THEN ....
Here I have made you just write the crossing point coordinates in a file,
but of course you can score them in histograms or do other analyses as you
like. Unfortunately, as always with user routines, you have to do all
the work. But the information is there.

Alberto

On Mon, 9 Feb 2009, Emilia Basile wrote:

> (smtp1.mi.infn.it [192.84.138.69]); Mon, 09 Feb 2009 12:38:11 +0100 (CET)
> Sender: owner-fluka-discuss_at_mi.infn.it
>
>
> Dear Fluka users,
> I'm working with a 200 MeV proton beam. I'd like to know the energy, the
> FWHM of the spatial distribution and the angular distribution of the
> primary beam at several depths.
> Which estimator can I use?
>
> Thanks in advance.
>
> With my best regards,
> Emilia Basile

-- 
Alberto Fasso`
SLAC-RP, MS 48, 2575 Sand Hill Road, Menlo Park CA 94025
Phone: (1 650) 926 4762   Fax: (1 650) 926 3569
fasso_at_slac.stanford.edu
Received on Tue Feb 10 2009 - 10:14:30 CET

This archive was generated by hypermail 2.2.0 : Tue Feb 10 2009 - 10:14:31 CET