User:Mpaldridge/Faulhaber

In mathematics, Faulhaber's formula, named after the early 17th century mathematician Johann Faulhaber, expresses the sum of the p-th powers of the first n positive integers $$\sum_{k=1}^n k^p = 1^p + 2^p + 3^p + \cdots + n^p$$ as a polynomial in n. In modern notation, Faulhaber's formula is $$ \sum_{k=1}^n k^{p} = \frac{1}{p+1} \sum_{k=0}^p \binom{p+1}{k} B_k n^{p-k+1} .$$ Here, $\binom{p+1}{k}$ is the binomial coefficient "p + 1 choose k", and the Bj are the Bernoulli numbers with the convention that $B_1 = +\frac12$.

The result: Faulhaber's formula
Faulhaber's formula concerns expressing the sum of the p-th powers of the first n positive integers $$\sum_{k=1}^n k^p = 1^p + 2^p + 3^p + \cdots + n^p$$ as a (p + 1)th-degree polynomial function of n.

The first few examples are well known. For p = 0, we have $$\sum_{k=1}^n k^0 = \sum_{k=1}^n 1 = n .$$ For p = 1, we have the triangular numbers $$\sum_{k=1}^n k^1 = \sum_{k=1}^n k = \frac{n(n+1)}{2} = \frac12(n^2 + n) .$$ For p = 2, we have the square pyramidal numbers $$\sum_{k=1}^n k^2 = \frac{n(n+1)(2n+1)}{6} = \frac13(n^3 + \tfrac32 n^2 + \tfrac12n) .$$

The coefficients of Faulhaber's formula in its general form involve the Bernoulli numbers Bj. The Bernoulli numbers begin $$ \begin{align} B_0 &= 1 & B_1 &= \tfrac12 & B_2 &= \tfrac16 & B_3 &= 0 \\ B_4 &= -\tfrac{1}{30} & B_5 &= 0 & B_6 &= \tfrac{1}{42} & B_7 &= 0 , \end{align} $$ where here we use the convention that $B_1 = +\frac12$. The Bernoulli numbers have various definitions (see Bernoulli_number), such as that they are the coefficients of the exponential generating function $$ \frac{t}{1 - \mathrm{e}^{-t}} = \frac{t}{2} \left( \operatorname{coth} \frac{t}{2} +1 \right) = \sum_{k=0}^\infty B^k \frac{t^k}{k!}. $$

Then Faulhaber's formula is that $$ \sum_{k=1}^n k^{p} = \frac{1}{p+1} \sum_{k=0}^p \binom{p+1}{k} B_k n^{p-k+1} .$$ Here, the Bj are the Bernoulli numbers as above, and $$\binom{p+1}{k} = \frac{(p+1)!}{(p+1-k)!\,k!} = \frac{(p+1)p(p-1) \cdots (p-k+3)(p-k+2)}{k(k-1)(k-2)\cdots2\cdot 1}$$ is the binomial coefficient "p + 1 choose k".

So, for example, one has for $p = 4$, $$\begin{align} 1^4 + 2^4 + 3^4 + \cdots + n^4 &= \frac{1}{5} \sum_{j=0}^4 {5 \choose j} B_j n^{5-j}\\ &= \frac{1}{5} \left(B_0 n^5+5B_1n^4+10B_2n^3+10B_3n^2+5B_4n\right)\\ &= \frac{1}{5} \left(n^5 + \tfrac{5}{2}n^4+ \tfrac{5}{3}n^3- \tfrac{1}{6}n \right) .\end{align}$$

