Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... ·...

170
Catalan Numbers Catalan Numbers Murray Bremner University of Saskatchewan, Canada University of Cape Town, Monday 30 November 2015

Transcript of Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... ·...

Page 1: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Catalan Numbers

Murray Bremner

University of Saskatchewan, Canada

University of Cape Town, Monday 30 November 2015

Page 2: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 1

Catalan numbers arise from a simple enumeration problem:

In how many different ways can we compute the productof n factors which don’t commute?

With three factors abc there are two multiplications to performand we can do them either in one order (ab)c or the other a(bc).

We can represent these possibilities as rooted planar binary trees:

a b

c

a ∗

b c

The asterisks represent multiplications, and the two subtrees beloweach asterisk represent the two factors being multiplied.

Page 3: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 1

Catalan numbers arise from a simple enumeration problem:

In how many different ways can we compute the productof n factors which don’t commute?

With three factors abc there are two multiplications to performand we can do them either in one order (ab)c or the other a(bc).

We can represent these possibilities as rooted planar binary trees:

a b

c

a ∗

b c

The asterisks represent multiplications, and the two subtrees beloweach asterisk represent the two factors being multiplied.

Page 4: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 1

Catalan numbers arise from a simple enumeration problem:

In how many different ways can we compute the productof n factors which don’t commute?

With three factors abc there are two multiplications to performand we can do them either in one order (ab)c or the other a(bc).

We can represent these possibilities as rooted planar binary trees:

a b

c

a ∗

b c

The asterisks represent multiplications, and the two subtrees beloweach asterisk represent the two factors being multiplied.

Page 5: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 1

Catalan numbers arise from a simple enumeration problem:

In how many different ways can we compute the productof n factors which don’t commute?

With three factors abc there are two multiplications to performand we can do them either in one order (ab)c or the other a(bc).

We can represent these possibilities as rooted planar binary trees:

a b

c

a ∗

b c

The asterisks represent multiplications, and the two subtrees beloweach asterisk represent the two factors being multiplied.

Page 6: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 1

Catalan numbers arise from a simple enumeration problem:

In how many different ways can we compute the productof n factors which don’t commute?

With three factors abc there are two multiplications to performand we can do them either in one order (ab)c or the other a(bc).

We can represent these possibilities as rooted planar binary trees:

a b

c

a ∗

b c

The asterisks represent multiplications, and the two subtrees beloweach asterisk represent the two factors being multiplied.

Page 7: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 1

Catalan numbers arise from a simple enumeration problem:

In how many different ways can we compute the productof n factors which don’t commute?

With three factors abc there are two multiplications to performand we can do them either in one order (ab)c or the other a(bc).

We can represent these possibilities as rooted planar binary trees:

a b

c

a ∗

b c

The asterisks represent multiplications, and the two subtrees beloweach asterisk represent the two factors being multiplied.

Page 8: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 1

Catalan numbers arise from a simple enumeration problem:

In how many different ways can we compute the productof n factors which don’t commute?

With three factors abc there are two multiplications to performand we can do them either in one order (ab)c or the other a(bc).

We can represent these possibilities as rooted planar binary trees:

a b

c

a ∗

b c

The asterisks represent multiplications, and the two subtrees beloweach asterisk represent the two factors being multiplied.

Page 9: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

With four factors, there are five ways to compute the product:

a b

c

d

a ∗

b c

d

a b

c d

a ∗

b c

d

a ∗

b ∗

c d

Page 10: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

With four factors, there are five ways to compute the product:

a b

c

d

a ∗

b c

d

a b

c d

a ∗

b c

d

a ∗

b ∗

c d

Page 11: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

With four factors, there are five ways to compute the product:

a b

c

d

a ∗

b c

d

a b

c d

a ∗

b c

d

a ∗

b ∗

c d

Page 12: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Using parentheses these sequences of multiplications look like this:

((ab)c)d , (a(bc))d , (ab)(cd),

a((bc)d), a(b(cd)).

For 5, 6, 7, 8, 9, 10, . . . factors the number of possibilities is

14, 42, 132, 429, 1430, 4862, . . .

Is there a simple compact formula for the terms of this sequence?

If there is, how do we go about finding it?

First, let’s consider some other applications of Catalan numbers.

Page 13: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Using parentheses these sequences of multiplications look like this:

((ab)c)d , (a(bc))d , (ab)(cd),

a((bc)d), a(b(cd)).

For 5, 6, 7, 8, 9, 10, . . . factors the number of possibilities is

14, 42, 132, 429, 1430, 4862, . . .

Is there a simple compact formula for the terms of this sequence?

If there is, how do we go about finding it?

First, let’s consider some other applications of Catalan numbers.

Page 14: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Using parentheses these sequences of multiplications look like this:

((ab)c)d , (a(bc))d , (ab)(cd),

a((bc)d), a(b(cd)).

For 5, 6, 7, 8, 9, 10, . . . factors the number of possibilities is

14, 42, 132, 429, 1430, 4862, . . .

Is there a simple compact formula for the terms of this sequence?

If there is, how do we go about finding it?

First, let’s consider some other applications of Catalan numbers.

Page 15: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Using parentheses these sequences of multiplications look like this:

((ab)c)d , (a(bc))d , (ab)(cd),

a((bc)d), a(b(cd)).

For 5, 6, 7, 8, 9, 10, . . . factors the number of possibilities is

14, 42, 132, 429, 1430, 4862, . . .

Is there a simple compact formula for the terms of this sequence?

If there is, how do we go about finding it?

First, let’s consider some other applications of Catalan numbers.

Page 16: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Using parentheses these sequences of multiplications look like this:

((ab)c)d , (a(bc))d , (ab)(cd),

a((bc)d), a(b(cd)).

For 5, 6, 7, 8, 9, 10, . . . factors the number of possibilities is

14, 42, 132, 429, 1430, 4862, . . .

Is there a simple compact formula for the terms of this sequence?

If there is, how do we go about finding it?

First, let’s consider some other applications of Catalan numbers.

Page 17: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Using parentheses these sequences of multiplications look like this:

((ab)c)d , (a(bc))d , (ab)(cd),

a((bc)d), a(b(cd)).

For 5, 6, 7, 8, 9, 10, . . . factors the number of possibilities is

14, 42, 132, 429, 1430, 4862, . . .

Is there a simple compact formula for the terms of this sequence?

If there is, how do we go about finding it?

First, let’s consider some other applications of Catalan numbers.

Page 18: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Using parentheses these sequences of multiplications look like this:

((ab)c)d , (a(bc))d , (ab)(cd),

a((bc)d), a(b(cd)).

For 5, 6, 7, 8, 9, 10, . . . factors the number of possibilities is

14, 42, 132, 429, 1430, 4862, . . .

Is there a simple compact formula for the terms of this sequence?

If there is, how do we go about finding it?

First, let’s consider some other applications of Catalan numbers.

Page 19: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Asymptotics:

Cn ∼4n

n3/2√π

as n→∞

This follows from the formula we will prove and Stirling’s formula:

n! ∼√

2πn(ne

)nas n→∞

The Catalan numbers appear as the solution to a very largenumber of different combinatorial problems.

Richard Stanley’s Enumerative Combinatorics: Volume 2(Cambridge U. Press, 1999) has an exercise which gives 66different interpretations of the Catalan numbers.

The Catalan numbers appear as sequence A000108 in the OEIS(On-Line Encyclopedia of Integer Sequences, oeis.org):“This is probably the longest entry in the OEIS, and rightly so.”

Page 20: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Asymptotics:

Cn ∼4n

n3/2√π

as n→∞

This follows from the formula we will prove and Stirling’s formula:

n! ∼√

2πn(ne

)nas n→∞

The Catalan numbers appear as the solution to a very largenumber of different combinatorial problems.

Richard Stanley’s Enumerative Combinatorics: Volume 2(Cambridge U. Press, 1999) has an exercise which gives 66different interpretations of the Catalan numbers.

The Catalan numbers appear as sequence A000108 in the OEIS(On-Line Encyclopedia of Integer Sequences, oeis.org):“This is probably the longest entry in the OEIS, and rightly so.”

Page 21: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Asymptotics:

Cn ∼4n

n3/2√π

as n→∞

This follows from the formula we will prove and Stirling’s formula:

n! ∼√

2πn(ne

)nas n→∞

The Catalan numbers appear as the solution to a very largenumber of different combinatorial problems.

Richard Stanley’s Enumerative Combinatorics: Volume 2(Cambridge U. Press, 1999) has an exercise which gives 66different interpretations of the Catalan numbers.

The Catalan numbers appear as sequence A000108 in the OEIS(On-Line Encyclopedia of Integer Sequences, oeis.org):“This is probably the longest entry in the OEIS, and rightly so.”

Page 22: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Asymptotics:

Cn ∼4n

n3/2√π

as n→∞

This follows from the formula we will prove and Stirling’s formula:

n! ∼√

2πn(ne

)nas n→∞

The Catalan numbers appear as the solution to a very largenumber of different combinatorial problems.

Richard Stanley’s Enumerative Combinatorics: Volume 2(Cambridge U. Press, 1999) has an exercise which gives 66different interpretations of the Catalan numbers.

The Catalan numbers appear as sequence A000108 in the OEIS(On-Line Encyclopedia of Integer Sequences, oeis.org):“This is probably the longest entry in the OEIS, and rightly so.”

Page 23: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Asymptotics:

Cn ∼4n

n3/2√π

as n→∞

This follows from the formula we will prove and Stirling’s formula:

n! ∼√

2πn(ne

)nas n→∞

The Catalan numbers appear as the solution to a very largenumber of different combinatorial problems.

Richard Stanley’s Enumerative Combinatorics: Volume 2(Cambridge U. Press, 1999) has an exercise which gives 66different interpretations of the Catalan numbers.

The Catalan numbers appear as sequence A000108 in the OEIS(On-Line Encyclopedia of Integer Sequences, oeis.org):

“This is probably the longest entry in the OEIS, and rightly so.”

Page 24: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Asymptotics:

Cn ∼4n

n3/2√π

as n→∞

This follows from the formula we will prove and Stirling’s formula:

n! ∼√

2πn(ne

)nas n→∞

The Catalan numbers appear as the solution to a very largenumber of different combinatorial problems.

Richard Stanley’s Enumerative Combinatorics: Volume 2(Cambridge U. Press, 1999) has an exercise which gives 66different interpretations of the Catalan numbers.

The Catalan numbers appear as sequence A000108 in the OEIS(On-Line Encyclopedia of Integer Sequences, oeis.org):“This is probably the longest entry in the OEIS, and rightly so.”

Page 25: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Dyck words: Cn is the number of Dyck words of length 2n, wherea Dyck word is a string of n a’s and n b’s such that no initialsegment of the string has more b’s than a’s. For example:

n = 1 : ab

n = 2 : aabb, abab

n = 3 : aaabbb, aababb, aabbab, abaabb, ababab

This is equivalent to another parentheses problem: if we replace aby (, and b by ), we obtain these placements of parentheses:

n = 1 : ()

n = 2 : (()), ()()

n = 3 : ((())), (()()), (())(), ()(()), ()()()

Exercise: Find a bijection between these parenthesizations andthose in our original formulation of the enumeration problem.

Page 26: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Dyck words: Cn is the number of Dyck words of length 2n, wherea Dyck word is a string of n a’s and n b’s such that no initialsegment of the string has more b’s than a’s. For example:

n = 1 : ab

n = 2 : aabb, abab

n = 3 : aaabbb, aababb, aabbab, abaabb, ababab

This is equivalent to another parentheses problem: if we replace aby (, and b by ), we obtain these placements of parentheses:

n = 1 : ()

n = 2 : (()), ()()

n = 3 : ((())), (()()), (())(), ()(()), ()()()

Exercise: Find a bijection between these parenthesizations andthose in our original formulation of the enumeration problem.

Page 27: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Dyck words: Cn is the number of Dyck words of length 2n, wherea Dyck word is a string of n a’s and n b’s such that no initialsegment of the string has more b’s than a’s. For example:

