njoy / NJOY2016

Nuclear data processing with legacy NJOY
https://www.njoy21.io/NJOY2016
Other
95 stars 82 forks source link

Fix/acer plots #314

Closed whaeck closed 8 months ago

whaeck commented 8 months ago

For certain ENDF/B-VIII.1 thermal scattering files, the energy points generated by ACER for plotting (iopt=7) the coherent elastic scattering cross section seemed to have energy points that were out of order. This has to do with the values being generated for the plots in the tplots subroutine in aceth.f90. The ACE file contains the energies e of the Bragg edges and the associated e xs values and not the actual cross section. When transforming this into an actual cross section plot, the tplots subroutine takes two sequential bragg edges at energies e1 and e2 (and cross sections xs1 and xs2) and inserts a value in between equal to e = e2-e2/1000 with a cross section equal to e1 xs1 / e. As you can expect, this can lead to energies that are out of order if e1 and e2 are close enough to one another.

This PR changes this intermediate energy point to be equal to e2 itself, and as a result the associated cross section changes to e1 * xs1 / e2.

A few tests needed their results updated as well (tests 67 and 70).