I have to use Newton's method on some root $\sqrt{7}$ to four decimal places.
I know that the formula is $$x_{n+1}=x_n-\frac{f(x_n)}{f'(x_n)}$$ How can I do anything when the derivative of $\sqrt{7}$ is $0$ and it is in the denominator? Should I say there is no root?
find the root(s) of $$x^2-7=0$$ and choose $\color{red} {x_0>0}$; $$f(x)=x^2-7\to f'(x)=2x\\x_{n+1}=x_n-\frac{f(x_n)}{f'(x_n)}\\x_{n+1}=x_n-\frac{x_n^2-7}{2x_n}$$ $$x_{n+1}=\frac12(2x_n-\frac{x_n^2-7}{x_n})\\ x_{n+1}=\frac12(\frac{x_n^2+7}{x_n})\\ x_{n+1}=\frac12(x_n+\frac{7}{x_n})$$ when your iteration start over a positive number $x_0>0 $ then $x_n \to +\sqrt7$ for example take $x_0=2$ so $$x_1=\frac12(2+\frac{7}{2})=2.75\\x_2=\frac{1}{2}(2.75+\frac{7}{2.75})=2.64772\\x_3=\dfrac12(2.64772+\frac{7}{2.64772})=2.7367\\ \vdots \\x_n \to 2.645751 or \sqrt 7$$