n = 1 : ab

n = 2 : aabb, abab

n = 3 : aaabbb, aababb, aabbab, abaabb, ababab

This is equivalent to another parentheses problem: if we replace aby (, and b by ), we obtain these placements of parentheses:

n = 1 : ()

n = 2 : (()), ()()

n = 3 : ((())), (()()), (())(), ()(()), ()()()

Exercise: Find a bijection between these parenthesizations andthose in our original formulation of the enumeration problem.

Page 28: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lattice paths: Given a positive integer n, imagine that you mustfollow a path in the (x , y) plane satisfying these conditions:

You must start at the point (0, 0).

You must take steps of length 1, east (1, 0) or north (0, 1).

You must not pass above the diagonal line y = x .

You must end at the point (n, n).

How many different paths are there which satisfy these conditions?

The answer is the Catalan number Cn.

In fact, there is a simple bijection between Dyck words and theselattice paths: interpret a as “go east”, and b as “go north”.

The condition that a Dyck word has the same number of a’s andb’s guarantees that the lattice path ends at (n, n).

The condition that no initial segment of a Dyck word has more b’sthan a’s guarantees that the lattice path stays below the diagonal.

Page 29: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lattice paths: Given a positive integer n, imagine that you mustfollow a path in the (x , y) plane satisfying these conditions:

You must start at the point (0, 0).

You must take steps of length 1, east (1, 0) or north (0, 1).

You must not pass above the diagonal line y = x .

You must end at the point (n, n).

How many different paths are there which satisfy these conditions?

The answer is the Catalan number Cn.

In fact, there is a simple bijection between Dyck words and theselattice paths: interpret a as “go east”, and b as “go north”.

The condition that a Dyck word has the same number of a’s andb’s guarantees that the lattice path ends at (n, n).

The condition that no initial segment of a Dyck word has more b’sthan a’s guarantees that the lattice path stays below the diagonal.

Page 30: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lattice paths: Given a positive integer n, imagine that you mustfollow a path in the (x , y) plane satisfying these conditions:

You must start at the point (0, 0).

You must take steps of length 1, east (1, 0) or north (0, 1).

You must not pass above the diagonal line y = x .

You must end at the point (n, n).

How many different paths are there which satisfy these conditions?

The answer is the Catalan number Cn.

In fact, there is a simple bijection between Dyck words and theselattice paths: interpret a as “go east”, and b as “go north”.

The condition that a Dyck word has the same number of a’s andb’s guarantees that the lattice path ends at (n, n).

The condition that no initial segment of a Dyck word has more b’sthan a’s guarantees that the lattice path stays below the diagonal.

Page 31: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lattice paths: Given a positive integer n, imagine that you mustfollow a path in the (x , y) plane satisfying these conditions:

You must start at the point (0, 0).

You must take steps of length 1, east (1, 0) or north (0, 1).

You must not pass above the diagonal line y = x .

You must end at the point (n, n).

How many different paths are there which satisfy these conditions?

The answer is the Catalan number Cn.

In fact, there is a simple bijection between Dyck words and theselattice paths: interpret a as “go east”, and b as “go north”.

The condition that a Dyck word has the same number of a’s andb’s guarantees that the lattice path ends at (n, n).

The condition that no initial segment of a Dyck word has more b’sthan a’s guarantees that the lattice path stays below the diagonal.

Page 32: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lattice paths: Given a positive integer n, imagine that you mustfollow a path in the (x , y) plane satisfying these conditions:

You must start at the point (0, 0).

You must take steps of length 1, east (1, 0) or north (0, 1).

You must not pass above the diagonal line y = x .

You must end at the point (n, n).

How many different paths are there which satisfy these conditions?

The answer is the Catalan number Cn.

In fact, there is a simple bijection between Dyck words and theselattice paths: interpret a as “go east”, and b as “go north”.

The condition that a Dyck word has the same number of a’s andb’s guarantees that the lattice path ends at (n, n).

The condition that no initial segment of a Dyck word has more b’sthan a’s guarantees that the lattice path stays below the diagonal.

Page 33: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lattice paths: Given a positive integer n, imagine that you mustfollow a path in the (x , y) plane satisfying these conditions:

You must start at the point (0, 0).

You must take steps of length 1, east (1, 0) or north (0, 1).

You must not pass above the diagonal line y = x .

You must end at the point (n, n).

How many different paths are there which satisfy these conditions?

The answer is the Catalan number Cn.

In fact, there is a simple bijection between Dyck words and theselattice paths: interpret a as “go east”, and b as “go north”.

The condition that a Dyck word has the same number of a’s andb’s guarantees that the lattice path ends at (n, n).

The condition that no initial segment of a Dyck word has more b’sthan a’s guarantees that the lattice path stays below the diagonal.

Page 34: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The 14 lattice paths in a 4× 4 grid from the Wikipedia article on“Catalan number”:

Page 35: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The 14 lattice paths in a 4× 4 grid from the Wikipedia article on“Catalan number”:

Page 36: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Permutations with excluded subsequences: We write Sn for thesymmetric group of all permutations of the set X = {1, 2, . . . , n}.

We think of an element p ∈ Sn as a sequence p1, p2, . . . , pnrepresenting a bijective function p : X → X .

By a subsequence of p of length k we mean a subset of k elementsof p which are in order but not necessarily consecutive:

pi1 , pi2 , , . . . , pik (i1 < i2 < · · · < ik).

How many permutations in Sn are there with no increasingsubsequence of length 3?

Trivially, for n = 1 there is 1, and for n = 2 there are 2.(There are no subsequences of length 3 to exclude.)

Page 37: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Permutations with excluded subsequences: We write Sn for thesymmetric group of all permutations of the set X = {1, 2, . . . , n}.

We think of an element p ∈ Sn as a sequence p1, p2, . . . , pnrepresenting a bijective function p : X → X .

By a subsequence of p of length k we mean a subset of k elementsof p which are in order but not necessarily consecutive:

pi1 , pi2 , , . . . , pik (i1 < i2 < · · · < ik).

How many permutations in Sn are there with no increasingsubsequence of length 3?

Trivially, for n = 1 there is 1, and for n = 2 there are 2.(There are no subsequences of length 3 to exclude.)

Page 38: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Permutations with excluded subsequences: We write Sn for thesymmetric group of all permutations of the set X = {1, 2, . . . , n}.

We think of an element p ∈ Sn as a sequence p1, p2, . . . , pnrepresenting a bijective function p : X → X .

By a subsequence of p of length k we mean a subset of k elementsof p which are in order but not necessarily consecutive:

pi1 , pi2 , , . . . , pik (i1 < i2 < · · · < ik).

How many permutations in Sn are there with no increasingsubsequence of length 3?

Trivially, for n = 1 there is 1, and for n = 2 there are 2.(There are no subsequences of length 3 to exclude.)

Page 39: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Permutations with excluded subsequences: We write Sn for thesymmetric group of all permutations of the set X = {1, 2, . . . , n}.

We think of an element p ∈ Sn as a sequence p1, p2, . . . , pnrepresenting a bijective function p : X → X .

By a subsequence of p of length k we mean a subset of k elementsof p which are in order but not necessarily consecutive:

pi1 , pi2 , , . . . , pik (i1 < i2 < · · · < ik).

How many permutations in Sn are there with no increasingsubsequence of length 3?

Trivially, for n = 1 there is 1, and for n = 2 there are 2.(There are no subsequences of length 3 to exclude.)

Page 40: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Permutations with excluded subsequences: We write Sn for thesymmetric group of all permutations of the set X = {1, 2, . . . , n}.

We think of an element p ∈ Sn as a sequence p1, p2, . . . , pnrepresenting a bijective function p : X → X .

By a subsequence of p of length k we mean a subset of k elementsof p which are in order but not necessarily consecutive:

pi1 , pi2 , , . . . , pik (i1 < i2 < · · · < ik).

How many permutations in Sn are there with no increasingsubsequence of length 3?

Trivially, for n = 1 there is 1, and for n = 2 there are 2.(There are no subsequences of length 3 to exclude.)

Page 41: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 3, we have to exclude the permutation 123, leaving 5:

132, 213, 231, 312, 321.

For n = 4, there are 24 permutations, and the increasingsubsequences could occur in positions 123, 124, 134 or 234.Here are all 24 permutations with the excluded ones underlined:

1234 1243 1324 1342 1423 1432

2134 2143 2314 2341 2413 2431

3124 3142 3214 3241 3412 3421

4123 4132 4213 4231 4312 4321

There are 10 excluded permutations, so 14 remain.

Page 42: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 3, we have to exclude the permutation 123, leaving 5:

132, 213, 231, 312, 321.

For n = 4, there are 24 permutations, and the increasingsubsequences could occur in positions 123, 124, 134 or 234.

Here are all 24 permutations with the excluded ones underlined:

1234 1243 1324 1342 1423 1432

2134 2143 2314 2341 2413 2431

3124 3142 3214 3241 3412 3421

4123 4132 4213 4231 4312 4321

There are 10 excluded permutations, so 14 remain.

Page 43: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 3, we have to exclude the permutation 123, leaving 5:

132, 213, 231, 312, 321.

For n = 4, there are 24 permutations, and the increasingsubsequences could occur in positions 123, 124, 134 or 234.Here are all 24 permutations with the excluded ones underlined:

1234 1243 1324 1342 1423 1432

2134 2143 2314 2341 2413 2431

3124 3142 3214 3241 3412 3421

4123 4132 4213 4231 4312 4321

There are 10 excluded permutations, so 14 remain.

Page 44: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 1, 2, 3, 4 we have 1, 2, 5, 14, . . . : the Catalan numbers!

Theorem

The number of permutations in Sn which have no increasingsubsequence of length 3 is the Catalan number Cn.

For permutations with no increasing subsequences of length 4:

1, 2, 6, 23, 103, 513, 2761, 15767, 94359, 586590, 3763290, . . .

For permutations with no increasing subsequences of length 5:

1, 2, 6, 24, 119, 694, 4582, 33324, 261808, 2190688, 19318688, . . .

For permutations with no increasing subsequences of length 6:

1, 2, 6, 24, 120, 719, 5003, 39429, 344837, 3291590, 33835114, . . .

The last three sequences are from the OEIS.

Page 45: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 1, 2, 3, 4 we have 1, 2, 5, 14, . . . : the Catalan numbers!

Theorem

The number of permutations in Sn which have no increasingsubsequence of length 3 is the Catalan number Cn.

For permutations with no increasing subsequences of length 4:

1, 2, 6, 23, 103, 513, 2761, 15767, 94359, 586590, 3763290, . . .

For permutations with no increasing subsequences of length 5:

1, 2, 6, 24, 119, 694, 4582, 33324, 261808, 2190688, 19318688, . . .

For permutations with no increasing subsequences of length 6:

1, 2, 6, 24, 120, 719, 5003, 39429, 344837, 3291590, 33835114, . . .

The last three sequences are from the OEIS.

Page 46: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 1, 2, 3, 4 we have 1, 2, 5, 14, . . . : the Catalan numbers!

Theorem

The number of permutations in Sn which have no increasingsubsequence of length 3 is the Catalan number Cn.

For permutations with no increasing subsequences of length 4:

1, 2, 6, 23, 103, 513, 2761, 15767, 94359, 586590, 3763290, . . .

For permutations with no increasing subsequences of length 5:

1, 2, 6, 24, 119, 694, 4582, 33324, 261808, 2190688, 19318688, . . .

For permutations with no increasing subsequences of length 6:

1, 2, 6, 24, 120, 719, 5003, 39429, 344837, 3291590, 33835114, . . .

The last three sequences are from the OEIS.

Page 47: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 1, 2, 3, 4 we have 1, 2, 5, 14, . . . : the Catalan numbers!

Theorem

The number of permutations in Sn which have no increasingsubsequence of length 3 is the Catalan number Cn.

