Alternating Series Test

Generalising the even-odd method to covering subsequences, and an infinite counterexample!


Wikipedia's current proof[1] of the alternating series test (also known as the alternating sequence test) seems to be missing its last line. They immediately conclude that because the subsequences $S_{2m}$ and $S_{2m+1}$ converge to the same limit $L$, then so too the sequence $S_n$ overall must also converge to $L$. The result is true, however it is not immediately obvious, and in analysis we have to be careful with surreptitious and specious sequences.

A proper proof

Setup

Let $(a_n)$ be a decreasing non-negative real sequence with limit $0$.

Let the alternating partial sum sequence $(S_n)$ be defined by $S_n = \sum\limits_{i=1}^{n} (-1)^{i-1}a_i$.

Claim

$S_n$ converges, i.e. $(a_1 - a_2 + a_3 - a_4 + a_5 - a_6 + \dots)$ exists.

Proof

Consider the even and odd subsequences of $(S_n)$.

$S_{\text{even}} = S_{2m} = (a_1 - a_2) + (a_3 - a_4) + \dots + (a_{2m-1} - a_{2m})$. Each of these parenthesised terms is non-negative because $(a_n)$ is a decreasing sequence. Thus $0 \le S_{2m}$, and this is an increasing sequence.

$S_{\text{odd}} = S_{2m+1} = a_1 - (a_2 - a_3) - (a_4 - a_5) - \dots - (a_{2m} - a_{2m+1})$. Each of these parenthesised terms is non-negative because $(a_n)$ is a decreasing sequence. Thus $S_{2m+1} \le a_1$, and this is a decreasing sequence.

We also know that $S_{2m+1} = S_{2m} + a_{2m+1}$ thus $S_{2m} \le S_{2m+1}$. Putting these three inequalities together we have $0 \le S_{2m} \le S_{2m+1} \le a_1$.

$(S_{\text{even}})$ is increasing and bounded above by $a_1$, thus by the monotone sequences property (implied by the least upper bound property of $\R$) it converges. Let the limit be $L_{\text{even}}$.

$(S_{\text{odd}})$ is decreasing and bounded below by $0$, thus by the monotone sequences property it converges. Let the limit be $L_{\text{odd}}$.

The algebra of limits tells us that $(S_{\text{odd}} - S_{\text{even}})$ converges to $L_{\text{odd}} - L_{\text{even}}$. But we also know that $S_{\text{odd}} - S_{\text{even}} = S_{2m+1} - S_{2m} = a_{2m+1}$ which converges to 0. Thus by the uniqueness of limits $L_{\text{odd}} - L_{\text{even}} = 0$, i.e. $L_{\text{odd}} = L_{\text{even}}$.

Now we prove the final step that Wikipedia glosses over. So far we have shown that both the odd and even subsequences converge to the same limit, which we shall now call $L$. We need to show that $S_n$ itself converges to $L$.

Let $\varepsilon \gt 0$. Then $\exists N_{\text{even}}, N_{\text{odd}}$ such that $n \ge N_{\text{even}} \implies | (S_{\text{even}})_n - L | \lt \varepsilon$ and $n \ge N_{\text{odd}} \implies | (S_{\text{odd}})_n - L | \lt \varepsilon$. Let $N_{\text{even}}'$ and $N_{\text{odd}}'$ be these critical indices actually indexing $(S_n)$, as opposed to being respective subsequence indices. Let $N' = \max(N_{\text{even}}', N_{\text{odd}}')$. Then $\forall n \ge N'$, since $S_n$ belongs to one of the subsequences $(S_{\text{even}})$ and $(S_{\text{odd}})$ and $n \ge N' \ge \lbrace N_{\text{odd}}', N_{\text{even}}' \rbrace$, the term $S_n$ satisfies $|S_n - L| \lt \varepsilon$ in the corresponding subsequence.

In other words: for any given epsilon we can scroll past all of the subsequences' critical indices that make each respective subsequence to be within epsilon of the limit, and thus the entire sequence beyond that point is within epsilon of the limit.

Hence overall we can portmanteau this step to $(\forall \varepsilon \gt 0)(\exists N')(\forall n \ge N')(|S_n - L| \lt \varepsilon)$, which is the definition of convergence!

Generalising to finite coverings

The proof above works because the two subsequences cover the original sequence, and both converge to the same limit. We can generalise from two subsequences to $K$ pretty easily, and they don't have to be disjoint either.

Setup

Let $(x_n)$ be a sequence.

Let $(x_n^j)$ where $j \in \lbrace 1, \dots, K \rbrace$ be subsequences of $(x_n)$ such that $\forall n \; \exists j$ such that $x_n \in (x_n^j)$. In other words: every term in the sequence $(x_n)$ is found in at least one of the $K$ subsequences $(x_n^j)$.

