solution by successive approximation