Replaced Newton's method with binary search.