Suppose also that $\exists L \in \R$ such that $\forall j \in \lbrace 1, \dots, K \rbrace$ we have $(x_n^j)$ converges to $L$. In other words: each of the $K$ subsequences $(x_n^j)$ converges to a common limit $L$.

Claim

$(x_n)$ itself also converges to $L$.

Proof

Let $\varepsilon \gt 0$. Then $\forall j \in \lbrace 1, \dots, K \rbrace \; \exists N_j$ such that $n \ge N_j \implies |x_n^j - L| \lt \varepsilon$. Let ${N_j}'$ be these critical indices actually indexing $(x_n)$, as opposed to being respective subsequence indices of $(x_n^j)$. Let $N' = \max \limits_j {N_j}'$. Then $\forall n \ge N' \; \exists j$ such that $x_n \in (x_n^j)$, and because $n \ge N' \ge {N_j}'$ we know $x_n$ satisfies $|x_n - L| \lt \varepsilon$ in the corresponding subsequence $(x_n^j)$, hence in $(x_n)$ overall.

So overall we have shown that $(\forall \varepsilon \gt 0)(\exists N')(\forall n \ge N')(|x_n - L| \lt \varepsilon)$.

Outro

There we are! It's a shame that this lemma doesn't have a proper name, like eg Bolzano-Weierstrass[2] does.

It feels somewhat related to compactness[3], that is every open cover has a finite subcover, because we are covering the sequence with a finite number of subsequences that all share a property, that is converges to the same limit just like each of the covering sets are all open.

Infact it's not hard to immediately see that our proof is forwards(?) compatible with topological spaces $(X, \tau)$, where convergence is defined by $(\forall U \in \tau : x \in U)(\exists N)(n \ge N \implies x_n \in U)$. Surely by just asserting this I'm not hypocritically going full-circle on the point of this article, that glossing over obvious results isn't the best? 😅

We will also see below that this proof doesn't also hold for $K = \N$, ie when $(x_n)$ is covered with a countably infinite number of subsequences.

Infinite covering counterexample

We can come up with a counterexample to the claim that when a sequence is covered by a countably infinite number of subsequences, all of which converge to a common limit, then the sequence itself must also converge to that limit. In other words a counterexample to the above claim with $K = \N$.

Setup

Let $(x_n)$ be a sequence.

Let $(x_n^j)$ where $j \in \N$ be subsequences of $(x_n)$ such that $\forall n \; \exists j$ such that $x_n \in (x_n^j)$. In other words: every term in the sequence $(x_n)$ is found in at least one of the subsequences $(x_n^j)$, of which there are countably infinite many.

Suppose also that $\exists L \in \R$ such that $\forall j \in \N$ we have $(x_n^j)$ converges to $L$. In other words: each of the subsequences $(x_n^j)$ converges to a common limit $L$.

Claim

$(x_n)$ itself also converges to $L$.

Counterexample

Method 1

Our approach reminds me of Timothy Gowers's just do it[4] blogpost. I saw him in the CMS at Cambridge a few times in 2017-2020; it's pretty cool and inspiring to see a Fields Medalist[5] in our natural environment!

Let's start with our favourite non-negative decreasing convergent (to 0) sequence, the harmonic sequence $x_n = 1/n$. Let's denote it as $(x_n^1)$, where the $1$ is an index like above, not an exponent.

$(x_n^1) = {\color{red} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{red} \frac{1}{3}}, {\color{red} \frac{1}{4}}, \dots$

We can use multiple copies of $(x_n^1)$ to build up super-sequences $(x_n^2)$, $(x_n^3)$ etc, which constructively converge to a limit sequence $(x_n^{\infty})$. This is non-standard terminology but will become clear. $(x_n^{\infty})$ contains infinitely many copies of $(x_n^{1})$, which converges to 0, but $(x_n^{\infty})$ itself can be made to not converge.

Let's try to create $(x_n^2)$. We can't exactly place two copies of a sequence one after the other as there are infinitely many terms in each, so we need a way to interleave them. Let's try $(x_n^2) = {\color{red} \frac{1}{1}}, {\color{darkorange} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{darkorange} \frac{1}{2}}, {\color{red} \frac{1}{3}}, {\color{darkorange} \frac{1}{3}}, {\color{red} \frac{1}{4}}, {\color{darkorange} \frac{1}{4}}, \dots$, a simple alternation (no pun intended as to this article's first part). This works but it's one of those situations where it's too small to see a pattern just yet.

If we were to construct $(x_n^3)$ etc the same way, enumerating all the $\frac{1}{1}$ then all the $\frac{1}{2}$ etc, this leads to a bunch-up of $(x_n^m)$ containing $m$ copies of $\frac{1}{1}$ at the head of the sequence. This bunch-up blows up as $m \to \infty$, leading to $(x_n^{\infty})$'s only candidate being $x_n^{\infty} = \frac{1}{1}$ which doesn't serve as a counterexample; we have clearly lost the harmonic subsequences.

