Bernoulli Polynomials
Bernoulli Polynomials
B0 (x) = 1,
Z 1
Bn0 (x) = nBn−1 (x) and Bn (x) dx = 0, n ≥ 1. (1)
0
Thus
1 1
B1 (x) = x − , B2 (x) = x2 − x + ,
2 6
2
3x x 1
B3 (x) = x3 − + , B4 (x) = x4 − 2x3 + x2 − ,
2 2 30
5x4 5x3 x 5x4 x2 1
B5 (x) = x5 − + − , B6 (x) = x6 − 3x5 + − + ,
2 3 6 2 2 42
6 5 3 6 4
7x 7x 7x x 14x 7x 2x2 1
B7 (x) = x7 − + − + , B8 (x) = x8 − 4x7 + − + − ,
2 2 6 6 3 3 3 30
8 5 8 2
9x 21x 3x 15x 3x 5
B9 (x) = x9 − +6x7 − +2x3 − , B10 (x) = x10 −5x9 + −7x6 +5x4 − + ,
2 5 10 2 2 66
11x10 55x9 11x3 5x
B11 (x) = x11 − + − 11x7 + 11x5 − + ,
2 6 2 6
8 4
33x 33x 691
B12 (x) = x12 − 6x11 + 11x10 − + 22x6 − + 5x2 − , ....
2 2 2730
The constant term gives the nth Bernoulli number, Bn = Bn (0),
1 1 1 1 1
B0 = 1, B1 = − , B2 = , B3 = 0, B4 = − , B5 = 0, B6 = , B7 = 0, B8 = − ,
2 6 30 42 30
5 691 7 3617
B9 = 0, B10 = , B11 = 0, B12 = − , B13 = 0, B14 = , B15 = 0, B16 = − ,
66 2730 6 510
43867 174611
B17 = 0, B18 = , B19 = 0, B20 = − , ....
798 330
There is some merit in defining what one might call the alternative Bernoulli polynomials:
B
b0 (x) = 1,
Z 1
bn0 (x) = nB
B bn−1 (x) and B
bn (x) dx = 1, n ≥ 1.
0
b1 = 1 = − B1 ,
B B
bn = Bn , n = 0, 2, 3, 4, . . . .
2
1
The graphs show that Bn (1 − x) = (−1)n Bn (x). From the definition, the coefficient of x
0 m n
is Bn (0) = nBn−1 . More generally, the coefficient of x in Bn (x) is m Bn−m ; hence
n
X n
Bn (x) = Bn−m xm .
m=0
m
0.15
0.10
0.05
-0.05
The generating functions for the Bernoulli polynomials and the Bernoulli numbers are
respectively
∞ ∞
text X tn t X tn
= Bn (x) and = Bn . (2)
et − 1 n=0
n! et − 1 n=0
n!
These could be used as definitions; then the left-hand equality in (1) is recovered by
differentiating the left-hand equality in (2) with respect to x:
∞ ∞ 0 ∞
t2 ext X
0 tn text X
0 tn−1 X Bn+1 (x) tn
= B (x) ⇒ = B (x) = · .
ex − 1 n=1 n n! ex − 1 n=1 n n! n=0
n+1 n!
From the right-hand equality in (2) we obtain two facts: (i) B2n+1 = 0 for n ≥ 1 since the
function t/(et − 1) + t/2 is even, and (ii) multiplying the series by the Taylor expansion
of (et − 1)/t gives
n
X n+1
Bk = 0n .
k=0
k
This last equality can be used to compute the Bn recursively; see Lovelace [3], for example.
2
Stirling numbers of the second kind
The Stirling number of the second kind S(n, k) is the number of ways to partition a set
of n objects into k non-empty subsets:
k k
(−1)k X
1 X k−j k n j k
S(n, k) = (−1) j = (−1) j n,
k! j=0 j k! j=0 j
k
n 0 1 2 3 4 5 6 7 8 9 10
0 1 0 0 0 0 0 0 0 0 0 0
1 0 1 0 0 0 0 0 0 0 0 0
2 0 1 1 0 0 0 0 0 0 0 0
3 0 1 3 1 0 0 0 0 0 0 0
4 0 1 7 6 1 0 0 0 0 0 0
5 0 1 15 25 10 1 0 0 0 0 0
6 0 1 31 90 65 15 1 0 0 0 0
7 0 1 63 301 350 140 21 1 0 0 0
8 0 1 127 966 1701 1050 266 28 1 0 0
9 0 1 255 3025 7770 6951 2646 462 36 1 0
10 0 1 511 9330 34105 42525 22827 5880 750 45 1
It is clear from the recursive definition that the S(n, k) are integers, P
that S(n, n) =
1 and
that S(n, k) = 0 if k > n. Interesting problem: prove directly that kj=0 (−1)j kj j n = 0
whenever k > n > 0.
1000
800
600
400
200
k
50 100 150 200 250 300
Plot of log S(n, k) + 1 for k = 5, 10, . . . and n = 1, 2, . . . , 300
3
Euler–Maclaurin summation
Let f (x) be a sufficiently well-behaved function. Suppose we want to sum f (x) over
integer values of x and that we know how to integrate f (x). Let m < n be integers. Then
n Z n r bk Z n br (bxc − x)
X X
(k−1) (k−1)
B B
f (r) = f (x) dx + f (n) − f (m) − f (r) (x) dx,
k=m+1 m k=1
k! m r!
Poly-Bernoulli numbers
(k)
If we define the more general poly-Bernoulli numbers Bn by
∞ ∞
X tm Lik (1 − e−t ) X
(k) t
n
Lik (t) = , = Bn ,
m=1
m k 1 − e−t n=0
n!
(1)
then k = 1 gives Li1 (x) = − log(1−x) and the generating function t/(1−e−t ) of Bn = B
bn .
4
But S(n, k) = 0 when k > n. Hence
∞ n
x X xn X (−1)k
= k!S(n, k),
ex − 1 n=0
n! k=0 k + 1
as required to get the right-hand expression in (3). The other expression follows by
substituting for S(n, k).
Proof Suppose n ≥ 2 is even. We consider each of the terms in the sum over k in either
of the two expressions of (3).
If k + 1 is not prime and k > 3, then k!/(k + 1) is an integer, as also is S(n, k); so the
term corresponding to this k is an integer. Also one can verify directly that the terms
corresponding to k = 0 and k = 3 are integers.
Now suppose k + 1 is prime and k does not divide n. Write n = qk + r with 0 < r < k.
qk
Pk for 0j <kj r≤ k, j ≡ 1 (mod k + 1). Hence modulo k + 1 the sum over j becomes
Then
j=0 (−1) j j = ±k!S(r, k) = 0 since k > r.
Finally, suppose k + 1 is
Pprime and k divides n. Then for 0 < j ≤ k, j n ≡ 1 (mod k + 1),
k
and 0 = 0. Therefore j=0 (−1)j kj j n ≡ −1 (mod k + 1) and hence modulo 1 there is a
n
When n is odd the sum is zero modulo 1; the k = 1 term contributes 1/2, as before, but
now the k = 3 term also contributes 1/2. All other k terms are integers.
The Von Staudt–Clausen theorem allows you to compute the fractional part of Bn for
some quite large n. For example, if n = 28000000000 , the divisors of n are powers of two and
the denominators of the fractions in (4) are just 2 and the Fermat primes, 3, 5, 17, 257 and
65537. On the other hand, the calculation is currently impossible for, say, n = 29000000000 .
It is convenient to have an expression for the absolute value of Bn . So we rearrange (4)
to get, writing {x} for x − bxc,
nP o
p−1|n, p prime 1/p , n > 0, n ≡ 0 (mod 4),
n P o
1−
p−1|n, p prime 1/p , n ≡ 2 (mod 4),
|Bn | = b|Bn |c + (5)
0, n = 0,
1/2, n = 1,
0, n > 1, n odd.
bn = − nζ(1 − n), n ≥ 0; 2 n!
B Bn = − ζ(n), even n ≥ 0. (6)
(2πi)n
Proof (Titchmarsh [6, section 2.4]) Let s be a complex veriable with Re s > 1. Using
Z ∞
Γ(s)
xs−1 e−kx dx =
0 ks
we get
∞ Z ∞ ∞ ∞ ∞
xs−1
X Z X Z
s−1 −ks s−1 −kx
Γ(s)ζ(s) = x e dx = x e dx = dx.
k=1 0 0 k=1 0 ex − 1
Let Cρ , ρ > 0, denote the contour that goes from +∞ to ρ on the real axis, circles the
origin once anticlockwise and then returns to +∞. Let ρ → 0. Since the integral along
the circle tends to zero as ρ tends to zero, we have
Z 0 s−1 Z ∞ 2πi s−1
z s−1
Z
z (e z)
z
dz = z
dz + z −1
dz = (e2πis − 1)Γ(s)ζ(s).
C0 e − 1 ∞ e − 1 0 e
which extends the domain of ζ(s) to the whole complex plane except for s = 1. Now let
n ≥ 1 be an integer and put s = 1 − n. Then
∞
(−1)n−1 (n − 1)! z −n (−1)n−1 (n − 1)!
Z Z X
Bk k−n−1
ζ(1 − n) = z
dz = z dz.
2πi C0 e − 1 2πi C0 k=0 k!
But the value of integral on the right is 2πi times the residue of the pole at z = 0, and
this is just the coefficient of 1/z in the sum. Hence, recalling that B1 = −B
b1 and Bn = 0
for odd n ≥ 3,
Of course we can discard the sign if we are interested only in the absolute value:
2 n! 2 n! 1 1
|Bn | = ζ(n) = 1 + n + n + . . . , even n ≥ 2. (7)
(2π)n (2π)n 2 3
6
We can use (5) and (7) to determine |Bn | exactly. Write b(n) = (2 n!)1/n /(2π). Then split
the sum into three parts,
|Bn | = In + En + Rn ,
db(n)e n db(n)e n ∞ n
X b(n) X b(n) X b(n)
In = , En = − In , Rn = .
k=1
k k=1
k k
k=db(n)+1e
References
[1] H. M. Edwards, Riemann’s Zeta-Function.
[2] TF, Problem 267.4 – Bernoulli numbers, M500 267 (December 2015).
[3] A. A. Lovelace, Note G in: L. F. Menabrea, Sketch of The Analytical Engine Invented
by Charles Babbage With notes upon the Memoir by the Translator, Ada Augusta,
Countess of Lovelace, Bibliothèque Universelle de Genève 82 (October 1842).
[4] R. Thompson, Bernoulli numbers and prime generating functions, M500 267 (De-
cember 2015).