Fix Newton's method