### Bernoulli Numbers and the Harmonic Oscillator

#### Posted by John Baez

I keep wanting to understand Bernoulli numbers more deeply, and people keep telling me stuff that’s fancy when I want to understand things *simply*. But let me try again.

The Bernoulli numbers can be defined like this:

$\frac{x}{e^x - 1} = B_0 + B_1 x + B_2 \frac{x^2}{2!} + B_3 \frac{x^3}{3!} + \cdots$

and if you grind them out, you get

$\begin{array}{lcr} B_0 &=& 1 \\ B_1 &=& -\frac{1}{2} \\ B_2 &=& \frac{1}{6} \\ B_3 &=& 0 \\ B_4 &=& -\frac{1}{30} \end{array}$

and so on. The pattern is quite strange.

Bernoulli numbers are connected to hundreds of interesting things. For example if you want to figure out a sum like

$1^{10} + \cdots + 1000^{10}$

you can use Bernoulli numbers — indeed Jakob Bernoulli boasted

It took me less than half of a quarter of an hour to find that the tenth powers of the first 1000 numbers being added together will yield the sum 91,409,924,241,424,243,424,241,924,242,500.

For some more mysterious appearances of the Bernoulli numbers, see:

- John Baez, Bernoulli numbers and the $J$-homomorphism.

But where the hell did this function $x/(e^x - 1)$ come from?

If $D$ means derivative:

$(D f)(x) = f'(x)$

then $e^D - 1$ is a so-called ‘difference operator’:

$((e^D - 1)f)(x) = f(x+1) - f(x)$

which you can show using the Taylor series for $f$ if $f$ is an entire function. So $D/(e^D - 1)$ is about derivatives versus differences, and its inverse is about integrals versus sums. This lets you reduce sums like the one above to integrals… *if* you know your Bernoulli numbers. For details try this:

- John Baez, Bernoulli numbers.

But $x/(e^x - 1)$ also shows up when you compute the expected energy of a quantum harmonic oscillator in thermal equilibrium!

Let’s work in units where Planck’s constant and Boltzmann’s constant are $1$. Say we have a quantum harmonic oscillator whose allowed energies are $0, 1, 2, 3, \dots$ etcetera. (Sometimes people add $\frac{1}{2}$ to each of these numbers, but let’s not.) If we compute this oscillator’s average or ‘expected’ energy at temperature $T$, and divide it by $T$, we get

$\frac{x}{e^x - 1}$

where

$x = \frac{1}{T}$

So the quantum harmonic oscillator secretly knows about Bernoulli numbers.

What does this fact really mean??? I don’t know. I once read a book called *Triangle of Thought* about a conversation between Alain Connes and two other mathematicians, and he vaguely alluded to a fact of this sort, and said it was important.

I forget exactly what Connes said, so I imagine it’s something about how the Todd class in algebraic topology, which is usually defined using the function $x/(1 - e^{-x})$ (whose power series also gives Bernoulli numbers), can be understood using the harmonic oscillator—perhaps because it appears in the Riemann–Roch theorem, which can probably be proved using ideas from quantum field theory (since it’s a special case of the Atiyah–Singer index theorem, which has a quantum proof). But all this erudite stuff is probably a complicated *spinoff* of the basic ideas, and I’d like to understand the basic ideas first.

By the way, here you can see a calculation of the expected energy of a quantum harmonic oscillator:

And here’s a little sanity check which is rather revealing. I said the expected energy divided by temperature is

$\frac{x}{e^x - 1}$

where $x = 1/T$. But in the limit $T \to +\infty$ the quantum harmonic oscillator should reduce to the classical harmonic oscillator. For *that*, the expected energy divided by temperature is just 1, since the oscillator has 2 degrees of freedom (position and momentum), and the equipartition theorem, which holds for classical systems with quadratic Hamiltonians, says we should get 1/2 times the number of degrees of freedom. And indeed, it works just as we’d expect:

$\lim_{x \to 0} \frac{x}{e^x - 1} = 1$

This limit is also, by definition, the zeroth Bernoulli number. So the zeroth Bernoulli number is telling us the energy over temperature of a quantum harmonic oscillator in the high-temperature limit. The rest of the Bernoulli numbers are telling us all the ‘low-temperature corrections’ to the oscillator’s energy over temperature:

$\frac{x}{e^x - 1} = B_0 + B_1 x + B_2 \frac{x^2}{2!} + B_3 \frac{x^3}{3!} + \cdots$

where $x = 1/T$.

I hope that if I think about it a bit harder, I’ll see that we’re using an analogy:

derivative operator $D$ : difference operator $e^D - 1$ ::

classical harmonic oscillator : quantum harmonic oscillator

and that Bernoulli numbers arise from comparing the derivative and the difference operator — or comparing the classical harmonic oscillator with its continuous energy spectrum, to the quantum oscillator, with its discretely spaced energy spectrum — or more poetically, the continuous and the discrete!

## Re: Bernoulli Numbers and the Harmonic Oscillator

Misc. comments:

You might be interested in “Interactions between Lie theory and algebraic geometry” by Shilin Yu, tying together the GRR and the BCH formula.

The Todd op (mod signs) and its inverse are usually presented as differential ops, but, in a new MathOverflow question (not well received), I present the Todd op and its inverse also in terms purely of the finite difference op, which makes a direct connection to the Helmut Hasse formula for the Hurwitz zeta function and the Bernoulli function that Milnor presented in one of his papers. (The finite diff rep actually allows one of his divergent series derived from the diff op rep and related to the Harer-Zagier formula to be derived as a convergent series, but it is the asymptotic series that is desired.)

The Hurwitz $\zeta(s,z)$ is related to the Bernoulli function via the derivative $B_s(z)=-\partial_z \zeta(-s,z) = -s\zeta(-s+1,z)$, which evaluates as the Bernoulli polynomial $B_n(x)$ for a positive integer $n=s$. Alternatively, a Mellin transform gives the same result. The Hurwitz zeta and the Barnes zeta function (which can be expanded in terms of the Hurwtiz zeta) are related to the Casimir effect, Bose-Eisntein condensation, and solutions for the Schrodinger equation of atoms in a harmonic oscillator potential in “Basic zeta functions and some applications in physics” by Klaus Kirsten.