ustajan / grasshopper

GNU General Public License v3.0
6 stars 4 forks source link

input_spectrum.txt interpolation bias #8

Closed plalor closed 4 years ago

plalor commented 4 years ago

I was examining how grasshopper reads input_spectrum.txt in order to design an appropriate input spectrum file for gammas with a discrete energy spectrum. However, I noted that there is a bias towards one bin edge. In particular, the value of the right edge of the bin is used to determine the density when sampling across the entire bin. See attached, where I do a run with neutrons according to a Watt Spectrum. I plot input_spectrum.txt compared the the numerical results of a simple geometry.

1D Interpolation Bias

Simulation Geometry