The first seven examples of Faulhaber's formula are $$ \begin{align} \sum_{k=1}^n k^0 &=	\frac{1}{1} \, \big(n \big)	\\ \sum_{k=1}^n k^1 &=	\frac{1}{2} \, \big(n^2 + \tfrac{2}{2} n \big)	\\ \sum_{k=1}^n k^2 &=	\frac{1}{3} \, \big(n^3 + \tfrac{3}{2} n^2 + \tfrac{ 3}{6} n \big)	\\ \sum_{k=1}^n k^3 &=	\frac{1}{4} \, \big(n^4 + \tfrac{4}{2} n^3 + \tfrac{ 6}{6} n^2 + 0n \big)	\\ \sum_{k=1}^n k^4 &=	\frac{1}{5} \, \big(n^5 + \tfrac{5}{2} n^4 + \tfrac{10}{6} n^3 + 0n^2 - \tfrac{ 5}{30} n \big)	\\ \sum_{k=1}^n k^5 &=	\frac{1}{6} \, \big(n^6 + \tfrac{6}{2} n^5 + \tfrac{15}{6} n^4 + 0n^3 - \tfrac{15}{30} n^2 + 0n \big)	\\ \sum_{k=1}^n k^6 &=	\frac{1}{7} \, \big(n^7 + \tfrac{7}{2} n^6 + \tfrac{21}{6} n^5 + 0n^4 - \tfrac{35}{30} n^3 + 0n^2 + \tfrac{7}{42}n \big). \end{align}$$

Some authors prefer a definition of the Bernoulli numbers $B_j^-$ where $B_1^- = -\frac12$, rather than $B_1 = +\frac12$ , but that are otherwise the same. With this convention, Faulhaber's formula still gives a polynomial for the first n powers, but now running from 0 to n – 1, rather than from 1 to n. This gives $$ \begin{align} \sum_{k=0}^{n-1} k^{p} &= 0^p + 1^p + 2^p + \cdots + (n-1)^p \\ &= \frac{1}{p+1} \sum_{k=0}^p \binom{p+1}{k} B_k^- n^{p-k+1}. \end{align} $$

History
Faulhaber's formula is also called Bernoulli's formula. Faulhaber did not know the properties of the coefficients later discovered by Bernoulli. Rather, he knew at least the first 17 cases, as well as the existence of the Faulhaber polynomials for odd powers described below.



In 1713, Jacob Bernoulli published under the title Summae Potestatum an expression of the sum of the $p$ powers of the $n$ first integers as a ($p + 1$)th-degree polynomial function of $n$, with coefficients involving numbers $B_{j}$, now called Bernoulli numbers:
 * $$ \sum_{k=1}^n k^{p} = \frac{n^{p+1}}{p+1}+\frac{1}{2}n^p+{1 \over p+1}

\sum_{j=2}^p {p+1 \choose j} B_j n^{p+1-j}.$$

Introducing also the first two Bernoulli numbers (which Bernoulli did not), the previous formula becomes

using the Bernoulli number of the second kind for which, or

using the Bernoulli number of the first kind for which

Faulhaber himself did not know the formula in this form, but only computed the first seventeen polynomials; the general form was established with the discovery of the Bernoulli numbers.

A rigorous proof of these formulas and Faulhaber's assertion that such formulas would exist for all odd powers took until, two centuries later.

Proof with exponential generating function
Let

denote the sum under consideration for integer $$p\ge 0.$$

Define the following exponential generating function with (initially) indeterminate $$z$$

We find

This is an entire function in $$z$$ so that $$z$$ can be taken to be any complex number.

We next recall the exponential generating function for the Bernoulli polynomials $$B_j(x)$$

where $$B_j=B_j(0)$$ denotes the Bernoulli number with the convention $$B_{1}=-\frac{1}{2}$$. This may be converted to a generating function with the convention $$B^+_1=\frac{1}{2}$$ by the addition of $$j$$ to the coefficient of $$x^{j-1}$$ in each $$B_j(x)$$ ($$B_0$$ does not need to be changed):

It follows immediately that

for all $$p$$.

Faulhaber polynomials
The term Faulhaber polynomials is used by some authors to refer to another polynomial sequence related to that given above.

Write $$a = \sum_{k=1}^n k = \frac{n(n+1)}{2}. $$ Faulhaber observed that if p is odd then $\sum_{k=1}^n k^p$ is a polynomial function of a.