What if, to avoid the bunch-up, $(x_n^m)$ were decapitated by $m-1$ terms, ie skip the first $m-1$ insertions of the harmonic sequence to construct $(x_n^m)$ from $(x_n^{m-1})$? This leads to $(x_n^{\infty}) = {\color{red} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{darkorange} \frac{1}{2}}, {\color{red} \frac{1}{3}}, {\color{darkorange} \frac{1}{3}}, {\color{lime} \frac{1}{3}}, {\color{red} \frac{1}{4}}, {\color{darkorange} \frac{1}{4}}, {\color{lime} \frac{1}{4}}, {\color{aqua} \frac{1}{4}}, \dots$, which constructively converges as $m \to \infty$, however the overall sequence $(x_n^{\infty})$ clearly converges to 0. What did we lose which makes $(x_n^{\infty}) \to 0$? The answer is that now each fraction $\frac{1}{j}$ only appears $j$ times in $(x_n^{\infty})$, whereas if we were to have them appearing infinitely often then the sequence would not converge. Explicitly, there would be infinitely many $\frac{1}{1}$ spikes keeping $(x_n^{\infty})$ away from our intuitive limit 0, and nor could $(x_n^{\infty})$ converge to $\frac{1}{1}$ as mutatis-mutandis there would be infinitely many $\frac{1}{2}$ spikes. Bonus point: this behaviour generalises to Hausdorff Spaces[6]; if $x_n \to l$ and $x_n = y$ infinitely often then $l = y$.

The sequence above, whilst not the right solution, did solve the bunch-up problem. Looking at it with colour highlighting one can see the staggered appearances of the first (and subsequent) terms of each harmonic subsequence. Perhaps if we start each harmonic subsequence without decapitating it then we have something closer to an answer? $(x_n^{\infty}) = {\color{red} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{darkorange} \frac{1}{1}}, {\color{red} \frac{1}{3}}, {\color{darkorange} \frac{1}{2}}, {\color{lime} \frac{1}{1}}, {\color{red} \frac{1}{4}}, {\color{darkorange} \frac{1}{3}}, {\color{lime} \frac{1}{2}}, {\color{aqua} \frac{1}{1}}, \dots$. This looks promising, and indeed does suffice as an answer!

We gracefully stumbled towards that counterexample. Here are a few more terms, parenthesised for ease of reading (though it's very interesting to note that the parentheses' positions aren't a direct choice from our method, but an emergent end-state; we didn't construct the sequence parentheses-block by parentheses-block (left-to-right), we constructed it colour by colour. This highlights that in mathematics it's important to understand the method to construct something, not just its end presentation, though the latter is important which is why I did a video on improving the presentation of Group Theory's second isomorphism theorem[7]):

$(x_n^{\infty}) = ({\color{red} \frac{1}{1}}), ({\color{red} \frac{1}{2}}, {\color{darkorange} \frac{1}{1}}), ({\color{red} \frac{1}{3}}, {\color{darkorange} \frac{1}{2}}, {\color{lime} \frac{1}{1}}), ({\color{red} \frac{1}{4}}, {\color{darkorange} \frac{1}{3}}, {\color{lime} \frac{1}{2}}, {\color{aqua} \frac{1}{1}}), ({\color{red} \frac{1}{5}}, {\color{darkorange} \frac{1}{4}}, {\color{lime} \frac{1}{3}}, {\color{aqua} \frac{1}{2}}, {\color{blue} \frac{1}{1}}), \dots$

Method 2

Alternatively, my original attempt for this article did not involve the decapitation introspection; I went directly to implementing a staggering mechanism to construct $(x_n^m)$ from $(x_n^{m-1})$.

Starting with $(x_n^2) = {\color{red} \frac{1}{1}}, {\color{darkorange} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{darkorange} \frac{1}{2}}, {\color{red} \frac{1}{3}}, {\color{darkorange} \frac{1}{3}}, {\color{red} \frac{1}{4}}, {\color{darkorange} \frac{1}{4}}, \dots$ from earlier, we notice that we inserted the second harmonic sequence term by term after each term of the first one (red), starting after $\frac{1}{1}$. To construct $(x_n^3)$, what if we insert the next harmonic sequence term by term after the first one, starting after $\frac{1}{2}$? $(x_n^3) = {\color{red} \frac{1}{1}}, {\color{darkorange} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{lime} \frac{1}{1}}, {\color{darkorange} \frac{1}{2}}, {\color{red} \frac{1}{3}}, {\color{lime} \frac{1}{2}}, {\color{darkorange} \frac{1}{3}}, {\color{red} \frac{1}{4}}, {\color{lime} \frac{1}{3}}, {\color{darkorange} \frac{1}{4}}, \dots$. And then to create $(x_n^4)$ insert the next harmonic sequence starting after the red $\frac{1}{3}$. $(x_n^4) = {\color{red} \frac{1}{1}}, {\color{darkorange} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{lime} \frac{1}{1}}, {\color{darkorange} \frac{1}{2}}, {\color{red} \frac{1}{3}}, {\color{aqua} \frac{1}{1}}, {\color{lime} \frac{1}{2}}, {\color{darkorange} \frac{1}{3}}, {\color{red} \frac{1}{4}}, {\color{aqua} \frac{1}{2}}, {\color{lime} \frac{1}{3}}, {\color{darkorange} \frac{1}{4}}, \dots$.