For permutations with no increasing subsequences of length 4:

1, 2, 6, 23, 103, 513, 2761, 15767, 94359, 586590, 3763290, . . .

For permutations with no increasing subsequences of length 5:

1, 2, 6, 24, 119, 694, 4582, 33324, 261808, 2190688, 19318688, . . .

For permutations with no increasing subsequences of length 6:

1, 2, 6, 24, 120, 719, 5003, 39429, 344837, 3291590, 33835114, . . .

The last three sequences are from the OEIS.

Page 48: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

For n = 1, 2, 3, 4 we have 1, 2, 5, 14, . . . : the Catalan numbers!

Theorem

The number of permutations in Sn which have no increasingsubsequence of length 3 is the Catalan number Cn.

For permutations with no increasing subsequences of length 4:

1, 2, 6, 23, 103, 513, 2761, 15767, 94359, 586590, 3763290, . . .

For permutations with no increasing subsequences of length 5:

1, 2, 6, 24, 119, 694, 4582, 33324, 261808, 2190688, 19318688, . . .

For permutations with no increasing subsequences of length 6:

1, 2, 6, 24, 120, 719, 5003, 39429, 344837, 3291590, 33835114, . . .

The last three sequences are from the OEIS.

Page 49: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Polygon triangulation: Let n be a positive integer, and consider aregular polygon with n + 2 sides.So n = 1 gives a triangle, n = 2 gives a square, n = 3 gives apentagon, n = 4 gives hexagon, etc.

Join the vertices of the polygon by non-intersecting straight linesso that the polygon is divided into triangles, and count how manydistinct ways there are of doing this.n = 1: Polygon is a triangle, nothing to do, only one possibility.n = 2: Square can be divided by one diagonal or the other, givingtwo possibilities.n = 3: Clockwise from the top, label the vertices of the pentagon1 (top), 2 (right), 3, 4 (base), 5 (left). From any vertex, draw twolines from that vertex to the endpoints of the opposite edge. Everydecomposition has this form, giving five possibilities.

Page 50: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Polygon triangulation: Let n be a positive integer, and consider aregular polygon with n + 2 sides.So n = 1 gives a triangle, n = 2 gives a square, n = 3 gives apentagon, n = 4 gives hexagon, etc.Join the vertices of the polygon by non-intersecting straight linesso that the polygon is divided into triangles, and count how manydistinct ways there are of doing this.

n = 1: Polygon is a triangle, nothing to do, only one possibility.n = 2: Square can be divided by one diagonal or the other, givingtwo possibilities.n = 3: Clockwise from the top, label the vertices of the pentagon1 (top), 2 (right), 3, 4 (base), 5 (left). From any vertex, draw twolines from that vertex to the endpoints of the opposite edge. Everydecomposition has this form, giving five possibilities.

Page 51: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Polygon triangulation: Let n be a positive integer, and consider aregular polygon with n + 2 sides.So n = 1 gives a triangle, n = 2 gives a square, n = 3 gives apentagon, n = 4 gives hexagon, etc.Join the vertices of the polygon by non-intersecting straight linesso that the polygon is divided into triangles, and count how manydistinct ways there are of doing this.n = 1: Polygon is a triangle, nothing to do, only one possibility.

n = 2: Square can be divided by one diagonal or the other, givingtwo possibilities.n = 3: Clockwise from the top, label the vertices of the pentagon1 (top), 2 (right), 3, 4 (base), 5 (left). From any vertex, draw twolines from that vertex to the endpoints of the opposite edge. Everydecomposition has this form, giving five possibilities.

Page 52: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Polygon triangulation: Let n be a positive integer, and consider aregular polygon with n + 2 sides.So n = 1 gives a triangle, n = 2 gives a square, n = 3 gives apentagon, n = 4 gives hexagon, etc.Join the vertices of the polygon by non-intersecting straight linesso that the polygon is divided into triangles, and count how manydistinct ways there are of doing this.n = 1: Polygon is a triangle, nothing to do, only one possibility.n = 2: Square can be divided by one diagonal or the other, givingtwo possibilities.

n = 3: Clockwise from the top, label the vertices of the pentagon1 (top), 2 (right), 3, 4 (base), 5 (left). From any vertex, draw twolines from that vertex to the endpoints of the opposite edge. Everydecomposition has this form, giving five possibilities.

Page 53: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Polygon triangulation: Let n be a positive integer, and consider aregular polygon with n + 2 sides.So n = 1 gives a triangle, n = 2 gives a square, n = 3 gives apentagon, n = 4 gives hexagon, etc.Join the vertices of the polygon by non-intersecting straight linesso that the polygon is divided into triangles, and count how manydistinct ways there are of doing this.n = 1: Polygon is a triangle, nothing to do, only one possibility.n = 2: Square can be divided by one diagonal or the other, givingtwo possibilities.n = 3: Clockwise from the top, label the vertices of the pentagon1 (top), 2 (right), 3, 4 (base), 5 (left). From any vertex, draw twolines from that vertex to the endpoints of the opposite edge. Everydecomposition has this form, giving five possibilities.

Page 54: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

n = 4: The 14 triangulations of a hexagon from the Wikipediaarticle on “Catalan number”:

Theorem

The number of ways in which the regular polygon with n sides canbe triangulated is the Catalan number Cn−2.

Page 55: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

n = 4: The 14 triangulations of a hexagon from the Wikipediaarticle on “Catalan number”:

Theorem

The number of ways in which the regular polygon with n sides canbe triangulated is the Catalan number Cn−2.

Page 56: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

n = 4: The 14 triangulations of a hexagon from the Wikipediaarticle on “Catalan number”:

Theorem

The number of ways in which the regular polygon with n sides canbe triangulated is the Catalan number Cn−2.

Page 57: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Young tableaux: Let n be a positive integer, and consider apartition of n:

n = n1 + n2 + · · ·+ nk , n1 ≥ n2 ≥ · · · ≥ nk ≥ 1,

A Young diagram consists of k rows of (left-justified) emptysquares, with ni squares in row i .

A Young tableau consists of some placement of the numbers1, 2, . . . , n into the n boxes.A Young tableau is standard if the numbers increase from left toright along the rows, and from top to bottom along the columns.The irreducible representations of the symmetric group Sn arelabelled by the partitions of n, and the dimension of eachrepresentation is the number of standard Young tableaux for thecorresponding Young diagram.For n = 2m, partition n = m + m (Young diagram is 2×m array),the number of standard tableaux is the Catalan number Cn.

Page 58: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Young tableaux: Let n be a positive integer, and consider apartition of n:

n = n1 + n2 + · · ·+ nk , n1 ≥ n2 ≥ · · · ≥ nk ≥ 1,

A Young diagram consists of k rows of (left-justified) emptysquares, with ni squares in row i .A Young tableau consists of some placement of the numbers1, 2, . . . , n into the n boxes.

A Young tableau is standard if the numbers increase from left toright along the rows, and from top to bottom along the columns.The irreducible representations of the symmetric group Sn arelabelled by the partitions of n, and the dimension of eachrepresentation is the number of standard Young tableaux for thecorresponding Young diagram.For n = 2m, partition n = m + m (Young diagram is 2×m array),the number of standard tableaux is the Catalan number Cn.

Page 59: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Young tableaux: Let n be a positive integer, and consider apartition of n:

n = n1 + n2 + · · ·+ nk , n1 ≥ n2 ≥ · · · ≥ nk ≥ 1,

A Young diagram consists of k rows of (left-justified) emptysquares, with ni squares in row i .A Young tableau consists of some placement of the numbers1, 2, . . . , n into the n boxes.A Young tableau is standard if the numbers increase from left toright along the rows, and from top to bottom along the columns.

The irreducible representations of the symmetric group Sn arelabelled by the partitions of n, and the dimension of eachrepresentation is the number of standard Young tableaux for thecorresponding Young diagram.For n = 2m, partition n = m + m (Young diagram is 2×m array),the number of standard tableaux is the Catalan number Cn.

Page 60: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Young tableaux: Let n be a positive integer, and consider apartition of n:

n = n1 + n2 + · · ·+ nk , n1 ≥ n2 ≥ · · · ≥ nk ≥ 1,

A Young diagram consists of k rows of (left-justified) emptysquares, with ni squares in row i .A Young tableau consists of some placement of the numbers1, 2, . . . , n into the n boxes.A Young tableau is standard if the numbers increase from left toright along the rows, and from top to bottom along the columns.The irreducible representations of the symmetric group Sn arelabelled by the partitions of n, and the dimension of eachrepresentation is the number of standard Young tableaux for thecorresponding Young diagram.

For n = 2m, partition n = m + m (Young diagram is 2×m array),the number of standard tableaux is the Catalan number Cn.

Page 61: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Young tableaux: Let n be a positive integer, and consider apartition of n:

n = n1 + n2 + · · ·+ nk , n1 ≥ n2 ≥ · · · ≥ nk ≥ 1,

A Young diagram consists of k rows of (left-justified) emptysquares, with ni squares in row i .A Young tableau consists of some placement of the numbers1, 2, . . . , n into the n boxes.A Young tableau is standard if the numbers increase from left toright along the rows, and from top to bottom along the columns.The irreducible representations of the symmetric group Sn arelabelled by the partitions of n, and the dimension of eachrepresentation is the number of standard Young tableaux for thecorresponding Young diagram.For n = 2m, partition n = m + m (Young diagram is 2×m array),the number of standard tableaux is the Catalan number Cn.

Page 62: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

It is the number of ways 1, 2, ..., 2n can be arranged in a 2-by-nrectangle so that each row and each column is increasing:

n = 1 :

[12

]n = 2 :

[1 23 4

] [1 32 4

]n = 3 :

[1 2 34 5 6

] [1 2 43 5 6

] [1 2 53 4 6

] [1 3 42 5 6

] [1 3 52 4 6

]n = 4 :

[1 2 3 45 6 7 8

] [1 2 3 54 6 7 8

] [1 2 3 64 5 7 8

] [1 2 3 74 5 6 8

][

1 2 4 53 6 7 8

] [1 2 4 63 5 7 8

] [1 2 4 73 5 6 8

] [1 2 5 63 4 7 8

] [1 2 5 73 4 6 8

][

1 3 4 52 6 7 8

] [1 3 4 62 5 7 8

] [1 3 4 72 5 6 8

] [1 3 5 62 4 7 8

] [1 3 5 72 4 6 8

]Again we see the sequence 1, 2, 5, 14, . . .

Page 63: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

It is the number of ways 1, 2, ..., 2n can be arranged in a 2-by-nrectangle so that each row and each column is increasing:

n = 1 :

[12

]n = 2 :

[1 23 4

] [1 32 4

]n = 3 :

[1 2 34 5 6

] [1 2 43 5 6

] [1 2 53 4 6

] [1 3 42 5 6

] [1 3 52 4 6

]n = 4 :

[1 2 3 45 6 7 8

] [1 2 3 54 6 7 8

] [1 2 3 64 5 7 8

] [1 2 3 74 5 6 8

][

1 2 4 53 6 7 8

] [1 2 4 63 5 7 8

] [1 2 4 73 5 6 8

] [1 2 5 63 4 7 8

] [1 2 5 73 4 6 8

][

1 3 4 52 6 7 8

] [1 3 4 62 5 7 8

] [1 3 4 72 5 6 8

] [1 3 5 62 4 7 8

] [1 3 5 72 4 6 8

]

Again we see the sequence 1, 2, 5, 14, . . .

Page 64: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

It is the number of ways 1, 2, ..., 2n can be arranged in a 2-by-nrectangle so that each row and each column is increasing:

n = 1 :

[12

]n = 2 :

[1 23 4

] [1 32 4

]n = 3 :

[1 2 34 5 6

] [1 2 43 5 6

] [1 2 53 4 6

] [1 3 42 5 6

] [1 3 52 4 6

]n = 4 :