For p = 1, it is clear that $$\sum_{k=1}^n k^1 = \sum_{k=1}^n k = \frac{n(n+1)}{2} = a. $$ For p = 3, the result that $$\sum_{k=1}^n k^3 = \frac{n^2(n+1)^2}{4} = a^2 $$ is known as Nicomachus's theorem.

Further, we have $$ \begin{align} \sum_{k=1}^n k^5 &= \frac{4a^3 - a^2}{3} \\ \sum_{k=1}^n k^7 &= \frac{6a^4 -4a^3 + a^2}{3} \\ \sum_{k=1}^n k^9 &= \frac{16a^5 - 20a^4 +12a^3 - 3a^2}{5} \\ \sum_{k=1}^n k^{11} &= \frac{16a^6 - 32a^5 + 34a^4 - 20a^3 + 5a^2}{3} \end{align} $$ (see, , , , ).

More generally, $$ \sum_{k=1}^n k^{2m+1} = \frac{1}{2^{2m+2}(2m+2)} \sum_{q=0}^m \binom{2m+2}{2q} (2-2^{2q})~ B_{2q} ~\left[(8a+1)^{m+1-q}-1\right]. $$

Some authors call the polynomials in a on the right-hand sides of these identities Faulhaber polynomials. These polynomials are divisible by $a^{2}$ because the Bernoulli number $B_{j}$ is 0 for odd $j > 1$.

Faulhaber also knew that if a sum for an odd power is given by $$\sum_{k=1}^n k^{2m+1} = c_1 a^2 + c_2 a^3 + \cdots + c_m a^{m+1}$$ then the sum for the even power just below is given by $$\sum_{k=1}^n k^{2m} = \frac{n+\frac12}{2m+1}(2 c_1 a + 3 c_2 a^2+\cdots + (m+1) c_m a^m).$$ Note that the polynomial in parentheses is the derivative of the polynomial above with respect to a.

Since a = n(n + 1)/2, these formulae show that for an odd power (greater than 1), the sum is a polynomial in n having factors n2 and (n + 1)2, while for an even power the polynomial has factors n, n + ½ and n + 1.

Matrix form
Faulhaber's formula can also be written in a form using matrix multiplication.

Take the first seven examples $$\begin{align} \sum_{k=1}^n k^0 &= n \\ \sum_{k=1}^n k^1 &= \tfrac{1}{2}n+\tfrac{1}{2}n^2 \\ \sum_{k=1}^n k^2 &= \tfrac{1}{6}n+\tfrac{1}{2}n^2+\tfrac{1}{3}n^3 \\ \sum_{k=1}^n k^3 &= \tfrac{1}{4}n^2+\tfrac{1}{2}n^3+\tfrac{1}{4}n^4 \\ \sum_{k=1}^n k^4 &= -\tfrac{1}{30}n+\tfrac{1}{3}n^3+\tfrac{1}{2}n^4+\tfrac{1}{5}n^5 \\ \sum_{k=1}^n k^5 &= -\tfrac{1}{12}n^2+\tfrac{5}{12}n^4+\tfrac{1}{2}n^5+\tfrac{1}{6}n^6 \\ \sum_{k=1}^n k^6 &= \tfrac{1}{42}n-\tfrac{1}{6}n^3+\tfrac{1}{2}n^5+\tfrac{1}{2}n^6+\tfrac{1}{7}n^7. \end{align}$$ Writing these polynomials as a product between matrices gives $$\begin{pmatrix} \sum k^0 \\ \sum k^1 \\ \sum k^2 \\ \sum k^3 \\ \sum k^4 \\ \sum k^5 \\ \sum k^6 \end{pmatrix} = G_7 \begin{pmatrix} n \\ n^2 \\ n^3 \\ n^4 \\ n^5 \\ n^6 \\ n^7 \end{pmatrix} ,$$ where

