Atmospheric flux rotation by default
In short: the problem is that atmospheric neutrino fluxes are parametrised by angles respect to the zenith, and GENIE in its wisdom decides that the zenith is the direction of the z axis.
On the other end, LArSoft definitely sets z direction as the beam direction.
My request is for
GENIEHelper to rotate the flux for us.
- first, NOvA should weigh in, in that if their z is toward the zenith, this request can be rejected immediately
- GENIE allows a rotation to be specified, and
GENIEHelperpasses one through from the configuration; the rotation that seems to do the trick is
[ +1.0, 0.0, 0.0, # new x axis in old coordinates 0.0, 0.0, 1.0, # new y axis in old coordinates -1.0, 0.0, 0.0 # new z axis in old coordinates ]
this rotation swaps y and z, resulting in z pointing west and x pointing south (because x is not changed, and GENIE x points south).
- this request is for such a matrix being used by default by
GENIEHelperwhen dealing with atmospheric fluxes, to be combined with the user-specified one.
Of course this is a breaking change that needs to be carefully pondered and well advertised.
Also of course, this does not fix the azimuth angle: in LArSoft z should point away from the beam source, usually not westward.
A new parameter (
zFromSouth) might even be added to simplify this; if I am not mistaken, the transformation matrix would become
[ +sin(zFromSouth), -cos(zFromSouth), 0.0, # new x axis in old coordinates 0.0, 0.0, 1.0, # new y axis in old coordinates -cos(zFromSouth), -sin(zFromSouth), 0.0 # new z axis in old coordinates ]with
zFromSouthbeing defined as the angle respect to south (west is π/2) the beam comes from (in the [0,+π/2] range for DUNE, MINOS and NOvA).