make core of Math.hypot implementation