cerati/mictest — pull request #1 by kmcdermo (2014-07-25 15:54:36+00:00)
Title: Fix phi wrapping issue

Fixed phi wrapping issue. Used atan2(sin(phi),cos(phi)) to return values back to -pi to pi. First had a while loop, but that is no good for vectorization. Tried modulo arithmetic, but was returning the wrong bin placements for values less than -Pi.

I should mention there is now a branch created by looping over the indices either through phi wrapping or not. This also introduces another branch within loop on hits on whether to use a hit from the phi wrapped case. I needed to add a new Hit constructor for this to work.

I also included a plotting tool (root macro). If you have two different makes of buildtest, you can save the root files as _old and _new (or whatever you prefer), and it will produce comparison plots for validation purposes.