Spectra sampling error

Dear FLUKA expert,
I followed the instruction in this post Sampling from energy spectra, and successfully installed and have the flukadpm-spec and flukahp-spec under CERN-FLUKA-spectra-sampling/src.
However, when I try to run a flair project, as I select flukadpm-spec in the Exe:, and click Start in the Run tab, the Progress Status become Finished with ERRORS. The Output window shows nothing, so I opened the .out file it generated.
At the end of the .out file, it prints:
Error: /home/z/Documents/misc/CERN-FLUKA-spectra-sampling/src/flukadpm-spec executable returned RC=136

Could you please help me with this?
Thank you in advance

Z.

Dear Ephemera,

the error code 136 suggests an floating point exception.

Could you share you input files, to be able to take a look?

Cheers,
David

Dear David,
Sure, attached is my test input file.
waterTankProton.inp (1.7 KB)

Thank you!!

Dear David,
I also try to run the example input provided in the Sampling from energy spectra, the result came out the same, returning RC=136
Here is a screenshot where I override the executable file


and the error message in the .out file.

Thank you!
Z.

Hi!

Based on the size of the executables, I’m guessing something went wrong during the compilation.
Could you run the make command again, and post the whole output?

Cheers,
David

Dear David,
Attached is the output of the make command.
Thank you!
Z.

makeOutput.txt (3.4 KB)

Hi!

Unfortunately, the output of the make command looks normal.

When you get the error, is there a fluka_xxxx folder as well? Is there a .out, .log or .err file in that folder?

Please also confirm, that a simple FLUKA simulation works.

Cheers,
David

Dear David,
Yes, a fluka_xxxxx folder was created, and a .log file was inside that folder. Attached is the .log file (waterTankProton001.log (392 Bytes) )
Once I remove the “Override Executable file” in the Run tab, and run, Flair will process correctly using the energy specified in BEAM card, but not using the spectrum.

Thank you!
Z.

Hello!

Thank, it confirms the overflow error, but unfortunately it’s not giving any hints about the problem.

The only thing I see is that the Makefile, has been edited and it’s size different from the original.
Could you delete the whole spectra_sampling folder, extract it again from the tar file, and try to compile? The executable sizes should be around 57 and 45 MBs.

Cheers,
David

Dear David,
I re-download the .tgz file, and extract it, directly go to /src and compile.
Here is the output after the compilation. makeOutput.txt (3.3 KB)
And here is the screenshot of the src folder.

I tried to run the spectra_sampling.inp in the example-input folder with selecting “flukadpm-spec” as override executable file in the Run tab. It still output the same error…and I tried the “flukahp-spec”, and same thing happened, it won’t run…

BTW, I’m using Ubuntu 20.04, and have gfortran 9.2.0 installed.

Thanks,
Z.

Hi!

Are you using a custom gfortran compiler, instead of the system one, which is 9.3 for ubuntu 20.04?

Cheers,
David

Dear David,
Yes, I installed from the gnu.org website. Should I just install the system one? cause I saw the recommended gfortran for building FLUKA are 7.4, 8.3, 9.2. So I installed 9.2.

Thanks
Z.

Hi Z,

yes, please try to use the system compiler.

My assumption is, that maybe some of the compiler option used to set up gcc/gfortran is not fully compatible with this code or FLUKAs’ precompiled libraries.

For FLUKA, only the major version of the gfortran compiler matters. This means the FLUKA package precompiled with gfortran 9.2 will work with the system compilers version 9.x (also with 8.x and 10.x, too)

Cheers,
David

Dear David,
I installed the system default gfortran. It works like charm!
Thank you so much for your help!!

Best,
Z.