The geometry is the algorithm.
At the current approximation, evaluate the function and derivative. The tangent line meets the x-axis somewhere else; that intercept becomes the next approximation. Repeat until the movement is small enough.
Root finding · CMNA Laboratory
Supply both the function and its derivative in R. Newton's method turns local slope into the next guess.
At the current approximation, evaluate the function and derivative. The tangent line meets the x-axis somewhere else; that intercept becomes the next approximation. Repeat until the movement is small enough.
Bring your own function
Then play the tangent construction one iteration at a time.
Preparing R…f and fp| n | x | f(x) | f'(x) | next x |
|---|