[1 2 3 45 6 7 8

] [1 2 3 54 6 7 8

] [1 2 3 64 5 7 8

] [1 2 3 74 5 6 8

][

1 2 4 53 6 7 8

] [1 2 4 63 5 7 8

] [1 2 4 73 5 6 8

] [1 2 5 63 4 7 8

] [1 2 5 73 4 6 8

][

1 3 4 52 6 7 8

] [1 3 4 62 5 7 8

] [1 3 4 72 5 6 8

] [1 3 5 62 4 7 8

] [1 3 5 72 4 6 8

]Again we see the sequence 1, 2, 5, 14, . . .

Page 65: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now, let’s return to finding a formula for the Catalan numbers.

Observation 1: Every product z of degree n has the form z = x · ywhere x , y have degrees i , j with i + j = n and 1 ≤ i , j ≤ n − 1.

Using trees, x and y are the left and right subtrees of the root.

Conclusion: We can give an algorithm to construct inductively allproducts of degree n once and only once:

Set P[1]← [X ] (the list containing the single element X )

For n from 2 to MAXDEG do

Set P[n]← [ ] (empty list)For j from 1 to n − 1 do:

For x in P[n − j ] do for y in P[j ] do:Adjoin [x , y ] to the list P[n].

The symbol X is a placeholder for all the factors; in each elementof P[n] we need to replace the n X ’s by the variables a1, . . . , an.

Page 66: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now, let’s return to finding a formula for the Catalan numbers.

Observation 1: Every product z of degree n has the form z = x · ywhere x , y have degrees i , j with i + j = n and 1 ≤ i , j ≤ n − 1.

Using trees, x and y are the left and right subtrees of the root.

Conclusion: We can give an algorithm to construct inductively allproducts of degree n once and only once:

Set P[1]← [X ] (the list containing the single element X )

For n from 2 to MAXDEG do

Set P[n]← [ ] (empty list)For j from 1 to n − 1 do:

For x in P[n − j ] do for y in P[j ] do:Adjoin [x , y ] to the list P[n].

The symbol X is a placeholder for all the factors; in each elementof P[n] we need to replace the n X ’s by the variables a1, . . . , an.

Page 67: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now, let’s return to finding a formula for the Catalan numbers.

Observation 1: Every product z of degree n has the form z = x · ywhere x , y have degrees i , j with i + j = n and 1 ≤ i , j ≤ n − 1.

Using trees, x and y are the left and right subtrees of the root.

Conclusion: We can give an algorithm to construct inductively allproducts of degree n once and only once:

Set P[1]← [X ] (the list containing the single element X )

For n from 2 to MAXDEG do

Set P[n]← [ ] (empty list)For j from 1 to n − 1 do:

For x in P[n − j ] do for y in P[j ] do:Adjoin [x , y ] to the list P[n].

The symbol X is a placeholder for all the factors; in each elementof P[n] we need to replace the n X ’s by the variables a1, . . . , an.

Page 68: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now, let’s return to finding a formula for the Catalan numbers.

Observation 1: Every product z of degree n has the form z = x · ywhere x , y have degrees i , j with i + j = n and 1 ≤ i , j ≤ n − 1.

Using trees, x and y are the left and right subtrees of the root.

Conclusion: We can give an algorithm to construct inductively allproducts of degree n once and only once:

Set P[1]← [X ] (the list containing the single element X )

For n from 2 to MAXDEG do

Set P[n]← [ ] (empty list)For j from 1 to n − 1 do:

For x in P[n − j ] do for y in P[j ] do:Adjoin [x , y ] to the list P[n].

The symbol X is a placeholder for all the factors; in each elementof P[n] we need to replace the n X ’s by the variables a1, . . . , an.

Page 69: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The number we are looking for is Pn = |P[n] |, the number of waysof placing balanced parantheses into a sequence of n factors.

Observation 2: The previous observation can be reformulated as:

Pn = Pn−1P1 + Pn−2P2 + · · ·+ P2Pn−2 + P1Pn−1,

Pn =∑i+j=n

PiPj , Pn =n−1∑j=1

Pn−jPj .

Observation 3: It will probably be useful to consider the so-calledordinary generating function

P(t) =∞∑n=1

Pntn,

which is a formal power series in the indeterminate t.

Page 70: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The number we are looking for is Pn = |P[n] |, the number of waysof placing balanced parantheses into a sequence of n factors.

Observation 2: The previous observation can be reformulated as:

Pn = Pn−1P1 + Pn−2P2 + · · ·+ P2Pn−2 + P1Pn−1,

Pn =∑i+j=n

PiPj , Pn =n−1∑j=1

Pn−jPj .

Observation 3: It will probably be useful to consider the so-calledordinary generating function

P(t) =∞∑n=1

Pntn,

which is a formal power series in the indeterminate t.

Page 71: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The number we are looking for is Pn = |P[n] |, the number of waysof placing balanced parantheses into a sequence of n factors.

Observation 2: The previous observation can be reformulated as:

Pn = Pn−1P1 + Pn−2P2 + · · ·+ P2Pn−2 + P1Pn−1,

Pn =∑i+j=n

PiPj , Pn =n−1∑j=1

Pn−jPj .

Observation 3: It will probably be useful to consider the so-calledordinary generating function

P(t) =∞∑n=1

Pntn,

which is a formal power series in the indeterminate t.

Page 72: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The terms appearing in Observation 2 also appear in P(t)2:

P(t)2 =

( ∞∑i=1

Pi ti

)( ∞∑j=1

Pj tj

)

=∞∑n=2

( ∑i+j=n

PiPj

)t i+j (outer sum starts at n = 2)

=∞∑n=2

Pntn (Observation 2)

= P(t)− t (since P1 = 1)

Conclusion: We have P(t)2 − P(t) + t = 0. This is a quadraticequation for the function P(t) whose coefficients are polynomialsin t, so we can use the quadratic formula to solve for P(t).

Page 73: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The terms appearing in Observation 2 also appear in P(t)2:

P(t)2 =

( ∞∑i=1

Pi ti

)( ∞∑j=1

Pj tj

)

=∞∑n=2

( ∑i+j=n

PiPj

)t i+j (outer sum starts at n = 2)

=∞∑n=2

Pntn (Observation 2)

= P(t)− t (since P1 = 1)

Conclusion: We have P(t)2 − P(t) + t = 0. This is a quadraticequation for the function P(t) whose coefficients are polynomialsin t, so we can use the quadratic formula to solve for P(t).

Page 74: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

P(t)2 − P(t) + t = 0 =⇒ a = 1, b = −1, c = t

P(t) =−b ±

√b2 − 4ac

2a=

1±√

1− 4t

2

There is no constant term in the formal power series for P(t),hence P(0) = 0, hence we must take the minus sign:

P(t) =1−√

1− 4t

2

Calculating the first few terms on a computer algebra system gives

t + t2 + 2t3 + 5t4 + 14t5 + 42t6 + 132t7 + 429t8 + 1430t9 + · · · ,

so it looks like we’re on the right track!

Page 75: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

P(t)2 − P(t) + t = 0 =⇒ a = 1, b = −1, c = t

P(t) =−b ±

√b2 − 4ac

2a=

1±√

1− 4t

2

There is no constant term in the formal power series for P(t),hence P(0) = 0, hence we must take the minus sign:

P(t) =1−√

1− 4t

2

Calculating the first few terms on a computer algebra system gives

t + t2 + 2t3 + 5t4 + 14t5 + 42t6 + 132t7 + 429t8 + 1430t9 + · · · ,

so it looks like we’re on the right track!

Page 76: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

P(t)2 − P(t) + t = 0 =⇒ a = 1, b = −1, c = t

P(t) =−b ±

√b2 − 4ac

2a=

1±√

1− 4t

2

There is no constant term in the formal power series for P(t),hence P(0) = 0, hence we must take the minus sign:

P(t) =1−√

1− 4t

2

Calculating the first few terms on a computer algebra system gives

t + t2 + 2t3 + 5t4 + 14t5 + 42t6 + 132t7 + 429t8 + 1430t9 + · · · ,

so it looks like we’re on the right track!

Page 77: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

P(t)2 − P(t) + t = 0 =⇒ a = 1, b = −1, c = t

P(t) =−b ±

√b2 − 4ac

2a=

1±√

1− 4t

2

There is no constant term in the formal power series for P(t),hence P(0) = 0, hence we must take the minus sign:

P(t) =1−√

1− 4t

2

Calculating the first few terms on a computer algebra system gives

t + t2 + 2t3 + 5t4 + 14t5 + 42t6 + 132t7 + 429t8 + 1430t9 + · · · ,

so it looks like we’re on the right track!

Page 78: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

P(t)2 − P(t) + t = 0 =⇒ a = 1, b = −1, c = t

P(t) =−b ±

√b2 − 4ac

2a=

1±√

1− 4t

2

There is no constant term in the formal power series for P(t),hence P(0) = 0, hence we must take the minus sign:

P(t) =1−√

1− 4t

2

Calculating the first few terms on a computer algebra system gives

t + t2 + 2t3 + 5t4 + 14t5 + 42t6 + 132t7 + 429t8 + 1430t9 + · · · ,

so it looks like we’re on the right track!

Page 79: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

P(t)2 − P(t) + t = 0 =⇒ a = 1, b = −1, c = t

P(t) =−b ±

√b2 − 4ac

2a=

1±√

1− 4t

2

There is no constant term in the formal power series for P(t),hence P(0) = 0, hence we must take the minus sign:

P(t) =1−√

1− 4t

2

Calculating the first few terms on a computer algebra system gives

t + t2 + 2t3 + 5t4 + 14t5 + 42t6 + 132t7 + 429t8 + 1430t9 + · · · ,

so it looks like we’re on the right track!

Page 80: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

P(t)2 − P(t) + t = 0 =⇒ a = 1, b = −1, c = t

P(t) =−b ±

√b2 − 4ac

2a=

1±√

1− 4t

2

There is no constant term in the formal power series for P(t),hence P(0) = 0, hence we must take the minus sign:

P(t) =1−√

1− 4t

2

Calculating the first few terms on a computer algebra system gives

t + t2 + 2t3 + 5t4 + 14t5 + 42t6 + 132t7 + 429t8 + 1430t9 + · · · ,

so it looks like we’re on the right track!

Page 81: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Binomial Theorem:

(x + y)n =n∑

k=0

(n

k

)xn−kyk ,

(n

k

)=

n!

k!(n − k)!

Generalized Binomial Coefficients:(n

k

)=

n(n − 1)(n − 2) · · · (n − (k − 1))

k!

There are k factors in the numerator.This is defined for any real (or complex) number n, and anynonnegative integer k .

In particular, we can use this to generalize the Binomial Theoremto fractional exponents, obtaining formal power series.

Page 82: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Binomial Theorem:

(x + y)n =n∑

k=0

(n

k

)xn−kyk ,

(n

k

)=

n!

k!(n − k)!

Generalized Binomial Coefficients:(n

k

)=

n(n − 1)(n − 2) · · · (n − (k − 1))

k!

There are k factors in the numerator.This is defined for any real (or complex) number n, and anynonnegative integer k .

In particular, we can use this to generalize the Binomial Theoremto fractional exponents, obtaining formal power series.

Page 83: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Binomial Theorem:

(x + y)n =n∑

k=0

(n

k

)xn−kyk ,

(n

k

)=

n!

k!(n − k)!

Generalized Binomial Coefficients:(n

k

)=

n(n − 1)(n − 2) · · · (n − (k − 1))

k!

There are k factors in the numerator.

This is defined for any real (or complex) number n, and anynonnegative integer k .

In particular, we can use this to generalize the Binomial Theoremto fractional exponents, obtaining formal power series.

Page 84: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Binomial Theorem:

(x + y)n =n∑

k=0

(n

k

)xn−kyk ,

(n

k

)=

n!

k!(n − k)!

Generalized Binomial Coefficients:(n

k

)=

n(n − 1)(n − 2) · · · (n − (k − 1))

k!

There are k factors in the numerator.This is defined for any real (or complex) number n, and anynonnegative integer k .