Surprisingly, inverting the matrix of polynomial coefficients yields something more familiar: $$ G_7^{-1}=\begin{pmatrix} 1& 0&   0&   0&   0&   0& 0\\ -1&  2&   0&   0&   0&   0& 0\\ 1& -3&   3&   0&   0&   0& 0\\ -1&  4&  -6&   4&   0&   0& 0\\ 1& -5&  10& -10&   5&   0& 0\\ -1&  6& -15&  20& -15&   6& 0\\ 1& -7&  21& -35&  35& -21& 7\\ \end{pmatrix} = \overline{A}_7 $$

In the inverted matrix, Pascal's triangle can be recognized, without the last element of each row, and with alternating signs.

Let $$A_7$$ be the matrix obtained from $$\overline{A}_7$$ by changing the signs of the entries in odd diagonals, that is by replacing $$a_{i,j}$$ by $$(-1)^{i+j} a_{i,j}$$, let $$\overline{G}_7$$ be the matrix obtained from $$G_7$$ with a similar transformation, then $$ A_7=\begin{pmatrix} 1& 0& 0&  0&  0&  0& 0\\ 1& 2&  0&  0&  0&  0& 0\\ 1& 3&  3&  0&  0&  0& 0\\ 1& 4&  6&  4&  0&  0& 0\\ 1& 5& 10& 10&  5&  0& 0\\ 1& 6& 15& 20& 15&  6& 0\\ 1& 7& 21& 35& 35& 21& 7\\ \end{pmatrix} $$ and $$ A_7^{-1}=\begin{pmatrix} 1& 0& 0& 0& 0&0& 0\\ -{1\over 2}& {1\over 2}& 0& 0& 0& 0& 0\\ {1\over 6}& -{1\over 2}&{1\over 3}& 0& 0& 0& 0\\ 0& {1\over 4}& -{1\over 2}& {1\over 4}& 0&0& 0\\ -{1\over 30}& 0& {1\over 3}& -{1\over 2}& {1\over 5}&0& 0\\ 0& -{1\over 12}& 0& {5\over 12}& -{1\over 2}& {1\over 6}& 0\\ {1\over 42}& 0& -{1\over 6}& 0& {1\over 2}&-{1\over 2}& {1\over 7} \end{pmatrix}=\overline{G}_7. $$ Also $$\begin{pmatrix} \sum_{k=0}^{n-1} k^0 \\ \sum_{k=0}^{n-1} k^1 \\ \sum_{k=0}^{n-1} k^2 \\ \sum_{k=0}^{n-1} k^3 \\ \sum_{k=0}^{n-1} k^4 \\ \sum_{k=0}^{n-1} k^5 \\ \sum_{k=0}^{n-1} k^6 \\ \end{pmatrix} = \overline{G}_7\begin{pmatrix} n \\ n^2 \\ n^3 \\ n^4 \\ n^5 \\ n^6 \\ n^7 \\ \end{pmatrix} $$ This is because it is evident that $\sum_{k=1}^{n}k^m-\sum_{k=0}^{n-1}k^m=n^m $ and that therefore polynomials of degree $$m+  1$$ of the form $\frac{1}{m+1}n^{m+1}+\frac{1}{2}n^m+\cdots $  subtracted the monomial difference $$ n^m $$ they become $\frac{1}{m+1}n^{m+1}-\frac{1}{2}n^m+\cdots $.

This is true for every order, that is, for each positive integer $m$, one has $$G_m^{-1} = \overline{A}_m$$ and $$\overline{G}_m^{-1} = A_m.$$ Thus, it is possible to obtain the coefficients of the polynomials of the sums of powers of successive integers without resorting to the numbers of Bernoulli but by inverting the matrix easily obtained from the triangle of Pascal.

