Dear FLUKA Experts,
Could you please assist me with the following issue that I am encountering with my SOURCE routine? I am attempting to use source_newgen.f to load a spectrum that I have created using the SPENVIS tool to simulate the GCR radiation that is present within Low Earth Orbit. I have attached the proton spectrum I am using in the file 1_fluence.txt. Here is a figure showing the characteristics from SPENVIS:
spenvis-plot.pdf (23.5 KB)
When I compile my source routine, loading 1_fluence.txt using sample_spectrum_momentum_energy() and run the attached simple simulation of protons being born at the origin and passing through a sphere where I calculate their fluence using USRBDX, I obtain the following:
spenvis_test-0: USR-1D spenvis test 41.pdf (36.9 KB)
One notable difference between the two plots is that the SPENVIS spectrum peaks near 400 MeV, but the spectrum that I am calculating in the USRBDX peaks near 2 GeV. I have confirmed that the spectrum file was read correctly, walked through the energy binning, and duplicated the calculations performed in sample_spectrum_file() at lines 812-845 of source_library.inc, but I am unable to understand why this spectrum would be shifted in this manner when I run the FLUKA simulation. Thank you in advance your expertise.
John
spenvis_test.inp (1.2 KB)
spenvis_test.flair (1.1 KB)
source_spenvis.f (21.8 KB)
1_fluence.txt (1.8 KB)
spenvis_test_41_tab.lis (175.2 KB)
spenvis_test001.out (74.4 KB)