Eliminating Math.sqrt to increase performance.