PrKalmanFilter cuts away tracks with near-zero curvature
A cut was introduced in PrKalmanFilter that essentially removes tracks with momentum > 7 TeV:
This is not a good idea: These are just good tracks with a curvature that cannot be distinguished from zero. Such tracks are useful for alignment and also for some physics (if treated properly). It is also in the way of assigning velo tracks zero curvature. The problem was noticed when we increased the scattering momentum of velo tracks to a large value.
I understand this solution was chosen to prevent problems in persistence. If we cannot solve it there, it is still much better to change the curvature than to remove the tracks, e.g. with
if ( std::abs( state.qOverP() ) < 1. / TrackParameters::maxPhysicalMomentum )
state.setQOverP( state.charge() / TrackParameters::maxPhysicalMomentum )
The better solution is to fix the packing: We should simply pack q/p rather than momentum for tracks. (This can just be packed as a float which is more than sufficient for all measured track curvatures in LHCb.) For the associated particle we can eventually introduce a momentum cutoff as above.