Fixed some rounding errors