This leads to $(x_n^{\infty}) = {\color{red} \frac{1}{1}}, {\color{darkorange} \frac{1}{1}}, {\color{red} \frac{1}{2}}, {\color{lime} \frac{1}{1}}, {\color{darkorange} \frac{1}{2}}, {\color{red} \frac{1}{3}}, {\color{aqua} \frac{1}{1}}, {\color{lime} \frac{1}{2}}, {\color{darkorange} \frac{1}{3}}, {\color{red} \frac{1}{4}}, {\color{blue} \frac{1}{1}}, {\color{aqua} \frac{1}{2}}, {\color{lime} \frac{1}{3}}, {\color{darkorange} \frac{1}{4}}, {\color{red} \frac{1}{5}}, \dots$ which is just a rearranged version of method 1's counterexample. Here are a few more terms, parenthesised for aesthetics as in method 1:

$(x_n^{\infty}) = ({\color{red} \frac{1}{1}}), ({\color{darkorange} \frac{1}{1}}, {\color{red} \frac{1}{2}}), ({\color{lime} \frac{1}{1}}, {\color{darkorange} \frac{1}{2}}, {\color{red} \frac{1}{3}}), ({\color{aqua} \frac{1}{1}}, {\color{lime} \frac{1}{2}}, {\color{darkorange} \frac{1}{3}}, {\color{red} \frac{1}{4}}), ({\color{blue} \frac{1}{1}}, {\color{aqua} \frac{1}{2}}, {\color{lime} \frac{1}{3}}, {\color{darkorange} \frac{1}{4}}, {\color{red} \frac{1}{5}}), \dots$

Overall I think that method 1 is slightly clearer in convincing one that it works, and I like that the colors end up in order. Method 2 has its truncated harmonic sequence blocks in descending order, which looks nice, but requires more mental overhead in its construction when inserting the next harmonic sequence. It's because in method 2 we're always inserting after the first (red) sequence rather than after the previous, when constructing $(x_n^{m})$ from $(x_n^{m-1})$, which leads to the parenthesised blocks filling from right-to-left.

Finally, scrolling through Gowers's post[8], example 5 inspires me to put our sequence from method 1 in a tabular (matrix-like) form:

${\color{red} \frac{1}{1}}$
${\color{red} \frac{1}{2}}$ ${\color{darkorange} \frac{1}{1}}$
${\color{red} \frac{1}{3}}$ ${\color{darkorange} \frac{1}{2}}$ ${\color{lime} \frac{1}{1}}$
${\color{red} \frac{1}{4}}$ ${\color{darkorange} \frac{1}{3}}$ ${\color{lime} \frac{1}{2}}$ ${\color{aqua} \frac{1}{1}}$
${\color{red} \frac{1}{5}}$ ${\color{darkorange} \frac{1}{4}}$ ${\color{lime} \frac{1}{3}}$ ${\color{aqua} \frac{1}{2}}$ ${\color{blue} \frac{1}{1}}$
$\dots$ $\dots$ $\dots$ $\dots$ $\dots$

read row by row. Nice! Reminds me a bit of counting[9] $\Q$ or $\N \times \N$.

References
[1] - https://en.wikipedia.org/wiki/Alternating_series_test#Proof_of_the_alternating_series_test
[2] - https://en.wikipedia.org/wiki/Bolzano%E2%80%93Weierstrass_theorem
[3] - https://en.wikipedia.org/wiki/Compact_space#Open_cover_definition
[4] - https://gowers.wordpress.com/2008/08/16/just-do-it-proofs/
[5] - https://en.wikipedia.org/wiki/Fields_Medal#:~:text=Timothy%20Gowers
[6] - https://en.wikipedia.org/wiki/Hausdorff_space
[7] - /videos/second-isomorphism-theorem/
[8] - https://gowers.wordpress.com/2008/08/16/just-do-it-proofs/#:~:text=Example%205
[9] - https://en.wikipedia.org/wiki/Rational_number#Countability