组合数学_学习笔记(二)
Combinatorial Mathematics
(TsinghuaX: 60240013x)
Linear Homogeneous Recurrence Relation
Fibonacci Rabbits
Fibonacci number
Fibonacci prime
Area of the rectangle = Sum of multiple quadrates
Expressions of Fibonacci Numbers
Linear Homogeneous Recurrence Relation
Def If sequence
Fibonacci Recurrence
Characteristic Polynomial
1. distinct real roots
2. Characteristic polynomial
3. Characteristic polynomial
Summary
Applications
-
There’s a point
P on the plane. It’s the cross ofn fieldsD1,D2,…Dn . Color thesen fields withk colors. We require the color of two adjacent areas to be different.
Calculate the number of arrangements.Let
an be the number of arrangement to color these areas. There are 2 situations:-
D1 andDn−1 have the same colorDn hask−1 choices, which is all colors except the one used byD1 andDn−1 ;
the arrangements forDn−2 toD1 are one-to-one correspondent to the arrangements forn−2 areas.(k−1)an−2 -
D1 andDn−1 have different colors.Dn hask−2 choices; the arrangements fromD1 toDn−1 are one-to-one correspondent to the arrangements forn−1 areas.(k−2)an−1
∴an=(k−2)an−1+(k−1)an−2,a2=k(k−1),a3=k(k−1)(k−2). a1=0,a0=k x2−(k−2)x−(k−1)=0 x1=k−1,x2=−1. an=A(k−1)n+B(−1)n {A+B=k,(k−1)A−B=0. {A=1,B=k−1. ∴an=(k−1)n+(k−1)(−1)n,n≥2. a1=k. -
Magical Sequences
Catalan Numbers
-
One stack (of infinite size) has the “push” sequence:
1,2,3,...n . How many ways can the numbers be popped out?Partition the
n sequences into two sub-sequences.f(n)=f(k−1)∗f(n−k) -
Binary Tree
How many different shapes can a binary tree with n nodes have?The root will obviously contain one node.
AssumeT(i,j) stands the left subtree of the root containingI nodes, and right subtree withj nodes.
Not counting the root, there aren−1 nodes that could be structured as:
Actually,
Dyck Language
Hands across the table
Exponential Generating Functions
Binomial Theorem
-
3a1,2a2,3a3
How many combinations of length4 ?
Key:70
Hint:4!(43!+32!2!+32!)=70
For a seq
-
Using the digits 1, 2, 3 and 4, construct a five digit number where 1 doesn’t appear more than 2 times, but has to appear at least once; 2 can’t appear more than once; 3 can appear up to 3 times but can also not appear in the number; 4 can only appear an even number of times. How many numbers can satisfy these conditions?
Hint:
Anr digit number that satisfies the condition isar ; the exponential generating function for the seqa0,a1,…,a10 is:There are
215 5-digit numbers that satisfy the conditions. -
With digits
1,3,5,7,9 , how many n-digit numbers are there, where3 and7 appear an even number of times, and1,5,9 don’t have any conditions.Hint:
Assume an r-digit number that satisfies the conditions isar . Then, the exponential generating function of the seq ofa1,a2,...,a3 is:
Derangements
之前浅显的学习笔记
A derangement is a permutation of the elements of a set such that none of the elements appear in their original position.
Suppose the derangement of n elements in a sequence
For the other part, not considering the number
Stirling Numbers
Stirling numbers of the first kind
- The
n+1st person can dance alone, and the others formm−1 groups. - The
n+1st person joins a group, and will haven choices for groups, while the othern people haves(n,m) ways of forming groups.
Stirling numbers of the second kind
Definition: The number of ways
Theorem: Stirling number of the second kind
-
S(n,0)=0 -
S(n,1)=1 -
S(n,2)=2n−1−1
Proof:
Assume there aren non-identical ballsb1,b2,...,bn , from which we pickb1 . Now for the othern−1 balls, there are two possibilities, either they can be in the same box asb1 or a box that doesn’t containb1 . But it can only satisfy one of these conditions, therefore there are2n−1−1 ways of placing the balls. -
S(n,n)=1
Theorem: Stirling number of the second kind satisfies the following recurrence relation.
Proof: Suppose there are
Placing n balls into m boxes where no box is empty can be classified into two possibilities.
1.
2.
A generating function is a clothesline on which we hang up a sequence of numbers.
— — Herbert Wilf