Error with DETGEB card

Hello, FLUKA community,

I hope this message finds you well. I am currently working on a gamma spectra simulation using a NaI detector in FLUKA, aiming to apply Gaussian spectra using the DETGEB card similar to what I have done successfully in MCNP. However, I’m encountering an error in Cycle 5 of my FLUKA simulation.

I have thoroughly checked my input file, including parameters such as a, b, and c for the FWHM formula, and I am confident that the values are reasonable. Despite this, I consistently encounter the error in Cycle 5.

Thank you in advance for your assistance!

Best regards,
NaI_Article1.inp (2.7 KB)

Dear @assia.arectout,

Would you please care to elaborate about the error: what it is?
Could you please upload your flair file and the .out, .log, and .err file of the last cycle?

Dear @amario

It seems that the issue is with the FWHM value, as it appears <0

I’ve carefully reviewed the parameters (a, b and c) in my simulation, and they align with those outlined in the article referenced below.
Please find attached the following files related to the simulation:

NaI_Article1005.log (139 Bytes)
NaI_Article1005.err (790 Bytes)
NaI_Article1005.out (80.7 KB)
article principal.pdf (1.2 MB)

Dear @assia.arectout,

I see that you run FLUKA4-3.1 which is almost one year old. I would ask you to download the latest version (as of today FLUKA4-3.4) and try to run again. Your problem may have already been fixed.

Dear Amario,
I’ve taken your advice and installed the latest version of FLUKA (4.3.4) as per your recommendation. However, regrettably, the issue I’ve been experiencing persists even with this updated version.
NaI_Article1005.err (790 Bytes)
NaI_Article1005.out (80.7 KB)
NaI_Article1005.log (139 Bytes)

Dear Assia,

The parameters you provide for the DETGEB card give negative FWHM values below ~35 keV and above ~6.5 MeV. Unfortunately, this will stop the FLUKA simulation and there isn’t a workaround.

We will look into how this could be handled better in a later release.

What you could do now is run the simulation without the Gaussian broadening, and apply it manually to the results.

Cheers,
David

Dear David
Thank you for your prompt response. I’m wondering if the use of the user routine “usreoui.f” file might resolve the negative FWHM values or if this error persists despite such modifications.

Best regards,

Dear Assia,

you are right, you could use the old implementation of Gaussian broadening with the usreou.f user routine as a workaround.

I slightly modified the previous version with a check only to do the broadening, when the FWHM is positive at a given energy. usreou.f (2.4 KB)

As a reminder, you need to disable the DETGEB card in your input, and add a second “dummy” DETECT for the BLKBODY region to make it work.

Cheers,
David

Thank you, this fixed my issue!