L11 – Catalan number and T-routes
5,680字
24–36 分钟
Catalan Number
Triangulation of Convex Polygons
: convex -polygons (interior angles , vertices point outward)

DEFINITION: A triangulation of is a set of diagonals of which do not cross in their interiors.
The th Catalan Number (Euler, 1751): # of triangulations of

Earlier findings: Ming Antu (1692-1763) in Qing court (China), established the following formula in “Quick Methods for Accurate Values of Circle Segments”:
Recurrence Relation: ,
- has triangulations
- After removing an edge , each triangulation of gives
- a triangulation for and a triangulation for

Binary Trees
DEFINITION: A binary tree is defined recursively as follows.
- The empty set is a binary tree.
- Otherwise, a binary tree has a root vertex , a left subtree , and a right subtree , both of which are binary trees.
- left child: the root of ; right child: the root of

THEOREM: The number of binary trees with vertices is
- proof is omitted
Plane Trees
DEFINITION: A plane tree (ordered tree) is defined recursively as follows.
- A single vertex is a plane tree. And the vertex is called the root of the tree.
- Otherwise, a plane tree has a root vertex , and a sequence of subtrees, each of which is a plane tree.

THEOREM: The number of plane trees with vertices is .
- proof is omitted
Parenthesization
DEFINITION: A parenthesization (or bracketing) of a string of symbols consists of the insertion of left parentheses and right parentheses that define binary operations on the string.
- Eugêne Charles Catalan (1814-1894) studied this problem in 1838
EXAMPLE: There are five parenthesizations on four symbols
- ;
- ;
- ;
- ;
THEOREM: The number of parenthesizations of a string of symbols is .
- proof is omitted
Ballot sequence
DEFINITION: A ballot sequence of length is a sequence of ‘s and ‘s, where
- the number of ‘s is equal to the number of ‘s; and
- the sum of every prefix of the sequence is nonnegative.
Bertrand’s Ballot Problem (special case): There are two candidates A and B in an election. Each receives votes. What is the probability that A will never trail B during the count of votes?
- First published by W. A. Whitworth (1840-1905) in 1878
- Named after Joseph Louis Francois Bertrand (1822-1900) who rediscovered it in 1887.
EXAMPLE: AABABBBAAB is bad, since among the first 7 votes, A receives 3 but B receives 4 , which is greater than 3.
THEOREM: The number of Ballot sequences of length is .
- proof is omitted
Dyck path
DEFINITION: A Dyck path of length is a sequence , , of lattice points (points with integral entries) such that
- for all
- for all

THEOREM: The number of Dyck paths of length is .
REMARK: Dyck path may be called T-route generally. The name of “Dyck path” is in memory of German mathematician Walther von Dyck (1856-1934)
Shortest Path
DEFINITION: A -grid is a collection of squares of side length 1, organized as a rectangle of side length and .

THEOREM: The number of shortest paths from to is .
- Let be a -multiset.
- The number of shortest paths the number of permutations of .
T-Route
DEFINITION: Let . // integral (lattice) points
- A T-Step at is a segment from to or .
- A T-Route from to is a route where each step is a T-step.

THEOREM: There is a T-route from to only if (1) ; (2) ; and (3) .
- Let be a T-route from to , where .
- ; ;
- ; for every
REMARK: The T-condition (1)+(2)+(3) is sufficient for the existence of a T-route.



THEOREM: Let satisfy the T-condition, where . Then # of T-routes from to that do not intersect the x-axis is
© 版权声明
文章版权归作者所有,未经允许请勿转载。




