For the function
$$ f: = \cot(\sqrt x) + \frac{1}{\sqrt{x}}$$ with the initial approximate $$x_0 = \pi^2\left(n-\frac{1}{2}\right)^2$$ Show that after one iteration $$ x_{n+1} = \pi^2\left(n-\frac{1}{2}\right)^2\left(1+ \frac{1}{1+ \pi^2\left(n-\frac{1}{2}\right)^2}\right)^2$$
So we have $$ f' = \frac{-x\csc^2(\sqrt{x})-1}{2x^{3/2}}$$
Then
$$ x_{n+1} = \pi^2\left(n-\frac{1}{2}\right)^2 - \frac{\cot(\pi\left(n-\frac{1}{2}\right))+\frac{1}{\pi\left(n-\frac{1}{2}\right)}}{\frac{-\pi^2\left(n-\frac{1}{2}\right)^2\csc^2\left(\pi\left(n-\frac{1}{2}\right)\right)-1}{2\pi^3\left(n-\frac{1}{2}\right)^3}}$$
I think that
$$ \cot\left(\pi\left(n-\frac{1}{2}\right)\right) = 0, \forall n \in \mathbb{N}$$ and $$ \csc^2\left(\pi\left(n-\frac{1}{2}\right)\right) = 1, \forall n \in \mathbb{N}$$
So,
$$ x_{n+1} = \pi^2\left(n-\frac{1}{2}\right)^2 - \frac{\frac{1}{\pi\left(n-\frac{1}{2}\right)}}{\frac{-\pi^2\left(n-\frac{1}{2}\right)^2-1}{2\pi^3\left(n-\frac{1}{2}\right)^3}}$$
$$ = \pi^2\left(n-\frac{1}{2}\right)^2+ \frac{2\pi^2\left(n-\frac{1}{2}\right)^2}{\pi^2\left(n-\frac{1}{2}\right)^2-1}$$
$$ = \pi^2\left(n-\frac{1}{2}\right)^2\left(1 + \frac{2}{1+ \pi^2\left(n-\frac{1}{2}\right)^2}\right)$$
Which is not the correct answer! Can anyone spot a flaw?