Перейти к содержимому
Number Buffet

Числа Каталана

Одна последовательность, десятки смыслов: правильные скобочные последовательности, формы двоичных деревьев, способы разрезать многоугольник на треугольники.

OEIS A000108 · 3 мин чтения

Настройки

Быстрые наборы

Terms are produced in order starting from the chosen index.

C(0) = 1. Each term is roughly four times the one before it.

Picks which of the sequence’s many readings is explained beneath the output.

Group long terms as 14,544,636,039,226,909 for readability.

Тонкая настройка вида

Сначала выберите набор рядом с изображением — эти регуляторы его подстраивают.

Frame

A border drawn inside the edge of the image.

Дополнительно

Результаты

15 значений

1, 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16796, 58786, 208012, 742900, 2674440


Создать изображение

Включите JavaScript, чтобы оформить эти числа и скачать их картинкой. Сами значения перечислены выше.

Text on the image

Drag a line straight onto the picture to place it — once placed, it stays exactly where you put it. Everything here is drawn into the download.

Подробная статья ниже ещё не переведена и показана на английском.

О числа каталана

The sequence reached print in Europe in 1751, when Leonhard Euler asked how many ways a convex polygon can be cut into triangles by non-crossing diagonals and worked out both the counts and a formula. The name attached to it much later and for an entirely different reason. Eugène Charles Catalan, a Belgian-born mathematician who spent most of his career in France and Liège, found the connection to parenthesised expressions while working on the Towers of Hanoi puzzle. It was the twentieth-century American combinatorialist John Riordan who began calling the numbers Catalan's, and the label stuck.

The dates run further back than Euler, though this only became widely known in 1988. The Mongolian mathematician Mingantu, working in Qing China, had begun writing Ge Yuan Mi Lu Jie Fa — "the quick method for obtaining the precise ratio of division of a circle" — by about 1730, prompted in part by three infinite series that the Jesuit missionary Pierre Jartoux had brought to China early in the century. Mingantu used the sequence as coefficients in series expansions, writing sin 2α and sin 4α in terms of sin α. His student Chen Jixin completed the manuscript in 1774, and it waited roughly another sixty years to be published. Peter Larcombe surveyed this history in 1999.

What makes the sequence remarkable is less its discovery than how often it is rediscovered. Désiré André's reflection argument of 1887 gave a clean way to count Dyck words, and the catalogue of things the numbers count has kept growing: Richard Stanley's Enumerative Combinatorics sets out sixty-six different interpretations as exercises. The pattern is consistent enough that finding a counting problem whose answers are 1, 1, 2, 5, 14, 42 is now taken as a strong hint that a bijection to brackets or trees is waiting to be found.

Ключевые свойства

  • C(0) = C(1) = 1, and C(n) = C(2n, n) / (n + 1) = (2n)! / (n! · (n+1)!).
  • Equivalently C(n) = C(2n, n) − C(2n, n+1), a difference of two binomial coefficients.
  • The sequence convolves with itself: C(n+1) = C(0)·C(n) + C(1)·C(n−1) + … + C(n)·C(0).
  • C(n+1) = C(n) · 2(2n + 1) / (n + 2), and the result is always a whole number, which is what lets each term be computed from its predecessor in exact integer arithmetic.
  • C(n) is odd exactly when n = 2^k − 1; every other Catalan number is even.
  • The only prime Catalan numbers are C(2) = 2 and C(3) = 5.
  • The ratio C(n+1)/C(n) approaches 4, since C(n) grows like 4ⁿ / (n^(3/2)·√π).
  • The n×n Hankel matrix whose (i, j) entry is C(i+j−2) has determinant 1 for every n.

Где встречаются

  • Parsing and expression evaluation: C(n) is the number of ways to parenthesise a chain of n + 1 factors, so it is the size of the search space that matrix-chain multiplication and similar dynamic-programming problems have to avoid enumerating.
  • Data structures: C(n) counts the distinct shapes of a binary tree with n internal nodes, which is the figure behind average-case analyses of unbalanced binary search trees and of random tree generation.
  • Computational geometry: the triangulations of a convex polygon — Euler’s original question — are counted by C(n), and the same numbers bound the fan-triangulation choices in mesh generation.
  • Molecular biology: non-crossing chord diagrams on 2n points, counted by C(n), are the standard model for pseudoknot-free RNA secondary structures.
  • Elections and queues: Bertrand’s ballot problem, where one candidate must stay ahead throughout the count, is the Catalan numbers in another costume, and the same bound governs stack-sortable sequences.
  • Trigonometric series: Mingantu used the sequence as expansion coefficients for sine functions in the 1730s, decades before the combinatorial readings were written down.

Как пользоваться этим генератором

Сгенерированные значения показаны сверху, рядом с кнопкой копирования. Чтобы превратить их в изображение, выберите вид среди стилей в блоке Создать изображение, задайте размер экспорта и скачайте в PNG, JPEG или WebP. Всё отрисовывается в браузере, поэтому ничего из созданного вами не уходит на сервер.

Адресная строка обновляется по ходу работы, поэтому ссылка всегда воспроизводит в точности то, что вы видите, — удобно, чтобы поделиться конкретной последовательностью или сохранить настройку. Нажмите Копировать, чтобы получить значения обычным текстом, или Экспорт данных для CSV, JSON, NDJSON, SQL и XML.

Источники

Исторические справки на этой странице опираются на перечисленные выше источники со свободной лицензией. Заметили ошибку? Напишите нам, и мы её исправим.