In particular, we can use this to generalize the Binomial Theoremto fractional exponents, obtaining formal power series.

Page 85: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Binomial Theorem:

(x + y)n =n∑

k=0

(n

k

)xn−kyk ,

(n

k

)=

n!

k!(n − k)!

Generalized Binomial Coefficients:(n

k

)=

n(n − 1)(n − 2) · · · (n − (k − 1))

k!

There are k factors in the numerator.This is defined for any real (or complex) number n, and anynonnegative integer k .

In particular, we can use this to generalize the Binomial Theoremto fractional exponents, obtaining formal power series.

Page 86: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Newton’s Binomial Theorem:

(x + y)α =∞∑k=0

k

)xα−kyk ,(

α

k

)=α(α− 1)(α− 2) · · · (α− (k − 1))

k!

We are interested in√

1− 4t so we set x = 1, y = −4t, α = 1/2:

√1− 4t =

∞∑k=0

(1/2

k

)(−4t)k =

∞∑k=0

(−1)k22k(

1/2

k

)tk .

What is(1/2

k

)for k ≥ 0? (No combinatorial interpretation.)

Page 87: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Newton’s Binomial Theorem:

(x + y)α =∞∑k=0

k

)xα−kyk ,(

α

k

)=α(α− 1)(α− 2) · · · (α− (k − 1))

k!

We are interested in√

1− 4t so we set x = 1, y = −4t, α = 1/2:

√1− 4t =

∞∑k=0

(1/2

k

)(−4t)k =

∞∑k=0

(−1)k22k(

1/2

k

)tk .

What is(1/2

k

)for k ≥ 0? (No combinatorial interpretation.)

Page 88: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Newton’s Binomial Theorem:

(x + y)α =∞∑k=0

k

)xα−kyk ,(

α

k

)=α(α− 1)(α− 2) · · · (α− (k − 1))

k!

We are interested in√

1− 4t so we set x = 1, y = −4t, α = 1/2:

√1− 4t =

∞∑k=0

(1/2

k

)(−4t)k =

∞∑k=0

(−1)k22k(

1/2

k

)tk .

What is(1/2

k

)for k ≥ 0? (No combinatorial interpretation.)

Page 89: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

(1/2

k

)=

1

k!· 1

2

(1

2− 1)(1

2− 2)· · ·(1

2− (k − 1)

)=

1

2· 1

k!· (−1)k−1 ·

(1− 1

2

)(2− 1

2

)· · ·(

(k − 1)− 1

2

)=

1

2· 1

k!· (−1)k−1 ·

(1

2

)(3

2

)· · ·(2k − 3

2

)= (−1)k−1 · 1

2k· 1

k!· (1 · 3 · · · (2k−3))

= (−1)k−1 · 1

2k· 1

k!· (1 · 3 · · · (2k−3)) · 2 · 4 · · · (2k−2)

2k−1(k − 1)!

= (−1)k−1 · 1

22k−1· (2k−2)!

k!(k − 1)!

Page 90: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lemma: (1/2

k

)=

(−1)k−1

22k−1· (2k−2)!

k!(k − 1)!

Recall:√

1− 4t =∞∑k=0

(−1)k22k(

1/2

k

)tk

The coefficient of tk is

(−1)k22k · (−1)k−1

22k−1· (2k−2)!

k!(k − 1)!= −2

(2k−2)!

k!(k − 1)!

Conclusion:

P(t) =1

2(1−

√1− 4t) =⇒ Pn =

(2n−2)!

n!(n − 1)!

Page 91: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lemma: (1/2

k

)=

(−1)k−1

22k−1· (2k−2)!

k!(k − 1)!

Recall:√

1− 4t =∞∑k=0

(−1)k22k(

1/2

k

)tk

The coefficient of tk is

(−1)k22k · (−1)k−1

22k−1· (2k−2)!

k!(k − 1)!= −2

(2k−2)!

k!(k − 1)!

Conclusion:

P(t) =1

2(1−

√1− 4t) =⇒ Pn =

(2n−2)!

n!(n − 1)!

Page 92: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lemma: (1/2

k

)=

(−1)k−1

22k−1· (2k−2)!

k!(k − 1)!

Recall:√

1− 4t =∞∑k=0

(−1)k22k(

1/2

k

)tk

The coefficient of tk is

(−1)k22k · (−1)k−1

22k−1· (2k−2)!

k!(k − 1)!= −2

(2k−2)!

k!(k − 1)!

Conclusion:

P(t) =1

2(1−

√1− 4t) =⇒ Pn =

(2n−2)!

n!(n − 1)!

Page 93: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Lemma: (1/2

k

)=

(−1)k−1

22k−1· (2k−2)!

k!(k − 1)!

Recall:√

1− 4t =∞∑k=0

(−1)k22k(

1/2

k

)tk

The coefficient of tk is

(−1)k22k · (−1)k−1

22k−1· (2k−2)!

k!(k − 1)!= −2

(2k−2)!

k!(k − 1)!

Conclusion:

P(t) =1

2(1−

√1− 4t) =⇒ Pn =

(2n−2)!

n!(n − 1)!

Page 94: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now we have a formula, so we can evaluate Pn for any n directly;for example, the number of ways to multiply n = 100 factors is:

227508830794229349661819540395688853956041682601541047340

The Catalan numbers are this sequence shifted one step left:

Cn = Pn+1 =(2n)!

(n + 1)!n!=

1

n + 1

(2n

n

).

The n in Cn counts the number of operations, not arguments.

The Catalan numbers are named after the Belgian-Frenchmathematician Eugene Charles Catalan (1814-1894).

Catalan also gave his name to the conjecture (1844) that the onlytwo consecutive integers which are powers of natural numbers are8 = 23 and 9 = 32. This was proved by Mihailescu (2002/2004).

Page 95: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now we have a formula, so we can evaluate Pn for any n directly;for example, the number of ways to multiply n = 100 factors is:

227508830794229349661819540395688853956041682601541047340

The Catalan numbers are this sequence shifted one step left:

Cn = Pn+1 =(2n)!

(n + 1)!n!=

1

n + 1

(2n

n

).

The n in Cn counts the number of operations, not arguments.

The Catalan numbers are named after the Belgian-Frenchmathematician Eugene Charles Catalan (1814-1894).

Catalan also gave his name to the conjecture (1844) that the onlytwo consecutive integers which are powers of natural numbers are8 = 23 and 9 = 32. This was proved by Mihailescu (2002/2004).

Page 96: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now we have a formula, so we can evaluate Pn for any n directly;for example, the number of ways to multiply n = 100 factors is:

227508830794229349661819540395688853956041682601541047340

The Catalan numbers are this sequence shifted one step left:

Cn = Pn+1 =(2n)!

(n + 1)!n!=

1

n + 1

(2n

n

).

The n in Cn counts the number of operations, not arguments.

The Catalan numbers are named after the Belgian-Frenchmathematician Eugene Charles Catalan (1814-1894).

Catalan also gave his name to the conjecture (1844) that the onlytwo consecutive integers which are powers of natural numbers are8 = 23 and 9 = 32. This was proved by Mihailescu (2002/2004).

Page 97: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now we have a formula, so we can evaluate Pn for any n directly;for example, the number of ways to multiply n = 100 factors is:

227508830794229349661819540395688853956041682601541047340

The Catalan numbers are this sequence shifted one step left:

Cn = Pn+1 =(2n)!

(n + 1)!n!=

1

n + 1

(2n

n

).

The n in Cn counts the number of operations, not arguments.

The Catalan numbers are named after the Belgian-Frenchmathematician Eugene Charles Catalan (1814-1894).

Catalan also gave his name to the conjecture (1844) that the onlytwo consecutive integers which are powers of natural numbers are8 = 23 and 9 = 32. This was proved by Mihailescu (2002/2004).

Page 98: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Now we have a formula, so we can evaluate Pn for any n directly;for example, the number of ways to multiply n = 100 factors is:

227508830794229349661819540395688853956041682601541047340

The Catalan numbers are this sequence shifted one step left:

Cn = Pn+1 =(2n)!

(n + 1)!n!=

1

n + 1

(2n

n

).

The n in Cn counts the number of operations, not arguments.

The Catalan numbers are named after the Belgian-Frenchmathematician Eugene Charles Catalan (1814-1894).

Catalan also gave his name to the conjecture (1844) that the onlytwo consecutive integers which are powers of natural numbers are8 = 23 and 9 = 32. This was proved by Mihailescu (2002/2004).

Page 99: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 2

m-ary Catalan numbers: The original Catalan numbers can begeneralized from a binary operation (taking two factors) to anm-ary operation (taking m factors).

In this case, the binomial formula generalizes very nicely:

1

(m − 1)n + 1

(mn

n

)Setting m = 2 gives our formula for the binary Catalan numbers.

The proof that we gave for m = 2 does not generalize: it wouldrequire explicit solution of a polynomial of degree m.

There is a (relatively) elementary proof that works for all m usingconvolution of formal power series in Concrete Mathematics byGraham, Knuth, and Patashnik (Section 7.5); I will call this GKP.

Page 100: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 2

m-ary Catalan numbers: The original Catalan numbers can begeneralized from a binary operation (taking two factors) to anm-ary operation (taking m factors).

In this case, the binomial formula generalizes very nicely:

1

(m − 1)n + 1

(mn

n

)Setting m = 2 gives our formula for the binary Catalan numbers.

The proof that we gave for m = 2 does not generalize: it wouldrequire explicit solution of a polynomial of degree m.

There is a (relatively) elementary proof that works for all m usingconvolution of formal power series in Concrete Mathematics byGraham, Knuth, and Patashnik (Section 7.5); I will call this GKP.

Page 101: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 2

m-ary Catalan numbers: The original Catalan numbers can begeneralized from a binary operation (taking two factors) to anm-ary operation (taking m factors).

In this case, the binomial formula generalizes very nicely:

1

(m − 1)n + 1

(mn

n

)Setting m = 2 gives our formula for the binary Catalan numbers.

The proof that we gave for m = 2 does not generalize: it wouldrequire explicit solution of a polynomial of degree m.

There is a (relatively) elementary proof that works for all m usingconvolution of formal power series in Concrete Mathematics byGraham, Knuth, and Patashnik (Section 7.5); I will call this GKP.

Page 102: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 2

m-ary Catalan numbers: The original Catalan numbers can begeneralized from a binary operation (taking two factors) to anm-ary operation (taking m factors).

In this case, the binomial formula generalizes very nicely:

1

(m − 1)n + 1

(mn

n

)Setting m = 2 gives our formula for the binary Catalan numbers.

The proof that we gave for m = 2 does not generalize: it wouldrequire explicit solution of a polynomial of degree m.

There is a (relatively) elementary proof that works for all m usingconvolution of formal power series in Concrete Mathematics byGraham, Knuth, and Patashnik (Section 7.5); I will call this GKP.

Page 103: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 2

m-ary Catalan numbers: The original Catalan numbers can begeneralized from a binary operation (taking two factors) to anm-ary operation (taking m factors).

In this case, the binomial formula generalizes very nicely:

1

(m − 1)n + 1

(mn

n

)Setting m = 2 gives our formula for the binary Catalan numbers.

The proof that we gave for m = 2 does not generalize: it wouldrequire explicit solution of a polynomial of degree m.

There is a (relatively) elementary proof that works for all m usingconvolution of formal power series in Concrete Mathematics byGraham, Knuth, and Patashnik (Section 7.5); I will call this GKP.

Page 104: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Just as in the binary case, we can regard the m-ary case asenumerating rooted planar complete trees, but now the trees arem-ary instead of binary: every internal node has exactly m children.

We must remember that n is the number of internal nodes (m-arymultiplications from the algebraic point of view) not the number ofleaf nodes (arguments or factors from the algebraic point of view).

Here is a table for 2 ≤ m ≤ 6 and 1 ≤ n ≤ 9:

m\n 1 2 3 4 5 6 7 8 9

