# Convergence of an alternating series (from exam Q)

State whether $$\sum_{n=1}^{\infty} a_n$$ converges or diverges and prove your result:

iv) $$a_{2^n + r} = (-1)^n(2^n + r)^{-1}\text{ for }0 \leq r \leq 2^n -1\text{ and }n \geq 0$$

I tried the alternating series test by defining $$b_n = \sum_{r=0}^{2^n -1}(2^n + r)^{-1}$$ but the issue is that $$b_n$$ tends to $$\log(2)$$ not zero and so the alternating test doesn't hold. I've also tried the ratio test but I don't think this will work either due to the $$(-1)^n$$.

The question says that you can use any test for convergence so long as it is correctly stated but given that we've only covered the ratio, alternating, comparison and integral test in lectures it seems like it should be one of these but I'm totally unsure of how to proceed. Thanks in advance.

• There is a problem with your expression for $b_n$: it shouldn't be an infinite sum. Apr 4 '14 at 23:06
• I have thought about it, and I don't think you can use those tests. But the fact that $b_n$ do not go to 0 suggests to me that it should be divergent. (Unfortunately, this is not a valid procedure since there is no reason to believe $\sum a_n=\sum (-1)^n b_n$.) For this particular problem, Andre Nicolas's solution is right on the spot: using the actual definition of an infinite sum as a limit of partial sum. Apr 5 '14 at 1:24

Hint: Show that the partial sums do not have a limit. To do this, note that if the partial sum of the terms up to the $(2^n-1)$-th term is $a$, then the partial sum of the terms up to the $(2^{n+1}-1)$-th term is either $\lt a-\frac{1}{2}$ or $\gt a+\frac{1}{2}$.
Let $\left\{a_n\right\} = \dfrac{1}{2^n+r}$ where $n$ is a non-negative integer and $0 \leq r\leq 2^n−1$.
By inspection $\left\{a_n\right\}$ is positive, decreasing sequence. Further, $\lim_{n\rightarrow\infty}{a_n}$ is zero as: \begin{align} \lim_{n\rightarrow\infty}{a_n}= \lim_{n\rightarrow\infty}{\dfrac{1}{2^n+r}} \end{align}
$$\lim_{n\rightarrow\infty}\dfrac{1}{2^n + 2\,n-1} \leq \lim_{n\rightarrow\infty}\dfrac{1}{2^n + r} \leq \lim_{n\rightarrow\infty}\dfrac{1}{2^n}$$ $$\lim_{n\rightarrow\infty}\dfrac{1}{2^n + r} = 0$$
Resulting from the fact that all three hypotheses of the alternating-series test are true, $\sum_{n=1}^{\infty}{(-1)^n\, \dfrac{1}{2^n+r}}$ converges.