After talks with @trnielsen today, I am considering if we should let the detector macros calculate another number indicating "statistical quality", i.e. a maximal allowed "scaling time".
Algorithm would:
- Only consider non-zero bins
- Calculate t_max = I / E^2 for each pixel
- Write the smallest t_max in the header as a scalar number
Would require:
- New internal (temporary) array in the detector_out functions
- Doing the calculation pr. pixel and storing the minimal during this loop
- Clear out the temporary array
Documentation to be found in e.g.
- Virtual experiments: the ultimate aim of neutron ray-tracing simulations
K. Lefmann, P. K. Willendrup, L. Udby, B. Lebech, K. Mortensen, J. O. Birk, K. KlenØ, E. Knudsen, P. Christiansen, J. Saroun, J. Kulda, U. Filges, M. Konnecke, P. Tregenna-Piggott, J. Peters, K. Lieutenant, G. Zsigmond, P. Bentley, and E. Farhi
Journal Of Neutron Research Vol. 16 , Iss. 3-4,2008 (Page 103 ff has simple derivation of above formula)
- Attached writeup from Anette Vickery which further defines methodology to add background.
Antette_Errorbars.pdf