Limit $l=\lim_{t\to^{-}} (1-t) \sum_{r=1}^{\infty} \frac{t^r}{1+t^r}$ 
Evaluate $$l=\lim_{t\to1^{-}} (1-t) \sum_{r=1}^\infty\frac{t^r}{1+t^r}$$


My solution: 
$$l=\lim_{t\to1^{-}} \frac{(1-t)}{\ln(t)}\cdot \ln(t)\sum_{r=1}^{\infty} \frac1{1+t^{-r}}$$
$$=\lim_{t\to1^{-}}-\ln(t) \sum_{r=1}^{\infty}\frac1{1+e^{-r\ln(t)}}$$
Let $-\ln(t)=\frac1n,$ as $t\to1^{-},\ n\to+\infty$
So $$l=\lim_{n\to+\infty}\frac1n \sum_{r=1}^{\infty}\frac1{1+e^{r/n}}$$
$$=\int_{0}^{1}\frac{dx}{1+e^x}=\ln \left(\frac{2e}{1+e}\right)$$
Is there any other way to do this question?
 A: You can put $t=e^{-h} $ so that $h\to 0^+$ and then $h/(1-t)\to 1$. The expression under limit can thus be reduced to $$h\sum_{r=1}^{\infty} \frac{1}{1+e^{rh}}$$ The function $f(x) =1/(1+e^x)$ is decreasing on $[0,\infty) $ therefore $$\int_{h} ^{(n+1)h}f(x)\,dx\leq h\sum_{r=1}^{n}f(rh) \leq\int_{0}^{nh}f(x)\,dx$$ Letting $n\to\infty $ we get $$\int_{h} ^{\infty} f(x) \, dx\leq h\sum_{r=1}^{\infty} f(rh) \leq \int_{0}^{\infty} f(x) \, dx$$ Letting $h\to 0^{+}$ we get the desired limit as $\int_{0}^{\infty} f(x) \, dx=\log 2$.
The above technique has also been used in this answer. 
A: Note that we have 
$$\begin{align}
(1-t)\sum_{n=1}^\infty \frac{t^n}{1+t^n}&=(1-t)\sum_{n=1}^\infty \sum_{m=0}^\infty (-1)^mt^{n+nm}\tag1\\\\
&=(1-t)\sum_{m=0}^\infty (-1)^m \sum_{n=1}^\infty t^{(m+1)n}\tag2\\\\
&=(1-t)\sum_{m=0}^\infty (-1)^m \frac{t^{m+1}}{1-t^{m+1}}\\\\
&=\sum_{m=1}^\infty (-1)^{m-1}\frac{t^{m+1}}{\sum_{\ell=1}^mt^\ell}
\end{align}$$
Now taking the limit as $t\to 1^-$ reveals
$$\begin{align}
\lim_{t\to1^-}(1-t)\sum_{n=1}^\infty \frac{t^n}{1+t^n}&=\sum_{m=1}^\infty \frac{(-1)^{m-1}}m\tag3\\\\
&=\log(2)
\end{align}$$
as expected!


NOTE $1$:
We first justify the interchange of series in going from $(1)$ to $(2)$.  To do so, note that 
$$\begin{align}
\lim_{M\to\infty}\sum_{n=1}^\infty\sum_{m=0}^M (-1)^mt^{n+nm}&=\lim_{M\to\infty}\sum_{n=1}^\infty t^n \frac{1-t^{n(M+1)}}{1+t^n}
\end{align}$$
For any fixed $t<1$, $\displaystyle \left|t^n \frac{1-t^{n(M+1)}}{1+t^n}\right|\le \frac{t^n}{1+t^n}$.  Then, both the Dominated Convergence Test and the Weierstrass M-test,  guarantee that 
$$\begin{align}
\lim_{M\to\infty}\sum_{n=1}^\infty\sum_{m=0}^M (-1)^mt^{n+nm}&=\lim_{M\to\infty}\sum_{n=1}^\infty t^n \frac{1-t^{n(M+1)}}{1+t^n}\\\\
&=\sum_{n=1}^\infty \frac{t^n}{1+t^n}\\\\
&=\sum_{n=1}^\infty\sum_{m=0}^\infty (-1)^mt^{n+nm}\tag4
\end{align}$$
Finally, we have 
$$\begin{align}
\lim_{M\to\infty}\sum_{n=1}^\infty\sum_{m=0}^M (-1)^mt^{n+nm}&=\lim_{M\to\infty}\sum_{m=0}^M \sum_{n=1}^\infty(-1)^mt^{n+nm}\\\\
&=\sum_{m=0}^\infty \sum_{n=1}^\infty(-1)^mt^{n+nm}\tag5
\end{align}$$ 
Noting that the right-hand sides are equal shows that the interchange of series is legitimate.


NOTE $2$:
To justify the interchange of the limit and the series on the left-hand side of $(3)$, simply note that for $t\le 1$
$$\left|\frac{t^{m+1}}{\sum_{\ell=1}^mt^\ell}\right|\le\frac1m$$
Hence, $\displaystyle \frac{t^{m+1}}{\sum_{\ell=1}^mt^\ell}\to 0$ uniformly as $m\to \infty$ (It is trivial to show that it is also monotonically decreasing).  Dirichlet's Test guarantees then that 
$$\lim_{t\to1^-}\sum_{m=1}^\infty (-1)^{m-1}\frac{t^{m+1}}{\sum_{\ell=1}^mt^\ell}=\sum_{m=1}^\infty (-1)^{n-1}\lim_{t\to1^-}\left(\frac{t^{m+1}}{\sum_{\ell=1}^mt^\ell}\right)$$
And we are done!