Alternate expressions
\sum_{k=1}^n k^p= \sum_{k=0}^p {(-1)^{p-k} \over k+1}{p \choose k} B_{p-k} n^{k+1}. $$ \begin{align} G(z,n) &= \frac{e^{(n+1)z}}{e^z -1} - \frac{e^z}{e^z -1}\\ &= \sum_{j=0}^{\infty} \left(B_j(n+1)-(-1)^j B_j\right) \frac{z^{j-1}}{j!}, \end{align} $$ which implies $$ \sum_{k=1}^n k^p = \frac{1}{p+1} \left(B_{p+1}(n+1)-(-1)^{p+1}B_{p+1}\right) = \frac{1}{p+1}\left(B_{p+1}(n+1)-B_{p+1}(1) \right). $$ Since $$B_n = 0$$ whenever $$ n > 1$$ is odd, the factor $$ (-1)^{p+1} $$ may be removed when $$p > 0$$. \sum_{k=0}^n k^p = \sum_{k=0}^p \left\{{p\atop k}\right\}\frac{(n+1)_{k+1}}{k+1}, $$ $$ \sum_{k=1}^n k^p = \sum_{k=1}^{p+1} \left\{{p+1\atop k}\right\}\frac{(n)_k}{k}. $$ This is due to the definition of the Stirling numbers of the second kind as mononomials in terms of falling factorials, and the behaviour of falling factorials under the indefinite sum. This in particular yields the examples below – e.g., take $k = 1$ to get the first example. In a similar fashion we also find
 * By relabelling we find the alternative expression $$
 * We may also expand $$G(z,n)$$ in terms of the Bernoulli polynomials to find $$
 * It can also be expressed in terms of Stirling numbers of the second kind and falling factorials as $$
 * There is also a similar (but somehow simpler) expression: using the idea of telescoping and the binomial theorem, one gets Pascal's identity:


 * Faulhaber's formula was generalized by Guo and Zeng to a $q$-analog.

Relationship to Riemann zeta function
Using $$B_k=-k\zeta(1-k)$$, one can write

If we consider the generating function $$G(z,n)$$ in the large $$n$$ limit for $$\Re (z)<0$$, then we find

Heuristically, this suggests that

This result agrees with the value of the Riemann zeta function $\zeta(s)=\sum_{n=1}^{\infty}\frac{1}{n^s}$ for negative integers $$s=-p<0$$ on appropriately analytically continuing $$\zeta(s)$$.

Umbral form
In the umbral calculus, one treats the Bernoulli numbers $B^0 = 1$, $B^1 = \frac{1}{2}$ , $B^2 = \frac{1}{6}$ as if the index j in Bj were actually an exponent, and so as if the Bernoulli numbers were powers of some object B.

Using this notation, Faulhaber's formula can be written as $$ \sum_{k=1}^n k^p = \frac{1}{p+1} \big( (B+n)^{p+1} - B^{p+1} \big). $$ Here, the expression on the right must be understood by expanding out to get terms B(j) that can then be interpreted as the Bernoulli numbers. Specifically, using the binomial theorem we get $$\begin{align} \frac{1}{p+1} \big( (B+n)^{p+1} - B^{p+1} \big) &= {1 \over p+1} \left( \sum_{k=0}^{p+1} \binom{p+1}{k} B^k n^{p+1-k} - B^{p+1} \right) \\ &= {1 \over p+1} \sum_{k=0}^{p} \binom{p+1}{j} B^k n^{p+1-k} \end{align}$$

A derivation of Faulhaber's formula using the umbral form is available in The Book of Numbers by John Horton Conway and Richard K. Guy.

Classically, this umbral form was considered as a notational convenience. In the modern umbral calculus, on the other hand, this is given a formal mathematical underpinning. One considers the linear functional T on the vector space of polynomials in a variable b given by $T(b^j) = B_j.$ Then one can say $$\begin{align} \sum_{k=1}^n k^p &= {1 \over p+1} \sum_{j=0}^p {p+1 \choose j} B_j n^{p+1-j} \\ &= {1 \over p+1} \sum_{j=0}^p {p+1 \choose j} T(b^j) n^{p+1-j} \\ &= {1 \over p+1} T\left(\sum_{j=0}^p {p+1 \choose j} b^j n^{p+1-j} \right) \\ &= T\left({(b+n)^{p+1} - b^{p+1} \over p+1}\right). \end{align}$$