eic / eic-smear

fast simulation tool originally developed by the BNL EIC task force
GNU General Public License v3.0
2 stars 11 forks source link

Double32_t has insufficient precision #9

Open kkauder opened 3 years ago

kkauder commented 3 years ago

Reported by Wojtek Slominski. This type is used by most if not all MC classes and offers 7-10 significant digits, and getting to 9-10 would already require changes of the form Double32_t E; //[0,10000] where the comment is important.

An example from rapgap: (in MC notation: px, py, pz, E, M): Generator output TXT file: 1.472406611 -1.440001479 -17.51050923 17.631208672 0.000510000 ROOT tree track filled by BuildTree: 1.472406611 -1.440001479 -17.51050923 17.631208420, -0.002939240

The calculated M is wrong (negative even).

kkauder commented 3 years ago

This is in principle a simple sed s///g one-line fix, but raises questions about backward compatibility.