Limit of $n(n\pi + \frac{\pi}{2} - x_n)$, where $x_n$ is the solution of $x = \tan(x)$ in the interval $(n \pi, n\pi + \frac{\pi}{2})$ Let $x_n$ denote the solution to $x = \tan(x)$ in the interval $(n \pi,n \pi +\frac{\pi}{2}).$ Find
$$ \lim_{n \to \infty}n \left(n\pi + \frac{\pi}{2} - x_n\right)$$

$x_n\in(n\pi,n\pi+\frac{\pi}{2})\implies n\pi+\frac{\pi}{2}-x_n\in(0,\frac{\pi}{2})$ and $\frac{1}{n\pi+\frac{\pi}{2}}<\frac{1}{x_n}<\frac{1}{n\pi}$.
\begin{align*}
\tan\left(n\pi+\frac{\pi}{2}-x_n\right)
&=\tan\left(\frac{\pi}{2} - x_n\right)\\
&=\frac{1}{\tan x_n}\\
&=\frac{1}{x_n}.
\end{align*}
So
$$n\pi+\frac{\pi}{2}-x_n=\arctan\frac{1}{x_n}\sim\frac{1}{x_n}\quad (n\to\infty).$$
$$\lim_{n\to\infty}n\left(n\pi+\frac{\pi}{2}-x_n\right)
=\lim_{n\to\infty}n\arctan\frac{1}{x_n}
=\lim_{n\to\infty}\frac{n}{x_n}=\frac{1}{\pi}.$$
