Calculations are now done modulo 2*pi.