Skip to main content

numerics - Implementing the Newton -Raphson method for finding the zeros of a function


f[x_] = x - 0.8 - 0.2 (sinx)

x0 = Pi;
n = 20;

NewtonsMethodList[f, {x_, Pi}, 20] :=
NestList[# - Function[x, f][#]/Derivative[1][Function[x, f]][#] &, Pi, 20]


I want to apply the newton raphson method to $x - 0.8 -0.2 \sin x$ and have little experience with Mathematica, but am told this is an efficient and useful tool to find a root. Based on the information in MathWorld, I tried this out, and a number of combinations, but do not understand how to get the series of values I would expect.




Comments