A method for finding successively better approximations to the roots (zeroes) of a real-valued function