Sunday, 15 April 2018

Sum of Squares of Integers and Catalan Numbers

As I began reading a new book Catalan Numbers With Applications by Thomas Koshy, I hadn't progressed far before I came across the statement:$$ \sum_{k=1}^n k^2=\frac{n(n+1)(2n+1)}{6}$$At this point, I had to pause because the author had just assumed this result but I couldn't see how to prove it. I needed to do a little digging but before long I came across an interesting proof of the result on this site. The website starts slowly and works out firstly what the sum of the first n integers will be. Here is how it is worked out: $$ \begin{align} (k-1)^2&=k^2-2k+1\\ \text{Rearranging the terms as below:}\\k^2-(k-1)^2&=2k-1\\ \text{Now sum both sides:}\\ \sum_{k=1}^n (k^2-(k-1)^2)&=2 \sum_{k=1}^n k-\sum_{k=1}^n 1\\n^2&=2S_n-n\\S_n&=\frac{n^2+n}{2}\\&=\frac{n(n+1)}{2} \end{align} $$ After this the website goes on to tackle the sum of the squares of the first n integers as follows (using a similar approach): $$\begin{align} (k-1)^3&=k^3-3k^2+3k+1\\ \text{Rearrange the terms: }\\k^3-(k-1)^3&=3k^2-3k-1\\ \text{Summing both sides:}\\ \sum_{k=1}^n (k^3-(k-1)^3)&=3 \sum_{k=1}^n k^2-3 \sum_{k=1}^n k -\sum_{k=1}^n 1\\n^3&=3 \sum_{k=1}^n k^2 -3 \frac{n(n+1)}{2}-n \\ \sum_{k=1}^n k^2&=\frac{1}{3}n^3+\frac{1}{2}n^2+\frac{1}{6}n\\&=\frac{n(n+1)(2n+1)}{6} \end{align}$$ The website then goes on to establish a general result for the sum of integers raised to any power. The question is asked is there a formula for calculating: $$ 1^a+2^a+3^a+ \cdots + (n-1)^a + n^a=\sum_{k=1}^n k^a \text{ ?} $$Well there is, it's called Faulhaber's Formula and involves Bernoulli numbers but I won't go into that here.

For now, I can go on reading my book about the Catalan numbers. I first made a blog post about Catalan numbers back in 2015 on Tuesday the 29th September. This was the first time I'd really heard of them and I didn't delve deeply into them at all in that post. Hopefully I'll have more to say in later posts about these numbers.

The Catalan numbers are of the form: \( \dfrac{1}{n+1} \dbinom{2n}{n} \)

They can be calculated readily enough:
  • in WolframAlpha using catalannumber[n]
  • in SageMath using catalan_number(n)
Talking of SageMath, I've installed the latest version (8.1) on my Mac and am making a concerted effort to make more use of it. I first made a blog post about this free, open source software program in 2017 on the 4th of January. It really is quite impressive in its capabilities so hopefully I can become more adept at using it. Here's a screenshot from my SageMath notebook:


Lastly, the mathematician who lent his name to these numbers, Eugène Catalan, shouldn't be ignored. He was born on the 30th of May 1814 in Bruges, French Empire (now Belgium) and died on the 14th February 1894 in Liège, Belgium. A biography can be found at MacTutor History of Mathematics archive along with biographies of a great many other mathematicians and other interesting material. I first came across this archive in the early naughties and was fascinated to read about the lives of famous mathematicians who had lent their names to so many mathematical tools that I'd used in previous years. L'Hôpital's Rule was a case in point. Although widely used and a greatly useful mathematical tool, who knows anything about the impressively named Guillaume François Antoine Marquis de L'Hôpital who lent his name to the rule?

on Sunday, March 28th 2021
layout improved

No comments:

Post a Comment