If Newton's method to applied to find the critical point of the $f(x) = \sin x - \ln x$, i.e., a point where $f'(x) = 0$, which iteration formulas should be obtained?
So basically I used the newton's method to approximate the root for $f'(x) = 0$, here is what I got: $$x_{n+1}=x_n-\frac{\cos x - \frac{1}{x_n}}{-\sin x + \frac{1}{x_n^2}}$$ which simplifies to: $$x_{n+1}=x_n-\frac{x_n^2\cos x_n - x_n}{-x_n^2\sin x + 1}$$
However the answer given is
$$x_{n+1}=x_n-\frac{x_n^2\cos x_n - x_n}{x_n^2\sin x + 1}$$
I am wondering whose solution is wrong? Thanks in advance.