2 1 2 5 14 42 132 429 1430 48623 1 3 12 55 273 1428 7752 43263 2466754 1 4 22 140 969 7084 53820 420732 33622605 1 5 35 285 2530 23751 231880 2330445 239503556 1 6 51 506 5481 62832 749398 9203634 115607310

In particular, there should be 12 ternary trees with 3 internal nodes:

Page 105: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Just as in the binary case, we can regard the m-ary case asenumerating rooted planar complete trees, but now the trees arem-ary instead of binary: every internal node has exactly m children.

We must remember that n is the number of internal nodes (m-arymultiplications from the algebraic point of view) not the number ofleaf nodes (arguments or factors from the algebraic point of view).

Here is a table for 2 ≤ m ≤ 6 and 1 ≤ n ≤ 9:

m\n 1 2 3 4 5 6 7 8 9

2 1 2 5 14 42 132 429 1430 48623 1 3 12 55 273 1428 7752 43263 2466754 1 4 22 140 969 7084 53820 420732 33622605 1 5 35 285 2530 23751 231880 2330445 239503556 1 6 51 506 5481 62832 749398 9203634 115607310

In particular, there should be 12 ternary trees with 3 internal nodes:

Page 106: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Just as in the binary case, we can regard the m-ary case asenumerating rooted planar complete trees, but now the trees arem-ary instead of binary: every internal node has exactly m children.

We must remember that n is the number of internal nodes (m-arymultiplications from the algebraic point of view) not the number ofleaf nodes (arguments or factors from the algebraic point of view).

Here is a table for 2 ≤ m ≤ 6 and 1 ≤ n ≤ 9:

m\n 1 2 3 4 5 6 7 8 9

2 1 2 5 14 42 132 429 1430 48623 1 3 12 55 273 1428 7752 43263 2466754 1 4 22 140 969 7084 53820 420732 33622605 1 5 35 285 2530 23751 231880 2330445 239503556 1 6 51 506 5481 62832 749398 9203634 115607310

In particular, there should be 12 ternary trees with 3 internal nodes:

Page 107: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Just as in the binary case, we can regard the m-ary case asenumerating rooted planar complete trees, but now the trees arem-ary instead of binary: every internal node has exactly m children.

We must remember that n is the number of internal nodes (m-arymultiplications from the algebraic point of view) not the number ofleaf nodes (arguments or factors from the algebraic point of view).

Here is a table for 2 ≤ m ≤ 6 and 1 ≤ n ≤ 9:

m\n 1 2 3 4 5 6 7 8 9

2 1 2 5 14 42 132 429 1430 48623 1 3 12 55 273 1428 7752 43263 2466754 1 4 22 140 969 7084 53820 420732 33622605 1 5 35 285 2530 23751 231880 2330445 239503556 1 6 51 506 5481 62832 749398 9203634 115607310

In particular, there should be 12 ternary trees with 3 internal nodes:

Page 108: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Just as in the binary case, we can regard the m-ary case asenumerating rooted planar complete trees, but now the trees arem-ary instead of binary: every internal node has exactly m children.

We must remember that n is the number of internal nodes (m-arymultiplications from the algebraic point of view) not the number ofleaf nodes (arguments or factors from the algebraic point of view).

Here is a table for 2 ≤ m ≤ 6 and 1 ≤ n ≤ 9:

m\n 1 2 3 4 5 6 7 8 9

2 1 2 5 14 42 132 429 1430 48623 1 3 12 55 273 1428 7752 43263 2466754 1 4 22 140 969 7084 53820 420732 33622605 1 5 35 285 2530 23751 231880 2330445 239503556 1 6 51 506 5481 62832 749398 9203634 115607310

In particular, there should be 12 ternary trees with 3 internal nodes:

Page 109: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

a b c

d e

f g

a ∗

b c d

e

f g

a b ∗

c d e

f g

Page 110: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

a ∗

b c d

e f

g

a ∗

b ∗

c d e

f

g

a ∗

b c ∗

d e f

g

Page 111: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

a b ∗

c d e

f g

a b ∗

c ∗

d e f

g

a b ∗

c d ∗

e f g

Page 112: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

a ∗

b c d

e f g

a b c

d ∗

e f g

a b c

d e f

g

Page 113: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In the rest of this talk, I follow GKP very closely. Their proof of them-ary Catalan formula starts with the notion of Raney sequence.

Lemma (Raney’s Lemma)

Let (a0, a1, . . . , a2n) be a sequence of integers with∑2n

i=0 ai = 1.Then exactly one of the 2n + 1 cyclic shifts of the sequence hasthe property that all of its partial sums are positive:

(a0, a1, . . . , a2n), (a1, a2, . . . , a0), . . . , (a2n, a0, . . . , a2n−1).

Definition

A Raney sequence is a sequence of integers such that

2n∑i=0

ai = 1 andk∑

i=0

ai ≥ 1 (k = 0, . . . , 2n).

Page 114: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In the rest of this talk, I follow GKP very closely. Their proof of them-ary Catalan formula starts with the notion of Raney sequence.

Lemma (Raney’s Lemma)

Let (a0, a1, . . . , a2n) be a sequence of integers with∑2n

i=0 ai = 1.Then exactly one of the 2n + 1 cyclic shifts of the sequence hasthe property that all of its partial sums are positive:

(a0, a1, . . . , a2n), (a1, a2, . . . , a0), . . . , (a2n, a0, . . . , a2n−1).

Definition

A Raney sequence is a sequence of integers such that

2n∑i=0

ai = 1 andk∑

i=0

ai ≥ 1 (k = 0, . . . , 2n).

Page 115: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In the rest of this talk, I follow GKP very closely. Their proof of them-ary Catalan formula starts with the notion of Raney sequence.

Lemma (Raney’s Lemma)

Let (a0, a1, . . . , a2n) be a sequence of integers with∑2n

i=0 ai = 1.Then exactly one of the 2n + 1 cyclic shifts of the sequence hasthe property that all of its partial sums are positive:

(a0, a1, . . . , a2n), (a1, a2, . . . , a0), . . . , (a2n, a0, . . . , a2n−1).

Definition

A Raney sequence is a sequence of integers such that

2n∑i=0

ai = 1 andk∑

i=0

ai ≥ 1 (k = 0, . . . , 2n).

Page 116: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In particular, consider the Raney sequences (a0, a1, . . . , a2n) whichcontain only +1 and −1.

To get sum +1 we need n + 1 copies of +1 and n copies of −1,which gives a total of

(2n+1n

)sequences.

Raney’s Lemma tells us that exactly 12n+1 of these have all their

partial sums positive.

Altogether we obtain this number of +1/−1 Raney sequences:

1

2n + 1

(2n + 1

n

)=

1

2n + 1· (2n + 1)!

(n + 1)!n!=

(2n)!

(n + 1)!n!

=1

n + 1

(2n

n

)The Catalan number, Cn!

Page 117: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In particular, consider the Raney sequences (a0, a1, . . . , a2n) whichcontain only +1 and −1.

To get sum +1 we need n + 1 copies of +1 and n copies of −1,which gives a total of

(2n+1n

)sequences.

Raney’s Lemma tells us that exactly 12n+1 of these have all their

partial sums positive.

Altogether we obtain this number of +1/−1 Raney sequences:

1

2n + 1

(2n + 1

n

)=

1

2n + 1· (2n + 1)!

(n + 1)!n!=

(2n)!

(n + 1)!n!

=1

n + 1

(2n

n

)The Catalan number, Cn!

Page 118: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In particular, consider the Raney sequences (a0, a1, . . . , a2n) whichcontain only +1 and −1.

To get sum +1 we need n + 1 copies of +1 and n copies of −1,which gives a total of

(2n+1n

)sequences.

Raney’s Lemma tells us that exactly 12n+1 of these have all their

partial sums positive.

Altogether we obtain this number of +1/−1 Raney sequences:

1

2n + 1

(2n + 1

n

)=

1

2n + 1· (2n + 1)!

(n + 1)!n!=

(2n)!

(n + 1)!n!

=1

n + 1

(2n

n

)The Catalan number, Cn!

Page 119: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In particular, consider the Raney sequences (a0, a1, . . . , a2n) whichcontain only +1 and −1.

To get sum +1 we need n + 1 copies of +1 and n copies of −1,which gives a total of

(2n+1n

)sequences.

Raney’s Lemma tells us that exactly 12n+1 of these have all their

partial sums positive.

Altogether we obtain this number of +1/−1 Raney sequences:

1

2n + 1

(2n + 1

n

)=

1

2n + 1· (2n + 1)!

(n + 1)!n!=

(2n)!

(n + 1)!n!

=1

n + 1

(2n

n

)

The Catalan number, Cn!

Page 120: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

In particular, consider the Raney sequences (a0, a1, . . . , a2n) whichcontain only +1 and −1.

To get sum +1 we need n + 1 copies of +1 and n copies of −1,which gives a total of

(2n+1n

)sequences.

Raney’s Lemma tells us that exactly 12n+1 of these have all their

partial sums positive.

Altogether we obtain this number of +1/−1 Raney sequences:

1

2n + 1

(2n + 1

n

)=

1

2n + 1· (2n + 1)!

(n + 1)!n!=

(2n)!

(n + 1)!n!

=1

n + 1

(2n

n

)The Catalan number, Cn!

Page 121: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

We give a bijection from placements of parentheses to +1/−1Raney sequences.

We illustrate with an example from GKP:

a((bc)(de))

Explicitly write in the multiplication symbols, and add anoutermost pair of parentheses so that there are as many pairs ofparentheses as multiplication symbols:

(a · ((b · c) · (d · e)))

Erase the arguments and the left parentheses:

··)··)))

Replace each multiplication by +1 and each right parenthesis by−1, and add an extra +1 at the beginning:

+1,+1,+1,−1,+1,+1,−1,−1,−1

Page 122: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

We give a bijection from placements of parentheses to +1/−1Raney sequences. We illustrate with an example from GKP:

a((bc)(de))

Explicitly write in the multiplication symbols, and add anoutermost pair of parentheses so that there are as many pairs ofparentheses as multiplication symbols:

(a · ((b · c) · (d · e)))

Erase the arguments and the left parentheses:

··)··)))

Replace each multiplication by +1 and each right parenthesis by−1, and add an extra +1 at the beginning:

+1,+1,+1,−1,+1,+1,−1,−1,−1

Page 123: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

We give a bijection from placements of parentheses to +1/−1Raney sequences. We illustrate with an example from GKP:

a((bc)(de))

Explicitly write in the multiplication symbols, and add anoutermost pair of parentheses so that there are as many pairs ofparentheses as multiplication symbols:

(a · ((b · c) · (d · e)))

Erase the arguments and the left parentheses:

··)··)))

Replace each multiplication by +1 and each right parenthesis by−1, and add an extra +1 at the beginning:

+1,+1,+1,−1,+1,+1,−1,−1,−1

Page 124: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

We give a bijection from placements of parentheses to +1/−1Raney sequences. We illustrate with an example from GKP:

a((bc)(de))

Explicitly write in the multiplication symbols, and add anoutermost pair of parentheses so that there are as many pairs ofparentheses as multiplication symbols:

(a · ((b · c) · (d · e)))

Erase the arguments and the left parentheses:

··)··)))

Replace each multiplication by +1 and each right parenthesis by−1, and add an extra +1 at the beginning:

+1,+1,+1,−1,+1,+1,−1,−1,−1

Page 125: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

We give a bijection from placements of parentheses to +1/−1Raney sequences. We illustrate with an example from GKP:

a((bc)(de))

Explicitly write in the multiplication symbols, and add anoutermost pair of parentheses so that there are as many pairs ofparentheses as multiplication symbols:

(a · ((b · c) · (d · e)))

Erase the arguments and the left parentheses:

··)··)))

Replace each multiplication by +1 and each right parenthesis by−1, and add an extra +1 at the beginning:

+1,+1,+1,−1,+1,+1,−1,−1,−1

