The Daily Reckoning
Why Do Parentheses and Polygons Count the Same Way?
Four symbols have five complete parenthesizations. A pentagon has five triangulations. The Catalan recurrence reveals the shared branching structure behind both counts.
- Difficulty
- Intermediate
- Area
- Discrete mathematics and computation
- Reading time
- 9 minutes
- Prerequisites
- Multiplication and addition · Binomial coefficients · Reading a recurrence
Suppose is a binary operation: it joins exactly two inputs. The operation might be subtraction, function composition, or a step in a computer program. If is not associative, the bare expression
does not say which pair to combine first.
How many complete parenthesizations remove the ambiguity?
There are five. A convex pentagon also has exactly five ways to be divided into triangles with noncrossing diagonals. The equality is not a numerical accident. Both problems repeatedly split one object into an ordered left part and an ordered right part. That shared act of splitting produces the Catalan numbers.
Count by the final operation
A complete parenthesization of must have one operation performed last. That final operation separates the original symbols into a left consecutive block and a right consecutive block.
For example,
has between the two parenthesized pairs as its final operation. The left block contains ; the right block contains .
Let denote the number of complete parenthesizations of symbols. The index starts at , so : a single symbol has one harmless “parenthesization,” namely the symbol itself.
For , place symbols on the left of the final operation. The remaining symbols go on the right. There are ways to parenthesize the left block and ways to parenthesize the right block. Those choices are independent, so they multiply.
The final operation may split the symbols in any of positions. The counts for the different split positions add:
This equation is the Catalan recurrence.
Worked example: four symbols
Four symbols correspond to , so we want . First calculate the smaller values.
One symbol has one form:
Two symbols have only :
Three symbols can split after the first symbol or after the second:
Now split four symbols in each possible position.
Split after . The left block has one form. The three-symbol right block has two:
These are and .
Split after . Each two-symbol block has one form:
This gives .
Split after . The three-symbol left block has two forms. The right block has one:
These are and .
Add the three disjoint cases:
The interactive diagram lets you inspect the five parenthesizations beside the five pentagon triangulations.
Catalan correspondence
Step through the five structures
Parenthesization
Every pair of parentheses records one binary combine.
Pentagon triangulation
Two diagonals divide the pentagon into three triangles.
Structure 1 of 5. The two diagonals share the pentagon's top vertex.
Why the pentagon obeys the same recurrence
Fix one edge of a convex polygon and call it the base. Every triangulation contains exactly one triangle touching that base. The triangle’s third vertex divides the remaining region into two smaller polygons, one on the left and one on the right. Either smaller polygon may collapse to a single edge; that empty side contributes the value .
Once the third vertex has been chosen, a triangulation on the left can be paired with any triangulation on the right. The two counts multiply. Moving the third vertex through all possible positions produces disjoint cases, so the products add.
That is the Catalan recurrence again.
More precisely, a convex polygon with vertices has triangulations. A pentagon has vertices, hence triangulations. The same recursive split also builds a full binary tree: the final operation is the root, and the two subexpressions become its left and right subtrees.
The shared recurrence gives more than equal totals. It supplies a route for translating among parenthesizations, binary trees, and triangulations. The Open Mathematics textbook’s Catalan-number chapter develops the tree–triangulation correspondence explicitly.
A formula without recursion
The recurrence generates the sequence
one term at a time. A closed formula reaches the th term directly:
Here means , and counts the ways to choose positions from positions.
For the four-symbol problem,
In a standard lattice-path proof, the factor selects the balanced paths from all arrangements of upward steps and downward steps. A balanced path never falls below its starting height. Deriving the closed formula from those paths deserves its own lesson. The recurrence is enough for today’s objective: recognize the two-part split and count it without omission or duplication.
A sequence with more than one birthplace
The name hides a long, international history. Richard Stanley’s historical survey of Catalan numbers traces the coefficients to the Mongolian mathematician and astronomer Ming Antu, also known as Minggatu, who worked at the Qing court. In the 1730s, Ming Antu obtained the sequence while studying infinite trigonometric series. His setting was not polygon counting.
Ming Antu’s work grew inside a cross-cultural exchange. European series had reached Qing mathematicians through Jesuit scholars, but Ming Antu supplied geometric arguments and new expansions rather than merely copying imported formulas. His student Chen Jixin completed the manuscript in 1774, and the book was not published until 1839. That delay helped keep this line of development outside the European story for generations.
In Europe, Leonhard Euler posed the polygon-triangulation problem to Christian Goldbach in 1751. Johann Andreas von Segner published the recurrence in 1758; Goldbach, Segner, and Euler assembled parts of a proof, and Gabriel Lamé supplied a self-contained proof in 1838. The MathWorld account of Euler’s polygon-division problem records the 1751 question, while historian Igor Pak’s history of the sequence examines how the later name obscured earlier contributors.
Also in 1838, Eugène Catalan showed that the formula counts parenthesizations. The term “Catalan number” appeared only in the twentieth century and eventually stuck. The sequence did not spring from one lone insight: trigonometric series in Qing China, polygon dissections in eighteenth-century Europe, and symbolic parenthesization all exposed the same numbers from different directions.
Where the count appears in computation
Programming languages represent nested expressions as trees. A parser turns a flat stream of source-code tokens into that tree; the tree determines which operations belong together and therefore what the program means. The University of Central Florida’s compiler notes show how different syntax trees give different interpretations to an arithmetic expression.
For a flat sequence of operands joined by one binary operator, is the number of possible full binary tree shapes before precedence, associativity, or grammar rules remove ambiguity. A real compiler does not usually enumerate all of them. The Catalan count warns how quickly brute force grows: five operands give shapes, ten operands give , and twenty operands give .
The same count describes the shapes of ordered binary trees. Princeton’s analysis of tree algorithms uses Catalan numbers to enumerate binary trees with a fixed number of internal nodes. That enumeration matters when analyzing recursive tree algorithms and when estimating the search space of structures that split into ordered left and right pieces.
Polygon triangulation appears in computational geometry and mesh construction. The Catalan number does not choose a numerically stable or visually attractive triangulation; it counts every combinatorially distinct triangulation of a convex polygon. Knowing the size of that space explains why an algorithm should exploit recurrence or optimization rather than generate candidates blindly.
Try the split
Problem 1
Use the recurrence to calculate , the number of complete parenthesizations of five symbols. Show every product in the sum.
Reveal the solution
Use , , , and :
The four products correspond to placing the final operation after the first, second, third, or fourth symbol.
Problem 2
How many triangulations does a convex hexagon have? Explain the index rather than quoting the next number in the sequence.
Reveal the solution
A polygon with vertices has triangulations. A hexagon has vertices, so
Therefore the number of triangulations is
The hexagon and the five-symbol parenthesization problem have the same Catalan index because each object makes four recursive binary joins.
The idea to keep
When a structure is built by choosing one dividing point, solving an ordered left part, and solving an ordered right part, look for the Catalan recurrence. Parentheses, binary trees, and polygon triangulations count alike because each hides the same recursive split.
Continue with the bridge-traversal lesson for another origin story in discrete mathematics, or the minimum-spanning-tree lesson for a contrasting algorithm whose local choices avoid a Catalan-sized search.
Sources
- Richard P. Stanley, Catalan Numbers lecture transparencies, including the recurrence, historical timeline, and multiple interpretations.
- Igor Pak, “History of Catalan Numbers”, later published as the historical appendix to Stanley’s monograph.
- Massachusetts Institute of Technology OpenCourseWare, “Catalan Numbers I”.
- Oscar Levin, Discrete Mathematics: An Open Introduction, “The Catalan Numbers”.
- University of Central Florida, compiler-course notes on parsing and syntax trees.
- Princeton University, Analysis of Algorithms: tree enumeration.