Skip to main content

Catalan Numbers

Generate Catalan numbers, look up a term, or test whether a number is a Catalan number.

The Catalan numbers appear all over combinatorics: counting balanced bracket sequences, binary trees, and ways to triangulate a polygon. Indexing here is 0-based, so C(0) is the first term.

They begin 1, 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16796 and use the recurrence C(n+1) = C(n) × 2(2n+1) / (n+2).

Generate first K terms

Up to 1000 terms.

Look up C(n)

Test a number