Page 126: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

What is the m-ary generalization?

Definition

For an integer m ≥ 2, an m-Raney sequence is a sequence

( a0, a1, . . . , amn )

of the numbers 1 and 1−m (so −1 corresponds to m = 2) whosetotal sum is 1 and whose partial sums are all positive.

If 1−m occurs k times (so 1 occurs mn + 1− k times) then

k(1−m) + (mn + 1− k) = 1 =⇒ −km + mn = 0 =⇒ k = n.

So each sequence has n occurrences of 1−m and mn + 1− noccurrences of 1, and each sequence has length mn + 1.

Page 127: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

What is the m-ary generalization?

Definition

For an integer m ≥ 2, an m-Raney sequence is a sequence

( a0, a1, . . . , amn )

of the numbers 1 and 1−m (so −1 corresponds to m = 2) whosetotal sum is 1 and whose partial sums are all positive.

If 1−m occurs k times (so 1 occurs mn + 1− k times) then

k(1−m) + (mn + 1− k) = 1 =⇒ −km + mn = 0 =⇒ k = n.

So each sequence has n occurrences of 1−m and mn + 1− noccurrences of 1, and each sequence has length mn + 1.

Page 128: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

What is the m-ary generalization?

Definition

For an integer m ≥ 2, an m-Raney sequence is a sequence

( a0, a1, . . . , amn )

of the numbers 1 and 1−m (so −1 corresponds to m = 2) whosetotal sum is 1 and whose partial sums are all positive.

If 1−m occurs k times (so 1 occurs mn + 1− k times) then

k(1−m) + (mn + 1− k) = 1 =⇒ −km + mn = 0 =⇒ k = n.

So each sequence has n occurrences of 1−m and mn + 1− noccurrences of 1, and each sequence has length mn + 1.

Page 129: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

What is the m-ary generalization?

Definition

For an integer m ≥ 2, an m-Raney sequence is a sequence

( a0, a1, . . . , amn )

of the numbers 1 and 1−m (so −1 corresponds to m = 2) whosetotal sum is 1 and whose partial sums are all positive.

If 1−m occurs k times (so 1 occurs mn + 1− k times) then

k(1−m) + (mn + 1− k) = 1 =⇒ −km + mn = 0 =⇒ k = n.

So each sequence has n occurrences of 1−m and mn + 1− noccurrences of 1, and each sequence has length mn + 1.

Page 130: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The total number of such sequences (without the positivitycondition on partial sums) is this binomial coefficient:(

mn + 1

n

)

Using Raney’s Lemma to include the positivity condition gives:

1

mn + 1

(mn + 1

n

)=

1

mn + 1· (mn + 1)!

((m − 1)n + 1)!n!

=(mn)!

((m − 1)n + 1)!n!

=1

((m − 1)n + 1)

(mn

n

).

This is the formula we’ve seen before for m-ary Catalan numbers.

Page 131: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The total number of such sequences (without the positivitycondition on partial sums) is this binomial coefficient:(

mn + 1

n

)Using Raney’s Lemma to include the positivity condition gives:

1

mn + 1

(mn + 1

n

)=

1

mn + 1· (mn + 1)!

((m − 1)n + 1)!n!

=(mn)!

((m − 1)n + 1)!n!

=1

((m − 1)n + 1)

(mn

n

).

This is the formula we’ve seen before for m-ary Catalan numbers.

Page 132: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The total number of such sequences (without the positivitycondition on partial sums) is this binomial coefficient:(

mn + 1

n

)Using Raney’s Lemma to include the positivity condition gives:

1

mn + 1

(mn + 1

n

)=

1

mn + 1· (mn + 1)!

((m − 1)n + 1)!n!

=(mn)!

((m − 1)n + 1)!n!

=1

((m − 1)n + 1)

(mn

n

).

This is the formula we’ve seen before for m-ary Catalan numbers.

Page 133: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Why does this formula enumerate placements of parentheses for anm-ary operation, or complete rooted planar m-ary trees?

We need to construct a bijection between these placements ofparentheses and the m-Raney sequences of the last definition.

The trivial sequence 1 of length 1 is an m-Raney sequence.

If we form a sequence of m sequences which are m-Raneysequences and follow it with the number 1−m, then we getanother m-Raney sequence: the partial sums (over the sequences)increase from 1 to m and then drop to 1.

Conversely, it can be shown with a little more work that allm-Raney sequences arise this way.

Page 134: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Why does this formula enumerate placements of parentheses for anm-ary operation, or complete rooted planar m-ary trees?

We need to construct a bijection between these placements ofparentheses and the m-Raney sequences of the last definition.

The trivial sequence 1 of length 1 is an m-Raney sequence.

If we form a sequence of m sequences which are m-Raneysequences and follow it with the number 1−m, then we getanother m-Raney sequence: the partial sums (over the sequences)increase from 1 to m and then drop to 1.

Conversely, it can be shown with a little more work that allm-Raney sequences arise this way.

Page 135: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Why does this formula enumerate placements of parentheses for anm-ary operation, or complete rooted planar m-ary trees?

We need to construct a bijection between these placements ofparentheses and the m-Raney sequences of the last definition.

The trivial sequence 1 of length 1 is an m-Raney sequence.

If we form a sequence of m sequences which are m-Raneysequences and follow it with the number 1−m, then we getanother m-Raney sequence: the partial sums (over the sequences)increase from 1 to m and then drop to 1.

Conversely, it can be shown with a little more work that allm-Raney sequences arise this way.

Page 136: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Why does this formula enumerate placements of parentheses for anm-ary operation, or complete rooted planar m-ary trees?

We need to construct a bijection between these placements ofparentheses and the m-Raney sequences of the last definition.

The trivial sequence 1 of length 1 is an m-Raney sequence.

If we form a sequence of m sequences which are m-Raneysequences and follow it with the number 1−m, then we getanother m-Raney sequence: the partial sums (over the sequences)increase from 1 to m and then drop to 1.

Conversely, it can be shown with a little more work that allm-Raney sequences arise this way.

Page 137: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Why does this formula enumerate placements of parentheses for anm-ary operation, or complete rooted planar m-ary trees?

We need to construct a bijection between these placements ofparentheses and the m-Raney sequences of the last definition.

The trivial sequence 1 of length 1 is an m-Raney sequence.

If we form a sequence of m sequences which are m-Raneysequences and follow it with the number 1−m, then we getanother m-Raney sequence: the partial sums (over the sequences)increase from 1 to m and then drop to 1.

Conversely, it can be shown with a little more work that allm-Raney sequences arise this way.

Page 138: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The recursive construction of m-Raney sequences we have justdescribed corresponds to the equation

C(m)n =

∑n1+n2+···+nm+1=n

C(m)n1 C

(m)n2 · · ·C

(m)nm ,

which is the same recursion that counts placements of parenthesesfor an m-ary operation.

Note that the +1 under the summation sign comes from the factthat we are counting operations not arguments: if we combine mfactors involving respectively n1, . . . , nm operations then when wemultiply those factors we introduce one more operation.

Page 139: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The recursive construction of m-Raney sequences we have justdescribed corresponds to the equation

C(m)n =

∑n1+n2+···+nm+1=n

C(m)n1 C

(m)n2 · · ·C

(m)nm ,

which is the same recursion that counts placements of parenthesesfor an m-ary operation.

Note that the +1 under the summation sign comes from the factthat we are counting operations not arguments: if we combine mfactors involving respectively n1, . . . , nm operations then when wemultiply those factors we introduce one more operation.

Page 140: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The recursive construction of m-Raney sequences we have justdescribed corresponds to the equation

C(m)n =

∑n1+n2+···+nm+1=n

C(m)n1 C

(m)n2 · · ·C

(m)nm ,

which is the same recursion that counts placements of parenthesesfor an m-ary operation.

Note that the +1 under the summation sign comes from the factthat we are counting operations not arguments:

if we combine mfactors involving respectively n1, . . . , nm operations then when wemultiply those factors we introduce one more operation.

Page 141: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The recursive construction of m-Raney sequences we have justdescribed corresponds to the equation

C(m)n =

∑n1+n2+···+nm+1=n

C(m)n1 C

(m)n2 · · ·C

(m)nm ,

which is the same recursion that counts placements of parenthesesfor an m-ary operation.

Note that the +1 under the summation sign comes from the factthat we are counting operations not arguments: if we combine mfactors involving respectively n1, . . . , nm operations then when wemultiply those factors we introduce one more operation.

Page 142: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 143: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 144: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 145: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 146: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 147: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 148: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 149: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

PART 3

What happens if we assume that the binary operation iscommutative?

In this case, it’s convenient to think of a single generator x subjectto a commutative but nonassociative operation.

We want to count the distinct “powers” of x in each degree:

x , x2, x2x = xx2 (commutativity), x2x2,

(x2x)x = (xx2)x = x(x2x) = x(xx2) (commutativity).

Degrees n = 1, 2, 3, 4 have 1, 1, 1, 2 distinct n-th powers of x .

In each equivalence class under commutativity, we need to chooseone representative normal form; for example, x2x and (x2x)x .

We also need to choose a total order on the normal forms thatrespects the degrees.

Page 150: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

We can solve both problems with an algorithm that generates thenormal forms by degree and by total order within each degree.

Set Q[1]← [ x ] (List containing the single element x)

For n from 2 to MAXDEG do

Set Q[n]← [ ] (Empty list)For j from 1 to b(n − 1)/2c do: (Stop before we reach n/2)

(In this loop, left factor has higher degree than right factor)For x in Q[n − j ] do for y in Q[j ] do:Adjoin [x , y ] to the list Q[n].

If n is even then (Special case: two factors of same degree)

For i to length(Q[n/2]) do for j from i to length(Q[n/2]) do(In this loop, the left factor precedes the right factor in thetotal order on degree i)Adjoin [Q[n/2][i ],Q[n/2][j ]] to the list Q[n].

Page 151: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

We can solve both problems with an algorithm that generates thenormal forms by degree and by total order within each degree.

Set Q[1]← [ x ] (List containing the single element x)

For n from 2 to MAXDEG do

Set Q[n]← [ ] (Empty list)For j from 1 to b(n − 1)/2c do: (Stop before we reach n/2)

(In this loop, left factor has higher degree than right factor)For x in Q[n − j ] do for y in Q[j ] do:Adjoin [x , y ] to the list Q[n].

If n is even then (Special case: two factors of same degree)

For i to length(Q[n/2]) do for j from i to length(Q[n/2]) do(In this loop, the left factor precedes the right factor in thetotal order on degree i)Adjoin [Q[n/2][i ],Q[n/2][j ]] to the list Q[n].

Page 152: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The resulting sequence is the Wedderburn-Etherington numbers:

1, 1, 1, 2, 3, 6, 11, 23, 46, 98, 207, 451, 983, 2179, 4850, . . .

To explain the number 3 in degree 5, we have:

4 + 1: (((x2)x)x)x , (x2x2)x ; 3 + 2: (x2x)x2.

To explain the number 6 in degree 6, we have:

5 + 1: ((((x2)x)x)x)x , ((x2x2)x)x , ((x2x)x2)x ;

4 + 2: (((x2)x)x)x2, (x2x2)x2; 3 + 3: (x2x)(x2x).

To explain the number 11 in degree 7, we have:

[6 + 1] 6 ·1 = 6, [5 + 2] 3 ·1 = 3, [4 + 3] 2 ·1 = 2 : total 11.

To explain the number 23 in degree 8, we have:

[7 + 1] 11 · 1, [6 + 2] 6 · 1, [5 + 3] 3 · 1, [4 + 4]

(2+1

2

): total 23.

Page 153: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The resulting sequence is the Wedderburn-Etherington numbers:

1, 1, 1, 2, 3, 6, 11, 23, 46, 98, 207, 451, 983, 2179, 4850, . . .

To explain the number 3 in degree 5, we have:

4 + 1: (((x2)x)x)x , (x2x2)x ; 3 + 2: (x2x)x2.

