Continuing the discussion from USRBIN - plot fluence of neutrons within specific range of energy:
Dear Fluka experts,
I would like to have a clarification about this post. I essentially need to do the same thing as Dalini, I saw this post and I asked myself how this can work with the multigroup algorithm used by Fluka dealing with neutrons.
I did a try, compiling the fluscw.f routine, and it worked, but I want to know if there are some precautions that I have to take into account.
Moreover, if I have both USRBIN and USRTRACK detectors, the JSCRNG number starts from 1 for each kind of detectors?
Thank you in advance,
the multigroup approach implies that below 20 MeV the accuracy of the neutron energy is determined by the group width (in fact, neutrons are assigned a fixed value of kinetic energy depending on which energy group they belong to). In this case, the only practical implication is that for neutrons below 20 MeV there is no point in ‘fine-tuning’ the values of the E threshold in the routine beyond this accuracy. Still, keeping this in mind, you can set any value to the threshold and the code will run.
(corrected): JSCRNG counts both USRBIN and USRTRACK cards (plus other scoring cards) separately. For example, if in your input file you have a USRBIN, then a USRTRACK and then another USRBIN, JSCRNG will be 1 for the first USRBIN, 1 (again) for the USRTRACK and 2 for the second USRBIN. In the routine you can identify specific types of scoring cards with ISCRNG, so the combined use of ISCRNG and JSCRNG allows to select each of them.
thanks for the clear explanation to both of my questions.
for the JSCRNG counting it is actually the other way around (see the edited reply above).
Sorry for the confusion!
Ok, I was actually replying that I tried with 2 USRBIN card and 1 USRTRACK and select in both cases JSCRNG =1 in the routine (after selecting the specific kind of detector) for the first USRBIN and the first USRTRACK and it worked.
Finally, I guess that it’s not a good idea to choose as cutting energy a value which is a lower or upper limit of a neutron group.
in fact, arguably the group limits are the best choice of threshold (let me call this E_cut). The neutrons in each group are assigned a fixed value of energy, so when you select E > E_cut they are either all included or all rejected.
- if E_cut = E_lim (limit between two groups) you are sure that you will count the exact same neutrons that you would select if the group structure didn’t exist (i.e. if the neutron energies were sampled smoothly).
- if E_cut != E_lim, the neutrons in the group where E_cut falls may or may not be counted, which introduces a bias with respect to the ideal ‘smooth’ case. To remove the bias you would need to sample (logarithmically) a random energy within the limits of the group to which E_cut belongs, and score only the neutrons for which the random energy is larger than E_cut
Now, if your energy range includes many groups, the bias would likely be small. Instead, if you select only a limited number of neutron groups (e.g. a small energy interval E_low < E < E_high) choosing E_cut in correspondence with the group limits becomes more important (alternatively you could implement the random E sampling).
Ok I understand, nice to know thank you.