Ballot序列那个例子是不是数错了?A前七票3:4,B领先咋不算拖后腿?
明安图也太猛了吧,清朝那会儿就能搞这种级数展开?🤯
明安图这名字一听就感觉来头不小,结果真是大神。
那个公式推导太绕了,看得我脑壳疼。
脑壳疼+1,那个级数展开我直接跳过了
Catalan数列前几项是1,1,2,5,14…这个背下来做题快。
T-route和Dyck path是一个东西吗?看着好像。
这证明省略得有点多吧,初学者看这也太难了。
Ballot sequence那个例子看半天,感觉还是有点绕。
递推公式Cn+1那个,有没有大佬讲讲具体怎么推出来的?
Dyck路径画起来还挺好玩的,感觉比推公式有意思。
那个公式推导看晕了,当年离散数学怎么过的都忘了。
括号匹配那个例子列举得挺全,数起来不累
列举全了才好对照验证
T-route就是德克路径吧
递归公式看着眼熟,组合数学老面孔了
投票问题那个例子挺形象,一下就看懂了
我也是看那个例子才懂的
明安图居然比欧拉还早?清朝数学这么猛的吗
全是 proof omitted 算了直接背
二叉树和括号化居然都是卡特兰数,太巧了
我也被这个巧合吸引了
T-route 那个公式看着好复杂
同感,公式看着头大
括号匹配那段,之前考试差点挂在这上面
原来Dyck路径就是T-route,之前一直没搞懂
我也卡在这很久
明安图居然研究到这个深度,清朝数学被低估了
主要是史料记载少,好多成就都没传下来。
感觉那时候的数学更偏向应用,能搞出纯理论公式挺难得的。
Catalan数在组合数学里应用真广
组合数学确实精彩
这个证明省略得有点多,需要自己补全吗
Cn+1=∑CkCn−k这个递推怎么记啊,每次都要现推
Ballot sequence那个例子”AABABBBAAB”找问题找半天,终于明白了😭
AABABBBAAB那个例子,数到第七票A3B4,B反超了所以不行?
我上次手写Catalan数的递推,算到第七项才发现公式里隐藏的对称性,感觉像在解谜一样,挺有成就感的。
有没有人把二叉树的递归写成非递归版,性能会不会好点?我想试试看。
我之前用Catalan数算过多边形划分,代码卡了一下才对上答案。
同踩坑,边界条件稍微写错一点就全乱了。
要是能贴一下代码片段就好了,正好对比下哪里有问题。
那个递推关系我当时也推了好久,手算很容易漏项。
多边形划分要是顶点一多,复杂度爆炸。
我也跑过这个题,debug到怀疑人生。
三角剖分这玩意儿代码实现起来坑不少,边界条件特麻烦。
这递推式记得小考试时背的。
如果把T路算错了,后面全崩。
看完才发现括号匹配背后藏大树。
明安图的公式居然这么早出现,牛掰。
清朝那会儿就能推出来这公式,确实有点东西。
这公式看着太像无穷级数了,当时看的时候愣了一下。
明安图那个是独立发现的吗?还是跟西方有交流啊?
明安图那个确实牛,清朝就有这水平了。
Dyck路径画起来还挺好玩的😂
二叉树对应Catalan,突然恍然大悟。
三角剖分那段突然串起来了,之前学计算几何卡了好久。
二叉树那条,当时没想明白为什么是n个顶点不是n+1
二叉树那个对应关系之前一直没搞懂,原来是这样。
这三角剖分真是把数学变魔术。
Cn=∑CkCn-k这个递推当年背半天,现在全还给老师了
居然还提到了明安图!清朝大数学家居然研究这个
原来选票问题和二叉树也是Catalan数,数学真奇妙
原来平面树和括号表达式也是Catalan数
组合数学真有意思
原来迪克路径也是Catalan数的一种表现
组合数学的魅力
原来平面树也是Catalan数,之前只知道括号匹配
Catalan数在这么多领域都有应用,有点震撼
原来选票问题和二叉树也是Catalan数,数学真奇妙
原来选票问题和二叉树也是Catalan数,数学真奇妙
原来选票问题和括号匹配都是Catalan数,神奇
组合数学的魅力
原来选票问题也是Catalan数,数学无处不在啊
明安图那个公式,清朝人怎么算出来的,离谱。
原来括号匹配和树结构都跟Catalan数有关
这公式推导看晕了…当年离散数学怎么过的都忘了
原来T-route还能这样推广,学到了🤔