User blog:Vel!/Omega and power towers

This is a problem I stumbled upon a while ago. I only recently managed to write a program to evaluate it.

Consider a power tower of \(\omega\)s of size \(n\). How many different values can we get by putting parentheses in the tower?

Call the result \(W(n)\). It's obvious that \(W(1) = W(2) = 1\). \(W(3) = 2\) because we have \((\omega^\omega)^\omega\) and \(\omega^{(\omega^\omega)}\). We can see that \(W(4) = 5\) through the following configurations:

\[\omega^{\omega^{}\omega^{}\omega^{}},\,\omega^{\omega^{\omega^{\omega^{}}}},\,\omega^{\omega^{\omega^{}\omega^{}}},\,\omega^{\omega^{}\omega^{\omega^{}}},\,\omega^{\omega^{\omega^{}}\omega^{}}\]

How many different values can we expect from an omnitower of size \(n\)? The answer is given by the \(C_n = \frac{1}{2n + 1}{2n\choose n}\). They start out 1, 1, 2, 5, 14, 42, 132, 429, ...