First Post

This was my first ever on-line posting, to sci.math in 1988. The world wide web wasn't invented until 1989 so we didn't have links---I added them in 2004 when I posted this to my blog.

Kristian Damm Jensen wrote:

Consider a string of matching parentheses, i.e. a string of parentheses where each prefix contains more left-parentheses than right-parentheses.

Now, given n left- and right parentheses, in how many ways can you order them and still get a string of matching parentheses?

"The Invisible Man" replied:

Here's as far as I got. Possibly far enough, perhaps too far. It looks like someone better at this sort of thing can get a result in closed form.

Let f(n) be the number of valid paren strings of n pairs of parens. (and define f(0) to be 1). We can get a recurrence relationship as follows:

Any string of n paren pairs can be derived uniquely from 2 smaller paren pair strings by considering it to be 1 leading string (possibly null) contained in parens followed by a trailing string: the rest. For example, (())(()())() is a combination of (()) and (()())(). We can thus say that f(n) = sum j=0 to n-1 of f(j)*f(n-1-j)

If this isn't far enough yet, consider g(x) = sum j=0 to infinity of f(j)*(x^j) This is the generating function for f() (see Knuth Vol 1) Using the above recurrence, note that

g^2 = (g - 1)/x

which solved for g gives:

g = (1 - sqrt(1-4x))/(2x)

This can also (i.e. if it does any good) be written as:

g = 2/(1+sqrt(1-4*x))

What we want now is an expression for the nth coefficient for the expansion of g as a power series in x. So, what's the next step?

OK, we want the series for sqrt(1-4x). The binomial thereom gives

sqrt(1-4x)= (1-4x)^(1/2)
          = sum i=0 to infty of C(1/2,i)(-4)^ix^i

where C(n,r)=n!/(r!(n-r)!) is the binomial coefficient. If you're worried about calculating (1/2)! just trust me.

C(n,r)= product i from 1 to r of (n-(i-1))/i
C(1/2,i)(-4)^i = (1/2)(1/2-1)(1/2-2)....(1/2-(i-1))
                 -----------------------------------(-4)^i
                    1   2      3    ....  i
              (-1)(1)(3)...(2i-3)
            = -------------------2^i
                      i!

            = (-1)(1)(3)...(2i-3)(2)(4)(6)...(2i)
              -----------------------------------
                      i! i!
            = -C(2i,i)/(2i-1)

So sqrt(1-4x)= sum i=0 to infty of (-C(2i,i)/(2i-1))x^i.
= -1 - sum i=1 to infty of (C(2i,i)/(2i-1))x^i
let j = i-1
= -1 - sum j=0 to infty of (C(2j+2,j+1)/(2j+1))x^(j+1)
hence g(x) = (1-sqrt(1-4x))/2x
= (sum j=0 to infty of (C(2j+2,j+1)/(2j+1))x^(j+1))/2x
= sum j=0 to infty of (C(2j+2,j+1)/(4j+2))x^j
So f(n) = C(2n+2,n+1)/(4n+2) = C(2n,n)(2n+2)(2n+1) = C(2n,n)/(n+1).
-------------------
(n+1)(n+1)(4n+2)

This is called the Catalan number. It is also the number of different ways of triangulating a convex polygon with n+2 sides, the number of different binary trees with n nodes and the number of different ways of folding a strip of n stamps.

Tags

More like this

Time for the big finale! We now have all the pieces in place to establish the divergence of the sum of the reciprocals of the primes.
In this week's edition of Monday Math we look at what I regard as one of the prettiest equations in number theory. Here it is: \[ \sum_{n=1}^\infty \frac{1}{n^s} = \prod_p \left( \frac{1}{1-\frac{1}{p^s}}\right) \]  
Back before my now-ended blogging hiatus, the server machinery that keeps ScienceBlogs running was not so snazzy as it is now. Now it's running a WordPress implementation that includes LaTeX support. LaTeX is a free environment for (among other things) typesetting mathematics.
It is time to continue our quest to prove that the sum of the reciprocals of the primes diverges. We have one more ingredient to put into place. I am referring to the notion of a Taylor series.