当前位置:网站首页>[combinatorial mathematics] counting model, common combinatorial numbers and combinatorial identities**
[combinatorial mathematics] counting model, common combinatorial numbers and combinatorial identities**
2022-07-03 16:39:00 【Programmer community】
One 、 Counting model
The counting model currently involved :
1 . Select the question :
n
n
n Meta set
S
S
S , from
S
S
S Select... From the set
r
r
r Elements ;
according to Whether the element can be repeated , Whether the selection process is orderly , The selection question is divided into four sub types :
Elements do not repeat | Elements can be repeated | |
---|---|---|
Orderly selection | Set arrangement P ( n , r ) P(n,r) P(n,r) | Multiset arrangement |
Unordered selection | Set combination C ( n , r ) C(n,r) C(n,r) | Combination of multiple sets |
Select the question :
- Non repeatable elements , Orderly selection , Corresponding Arrangement of sets ;
P
(
n
,
r
)
=
n
!
(
n
−
r
)
!
P(n,r) = \dfrac{n!}{(n-r)!}
P(n,r)=(n−r)!n!
- Non repeatable elements , Unordered selection , Corresponding A combination of sets ;
C
(
n
,
r
)
=
P
(
n
,
r
)
r
!
=
n
!
r
!
(
n
−
r
)
!
C(n,r) = \dfrac{P(n,r)}{r!} = \dfrac{n!}{r!(n-r)!}
C(n,r)=r!P(n,r)=r!(n−r)!n!
- Repeatable elements , Orderly selection , Corresponding Arrangement of multiple sets ;
whole
row
Column
=
n
!
n
1
!
n
2
!
⋯
n
k
!
Full Permutation = \cfrac{n!}{n_1! n_2! \cdots n_k!}
whole row Column =n1!n2!⋯nk!n! , Incomplete permutation
k
r
,
r
≤
n
i
k^r , \ \ r\leq n_i
kr, r≤ni
- Repeatable elements , Unordered selection , Corresponding Combination of multiple sets ;
N
=
C
(
k
+
r
−
1
,
r
)
N= C(k + r - 1, r)
N=C(k+r−1,r)
2 . Number of nonnegative integer solutions of indefinite equation :
x
1
+
x
2
+
⋯
+
x
k
=
r
x_1 + x_2 + \cdots + x_k = r
x1+x2+⋯+xk=r
The number of nonnegative integer solutions is :
N
=
C
(
k
+
r
−
1
,
r
)
N= C(k + r - 1, r)
N=C(k+r−1,r)
It is also the combinatorial number of multiple sets ;
3 . Non descending path problem :
Basic model : from
(
0
,
0
)
(0,0)
(0,0) To
(
m
,
n
)
(m, n)
(m,n) The number of non descending paths
(
m
+
n
m
)
\dbinom{m + n}{m}
(mm+n) ;
Expand the model 1 : from
(
a
,
b
)
(a,b)
(a,b) To
(
m
,
n
)
(m, n)
(m,n) The number of non descending paths
(
m
−
a
+
n
−
b
m
−
a
)
\dbinom{m-a + n-b}{m-a}
(m−am−a+n−b) ;
Expand the model 2 : from
(
a
,
b
)
(a,b)
(a,b) after
(
c
,
d
)
(c, d)
(c,d) To
(
m
,
n
)
(m, n)
(m,n) The number of non descending paths
(
c
−
a
+
c
−
b
c
−
a
)
(
m
−
c
+
n
−
d
m
−
c
)
\dbinom{c-a + c-b}{c-a}\dbinom{m-c + n-d}{m-c}
(c−ac−a+c−b)(m−cm−c+n−d)
The number of non descending paths of the constraint : from
(
0
,
0
)
(0,0)
(0,0) To
(
n
,
n
)
(n,n)
(n,n) Except endpoint , The number of non descending paths that do not touch the diagonal
Reference resources : 【 Combinatorial mathematics 】 Non descending path problem ( The number of non descending paths of the constraint )
Two 、 Common combination count
Common combination count :
I . Binomial coefficient
(
x
+
y
)
n
=
∑
k
=
0
n
(
n
k
)
x
k
y
n
−
k
(x + y)^n = \sum_{k=0}^n \dbinom{n}{k}x^k y^{n-k}
(x+y)n=k=0∑n(kn)xkyn−k
(
n
k
)
\dbinom{n}{k}
(kn) It's binomial coefficient ;
Binomial coefficient correlation combinatorial identity :
1 . Combinatorial identity ( recursion ) :
( 1 ) recursion 1 :
(
n
k
)
=
(
n
n
−
k
)
\dbinom{n}{k} = \dbinom{n}{n-k}
(kn)=(n−kn)①
( 2 ) recursion 2 :
(
n
k
)
=
n
k
(
n
−
1
k
−
1
)
\dbinom{n}{k} = \dfrac{n}{k} \dbinom{n - 1}{k - 1}
(kn)=kn(k−1n−1)②
( 3 ) recursion 3 ( Pascal / Yang Hui's trigonometric formula ) :
(
n
k
)
=
(
n
−
1
k
)
+
(
n
−
1
k
−
1
)
\dbinom{n}{k} = \dbinom{n - 1}{k} + \dbinom{n - 1}{k - 1}
(kn)=(kn−1)+(k−1n−1)③
2 . Review the combinatorial identities of summation under four variables : The combinatorial identity introduced earlier The number of combinations in
(
n
k
)
\dbinom{n}{k}
(kn) , Is the next item
k
k
k Have been accumulating changes , have
∑
k
=
0
n
\sum\limits_{k=0}^{n}
k=0∑n Cumulative property , Previous item
n
n
n It is the same. ;
( 1 ) Simple and :
∑
k
=
0
n
(
n
k
)
=
2
n
\sum\limits_{k=0}^{n}\dbinom{n}{k} = 2^n
k=0∑n(kn)=2n④
( 2 ) Staggered and :
∑
k
=
0
n
(
−
1
)
k
(
n
k
)
=
0
\sum\limits_{k=0}^{n} (-1)^k \dbinom{n}{k} = 0
k=0∑n(−1)k(kn)=0⑤
( 3 ) Change the next term to sum 3 :
∑
k
=
0
n
k
(
n
k
)
=
n
2
n
−
1
\sum\limits_{k=0}^{n} k \dbinom{n}{k} = n 2^{n-1}
k=0∑nk(kn)=n2n−1⑥
( 4 ) Change the next term to sum 4 :
∑
k
=
0
n
k
2
(
n
k
)
=
n
(
n
+
1
)
2
n
−
2
\sum_{k=0}^{n} k^2 \dbinom{n}{k} = n ( n+1 ) 2^{n-2}
∑k=0nk2(kn)=n(n+1)2n−2⑦
3 . Change the upper term to sum :
∑
l
=
0
n
(
l
k
)
=
(
n
+
1
k
+
1
)
\sum\limits_{l=0}^{n} \dbinom{l}{k} = \dbinom{n + 1}{k + 1}
l=0∑n(kl)=(k+1n+1)⑧
4 . product :
∑
l
=
0
n
(
l
k
)
=
(
n
+
1
k
+
1
)
\sum\limits_{l=0}^{n} \dbinom{l}{k} = \dbinom{n + 1}{k + 1}
l=0∑n(kl)=(k+1n+1)⑨
5 . Sum of product :
( 1 ) Combinatorial identity ( Sum of product ) 1 :
∑
k
=
0
r
(
m
k
)
(
n
r
−
k
)
=
(
m
+
n
r
)
,
r
=
min
{
m
,
n
}
\sum\limits_{k=0}^{r}\dbinom{m}{k}\dbinom{n}{r-k} = \dbinom{m + n }{r} , \ \ \ \ \ \ r= \min \{ m, n \}
k=0∑r(km)(r−kn)=(rm+n), r=min{ m,n}⑩
( 2 ) Combinatorial identity ( Sum of product ) 2 :
∑
k
=
0
r
(
m
k
)
(
n
k
)
=
(
m
+
n
m
)
\sum\limits_{k=0}^{r}\dbinom{m}{k}\dbinom{n}{k} = \dbinom{m + n }{m}
k=0∑r(km)(kn)=(mm+n)⑪
II . Polynomial coefficients
(
x
1
+
x
2
+
⋯
+
x
t
)
n
\ \ \ \ (x_1 + x_2 + \cdots + x_t)^n
(x1+x2+⋯+xt)n
=
∑
full
foot
n
1
+
n
2
+
⋯
+
n
t
=
n
Not
negative
whole
Count
Explain
individual
Count
(
n
n
1
n
2
⋯
n
t
)
x
1
n
1
x
2
n
2
⋯
x
t
n
t
= \sum\limits_{ Satisfy n_1 + n_2 + \cdots + n_t = n Number of nonnegative integer solutions }\dbinom{n}{n_1 n_2 \cdots n_t}x_1^{n_1}x_2^{n_2}\cdots x_t^{n_t}
= full foot n1+n2+⋯+nt=n Not negative whole Count Explain individual Count ∑(n1n2⋯ntn)x1n1x2n2⋯xtnt
(
n
n
1
n
2
⋯
n
t
)
\dbinom{n}{n_1 n_2 \cdots n_t}
(n1n2⋯ntn) Is a polynomial coefficient
Polynomial coefficient correlation combination identity :
1 . Polynomial theorem inference 3 :
∑
(
n
n
1
n
2
⋯
n
t
)
=
t
n
\sum\dbinom{n}{n_1 n_2 \cdots n_t} = t^n
∑(n1n2⋯ntn)=tn
2 . Full Permutation of multiple sets :
(
n
n
1
n
2
⋯
n
t
)
=
n
!
n
1
!
n
2
!
⋯
n
k
!
\dbinom{n}{n_1 n_2 \cdots n_t} = \cfrac{n!}{n_1! n_2! \cdots n_k!}
(n1n2⋯ntn)=n1!n2!⋯nk!n!
3 . recursion :
(
n
n
1
n
2
⋯
n
t
)
=
(
n
−
1
(
n
1
−
1
)
n
2
⋯
n
t
)
+
(
n
−
1
n
1
(
n
2
−
1
)
⋯
n
t
)
+
(
n
−
1
n
1
n
2
⋯
(
n
t
−
1
)
)
\dbinom{n}{n_1 n_2 \cdots n_t} = \dbinom{n-1}{(n_1-1) n_2 \cdots n_t} + \dbinom{n-1}{n_1 (n_2 - 1) \cdots n_t}+ \dbinom{n-1}{n_1 n_2 \cdots (n_t -1)}
(n1n2⋯ntn)=((n1−1)n2⋯ntn−1)+(n1(n2−1)⋯ntn−1)+(n1n2⋯(nt−1)n−1)
边栏推荐
- 为抵制 7-Zip,列出 “三宗罪” ?网友:“第3个才是重点吧?”
- Leetcode binary search tree
- NSQ source code installation and operation process
- 【剑指 Offer 】64. 求1+2+…+n
- Nifi from introduction to practice (nanny level tutorial) - flow
- The mixlab editing team is recruiting teammates~~
- [Jianzhi offer] 58 - ii Rotate string left
- There are several APIs of airtest and poco that are easy to use wrong in "super". See if you have encountered them
- Unreal_ Datatable implements ID self increment and sets rowname
- Multithread 02 thread join
猜你喜欢
[combinatorics] non descending path problem (outline of non descending path problem | basic model of non descending path problem | non descending path problem expansion model 1 non origin starting poi
【LeetCode】94. Middle order traversal of binary tree
8 cool visual charts to quickly write the visual analysis report that the boss likes to see
NFT new opportunity, multimedia NFT aggregation platform okaleido will be launched soon
Mysql 将逗号隔开的属性字段数据由列转行
Mysql 单表字段重复数据取最新一条sql语句
斑馬識別成狗,AI犯錯的原因被斯坦福找到了
关于视觉SLAM的最先进技术的调查-A survey of state-of-the-art on visual SLAM
探索Cassandra的去中心化分布式架构
QT串口ui设计和解决显示中文乱码
随机推荐
How programming apes grow rapidly
NSQ source code installation and operation process
Basis of target detection (IOU)
NLP four paradigms: paradigm 1: fully supervised learning in the era of non neural networks (Feature Engineering); Paradigm 2: fully supervised learning based on neural network (Architecture Engineeri
在ntpdate同步时间的时候出现“the NTP socket is in use, exiting”
Alibaba P8 painstakingly sorted it out. Summary of APP UI automated testing ideas. Check it out
Custom plug-in construction and use of QT plug-in
(Supplement) double pointer topic
深入理解 SQL 中的 Grouping Sets 语句
Thinking about telecommuting under the background of normalization of epidemic | community essay solicitation
Golang 匿名函数使用
Leetcode binary search tree
PyTorch 1.12发布,正式支持苹果M1芯片GPU加速,修复众多Bug
"Everyday Mathematics" serial 56: February 25
Aike AI frontier promotion (7.3)
What is the material of 13mnnimor? 13mnnimor steel plate for medium and low temperature pressure vessels
0214-27100 a day with little fluctuation
Arduino esp32: overall framework of lvgl project (I)
Is it safe to open a stock account by mobile registration? Does it need money to open an account
MySQL single table field duplicate data takes the latest SQL statement