To explain the number 6 in degree 6, we have:

5 + 1: ((((x2)x)x)x)x , ((x2x2)x)x , ((x2x)x2)x ;

4 + 2: (((x2)x)x)x2, (x2x2)x2; 3 + 3: (x2x)(x2x).

To explain the number 11 in degree 7, we have:

[6 + 1] 6 ·1 = 6, [5 + 2] 3 ·1 = 3, [4 + 3] 2 ·1 = 2 : total 11.

To explain the number 23 in degree 8, we have:

[7 + 1] 11 · 1, [6 + 2] 6 · 1, [5 + 3] 3 · 1, [4 + 4]

(2+1

2

): total 23.

Page 154: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The resulting sequence is the Wedderburn-Etherington numbers:

1, 1, 1, 2, 3, 6, 11, 23, 46, 98, 207, 451, 983, 2179, 4850, . . .

To explain the number 3 in degree 5, we have:

4 + 1: (((x2)x)x)x , (x2x2)x ; 3 + 2: (x2x)x2.

To explain the number 6 in degree 6, we have:

5 + 1: ((((x2)x)x)x)x , ((x2x2)x)x , ((x2x)x2)x ;

4 + 2: (((x2)x)x)x2, (x2x2)x2; 3 + 3: (x2x)(x2x).

To explain the number 11 in degree 7, we have:

[6 + 1] 6 ·1 = 6, [5 + 2] 3 ·1 = 3, [4 + 3] 2 ·1 = 2 : total 11.

To explain the number 23 in degree 8, we have:

[7 + 1] 11 · 1, [6 + 2] 6 · 1, [5 + 3] 3 · 1, [4 + 4]

(2+1

2

): total 23.

Page 155: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The resulting sequence is the Wedderburn-Etherington numbers:

1, 1, 1, 2, 3, 6, 11, 23, 46, 98, 207, 451, 983, 2179, 4850, . . .

To explain the number 3 in degree 5, we have:

4 + 1: (((x2)x)x)x , (x2x2)x ; 3 + 2: (x2x)x2.

To explain the number 6 in degree 6, we have:

5 + 1: ((((x2)x)x)x)x , ((x2x2)x)x , ((x2x)x2)x ;

4 + 2: (((x2)x)x)x2, (x2x2)x2; 3 + 3: (x2x)(x2x).

To explain the number 11 in degree 7, we have:

[6 + 1] 6 ·1 = 6, [5 + 2] 3 ·1 = 3, [4 + 3] 2 ·1 = 2 : total 11.

To explain the number 23 in degree 8, we have:

[7 + 1] 11 · 1, [6 + 2] 6 · 1, [5 + 3] 3 · 1, [4 + 4]

(2+1

2

): total 23.

Page 156: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The resulting sequence is the Wedderburn-Etherington numbers:

1, 1, 1, 2, 3, 6, 11, 23, 46, 98, 207, 451, 983, 2179, 4850, . . .

To explain the number 3 in degree 5, we have:

4 + 1: (((x2)x)x)x , (x2x2)x ; 3 + 2: (x2x)x2.

To explain the number 6 in degree 6, we have:

5 + 1: ((((x2)x)x)x)x , ((x2x2)x)x , ((x2x)x2)x ;

4 + 2: (((x2)x)x)x2, (x2x2)x2; 3 + 3: (x2x)(x2x).

To explain the number 11 in degree 7, we have:

[6 + 1] 6 ·1 = 6, [5 + 2] 3 ·1 = 3, [4 + 3] 2 ·1 = 2 : total 11.

To explain the number 23 in degree 8, we have:

[7 + 1] 11 · 1, [6 + 2] 6 · 1, [5 + 3] 3 · 1, [4 + 4]

(2+1

2

): total 23.

Page 157: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

The resulting sequence is the Wedderburn-Etherington numbers:

1, 1, 1, 2, 3, 6, 11, 23, 46, 98, 207, 451, 983, 2179, 4850, . . .

To explain the number 3 in degree 5, we have:

4 + 1: (((x2)x)x)x , (x2x2)x ; 3 + 2: (x2x)x2.

To explain the number 6 in degree 6, we have:

5 + 1: ((((x2)x)x)x)x , ((x2x2)x)x , ((x2x)x2)x ;

4 + 2: (((x2)x)x)x2, (x2x2)x2; 3 + 3: (x2x)(x2x).

To explain the number 11 in degree 7, we have:

[6 + 1] 6 ·1 = 6, [5 + 2] 3 ·1 = 3, [4 + 3] 2 ·1 = 2 : total 11.

To explain the number 23 in degree 8, we have:

[7 + 1] 11 · 1, [6 + 2] 6 · 1, [5 + 3] 3 · 1, [4 + 4]

(2+1

2

): total 23.

Page 158: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Write Qn for the number of commutative nonassociative n-thpowers of x .

The last algorithm gives this equation:

Qn =

b(n−1)/2c∑i=1

Qn−iQi + (n even)1

2Qn/2(Qn/2 + 1).

The term which only occurs for n even means that we choose twofactors from degree n/2, allowing repetitions; it can also be written(

Qn/2

2

)+ Qn/2 =

(Qn/2 + 1

2

).

As before, define the formal power series with Qn as coefficients:

Q(t) =∞∑n=1

Qntn.

Page 159: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Write Qn for the number of commutative nonassociative n-thpowers of x . The last algorithm gives this equation:

Qn =

b(n−1)/2c∑i=1

Qn−iQi + (n even)1

2Qn/2(Qn/2 + 1).

The term which only occurs for n even means that we choose twofactors from degree n/2, allowing repetitions; it can also be written(

Qn/2

2

)+ Qn/2 =

(Qn/2 + 1

2

).

As before, define the formal power series with Qn as coefficients:

Q(t) =∞∑n=1

Qntn.

Page 160: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Write Qn for the number of commutative nonassociative n-thpowers of x . The last algorithm gives this equation:

Qn =

b(n−1)/2c∑i=1

Qn−iQi + (n even)1

2Qn/2(Qn/2 + 1).

The term which only occurs for n even means that we choose twofactors from degree n/2, allowing repetitions; it can also be written(

Qn/2

2

)+ Qn/2 =

(Qn/2 + 1

2

).

As before, define the formal power series with Qn as coefficients:

Q(t) =∞∑n=1

Qntn.

Page 161: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Write Qn for the number of commutative nonassociative n-thpowers of x . The last algorithm gives this equation:

Qn =

b(n−1)/2c∑i=1

Qn−iQi + (n even)1

2Qn/2(Qn/2 + 1).

The term which only occurs for n even means that we choose twofactors from degree n/2, allowing repetitions; it can also be written(

Qn/2

2

)+ Qn/2 =

(Qn/2 + 1

2

).

As before, define the formal power series with Qn as coefficients:

Q(t) =∞∑n=1

Qntn.

Page 162: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Let’s see what happens when we expand Q(t)2. We easily see,

Q(t)2 =( ∞∑

i=1

Qi ti)( ∞∑

j=1

Qj tj)

=∞∑n=2

( ∑i+j=n

QiQj

)tn.

To relate∑

i+j=n QiQj to Qn we must distinguish even and odd n.If n is odd, then∑

i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i

= 2Qn.

But if n is even, then∑i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i + Q2n/2

= 2Qn − Qn/2.

Page 163: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Let’s see what happens when we expand Q(t)2. We easily see,

Q(t)2 =( ∞∑

i=1

Qi ti)( ∞∑

j=1

Qj tj)

=∞∑n=2

( ∑i+j=n

QiQj

)tn.

To relate∑

i+j=n QiQj to Qn we must distinguish even and odd n.

If n is odd, then∑i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i

= 2Qn.

But if n is even, then∑i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i + Q2n/2

= 2Qn − Qn/2.

Page 164: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Let’s see what happens when we expand Q(t)2. We easily see,

Q(t)2 =( ∞∑

i=1

Qi ti)( ∞∑

j=1

Qj tj)

=∞∑n=2

( ∑i+j=n

QiQj

)tn.

To relate∑

i+j=n QiQj to Qn we must distinguish even and odd n.If n is odd, then∑

i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i

= 2Qn.

But if n is even, then∑i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i + Q2n/2

= 2Qn − Qn/2.

Page 165: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

Let’s see what happens when we expand Q(t)2. We easily see,

Q(t)2 =( ∞∑

i=1

Qi ti)( ∞∑

j=1

Qj tj)

=∞∑n=2

( ∑i+j=n

QiQj

)tn.

To relate∑

i+j=n QiQj to Qn we must distinguish even and odd n.If n is odd, then∑

i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i

= 2Qn.

But if n is even, then∑i+j=n

QiQj =

b(n−1)/2c∑i=1

Qn−iQi +

b(n−1)/2c∑i=1

QiQn−i + Q2n/2

= 2Qn − Qn/2.

Page 166: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

From this we see that Q(t) satisfies this functional equation:

Q(t)2 = 2(Q(t)− t)− Q(t2)

I am not aware of an exact solution of this equation.

Here are the two original papers by Wedderburn and Etherington:

J. H. M. Wedderburn:The Functional Equation g(x2) = 2αx + [g(x)]2.Annals of Mathematics. Second Series.Vol. 24, No. 2 (Dec., 1922), pp. 121-140.

I. M. H. Etherington:Non-associate powers and a functional equation.The Mathematical Gazette21 (1937), 36-39; addendum 21 (1937), 153.

Page 167: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

From this we see that Q(t) satisfies this functional equation:

Q(t)2 = 2(Q(t)− t)− Q(t2)

I am not aware of an exact solution of this equation.

Here are the two original papers by Wedderburn and Etherington:

J. H. M. Wedderburn:The Functional Equation g(x2) = 2αx + [g(x)]2.Annals of Mathematics. Second Series.Vol. 24, No. 2 (Dec., 1922), pp. 121-140.

I. M. H. Etherington:Non-associate powers and a functional equation.The Mathematical Gazette21 (1937), 36-39; addendum 21 (1937), 153.

Page 168: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

From this we see that Q(t) satisfies this functional equation:

Q(t)2 = 2(Q(t)− t)− Q(t2)

I am not aware of an exact solution of this equation.

Here are the two original papers by Wedderburn and Etherington:

J. H. M. Wedderburn:The Functional Equation g(x2) = 2αx + [g(x)]2.Annals of Mathematics. Second Series.Vol. 24, No. 2 (Dec., 1922), pp. 121-140.

I. M. H. Etherington:Non-associate powers and a functional equation.The Mathematical Gazette21 (1937), 36-39; addendum 21 (1937), 153.

Page 169: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

From this we see that Q(t) satisfies this functional equation:

Q(t)2 = 2(Q(t)− t)− Q(t2)

I am not aware of an exact solution of this equation.

Here are the two original papers by Wedderburn and Etherington:

J. H. M. Wedderburn:The Functional Equation g(x2) = 2αx + [g(x)]2.Annals of Mathematics. Second Series.Vol. 24, No. 2 (Dec., 1922), pp. 121-140.

I. M. H. Etherington:Non-associate powers and a functional equation.The Mathematical Gazette21 (1937), 36-39; addendum 21 (1937), 153.

Page 170: Catalan Numbers - University of Saskatchewanbremner/research/publications/Catalan_Talk_3... · Catalan Numbers PART 1 Catalan numbers arise from a simple enumeration problem: In how

Catalan Numbers

From this we see that Q(t) satisfies this functional equation:

Q(t)2 = 2(Q(t)− t)− Q(t2)

I am not aware of an exact solution of this equation.

Here are the two original papers by Wedderburn and Etherington:

J. H. M. Wedderburn:The Functional Equation g(x2) = 2αx + [g(x)]2.Annals of Mathematics. Second Series.Vol. 24, No. 2 (Dec., 1922), pp. 121-140.

I. M. H. Etherington:Non-associate powers and a functional equation.The Mathematical Gazette21 (1937), 36-39; addendum 21 (1937), 153.