『Discrete Mathematics and Its Applications』离散数学及其应用学习笔记

教材是Discrete Mathematics and Its Applications 7th,做了一些简单的翻译和简单的笔记。

1. The Foundations: Logic and Proofs

ENGCHNDenote
negation否定 ¬ p \neg p ¬p
conjunction (and)合取 p ∧ q p \land q pq
disjunction (or)析取 p ∨ q p \lor q pq
exlusive or异或 p ⊕ q p \oplus q pq
conditional statement/
implication
蕴含 p → q p \to q pq
biconditional statement等价 p ↔ q p \leftrightarrow q pq
tautology永真式 ≡ 1 \equiv 1 1
contingency可能式 0 / 1 0/1 0/1
contradiction矛盾式 ≡ 0 \equiv 0 0
proposition命题 p → q p \to q pq
converse proposition逆命题 q → p q \to p qp
inverse proposition否命题 ¬ p → ¬ q \neg p \to \neg q ¬p¬q
contrapositive proposition逆否命题 ¬ q → ¬ p \neg q \to \neg p ¬q¬p

 Precedence of Logical Operators:
¬   >   ∧   >   ∨ >   →   >   ↔ \neg\ >\ \land\ >\ \lor>\ \to\ >\ \leftrightarrow ¬ >  > >  > 
 Implication Law:
p → q ≡ ¬ p ∨ q    ⟺    p \to q \equiv \neg p \lor q \iff pq¬pq if p p p then q    ⟺    q q \iff q qq if/when p    ⟺    p p \iff p pp only if q    ⟺    q q \iff q qq unless ¬ p \neg p ¬p
 Equivalence Law:
p ↔ q ≡ ( p → q ) ∧ ( q → p )    ⟺    p p \leftrightarrow q \equiv (p \to q) \land (q \to p) \iff p pq(pq)(qp)p if and only if q    ⟺    p q \iff p qp iff q q q

Logical Equivalences:
EquivalenceENGCHN
p ∧ T ≡ p p \land T \equiv p pTp
p ∨ F ≡ p p \lor F \equiv p pFp
Identity Laws同一律
p ∨ T ≡ T p \lor T \equiv T pTT
p ∧ F ≡ F p \land F \equiv F pFF
Domination Laws零律
p ∨ p ≡ p p \lor p \equiv p ppp
p ∧ p ≡ p p \land p \equiv p ppp
Idempotent Laws幂等律
¬ ( ¬ p ) ≡ p \neg (\neg p) \equiv p ¬(¬p)pDouble Negation Law双重否定律
p ∨ q ≡ q ∨ p p \lor q \equiv q \lor p pqqp
p ∧ q ≡ q ∧ p p \land q \equiv q \land p pqqp
Comutative Laws交换律
( p ∨ q ) ∨ r ≡ p ∨ ( q ∨ r ) (p \lor q) \lor r \equiv p \lor (q \lor r) (pq)rp(qr)
( p ∧ q ) ∧ r ≡ p ∧ ( q ∧ r ) (p \land q) \land r \equiv p \land (q \land r) (pq)rp(qr)
Associative Laws结合律
p ∨ ( q ∧ r ) ≡ ( p ∨ q ) ∧ ( p ∨ r ) p \lor (q \land r) \equiv (p \lor q) \land (p \lor r) p(qr)(pq)(pr)
p ∧ ( q ∨ r ) ≡ ( p ∧ q ) ∨ ( p ∧ r ) p \land (q \lor r) \equiv (p \land q) \lor (p \land r) p(qr)(pq)(pr)
Distributive Laws分配律
¬ ( p ∧ q ) ≡ ¬ p ∨ ¬ q \neg (p \land q) \equiv \neg p \lor \neg q ¬(pq)¬p¬q
¬ ( p ∨ q ) ≡ ¬ p ∧ ¬ q \neg (p \lor q) \equiv \neg p \land \neg q ¬(pq)¬p¬q
De Morgan’s Laws德摩根定律
p ∨ ( p ∧ q ) ≡ p p \lor (p \land q) \equiv p p(pq)p
p ∧ ( p ∨ q ) ≡ p p \land (p \lor q) \equiv p p(pq)p
Absorption Laws吸收律
p ∨ ¬ p ≡ T p \lor \neg p \equiv T p¬pT
p ∧ ¬ p ≡ F p \land \neg p \equiv F p¬pF
Negation Laws排中律
矛盾律

Show p ≡ q p \equiv q pq :
 a. Using truth tables
 b. Using already-proved equivalences (Recommended)

Predicates and Quantifiers:

 Universal Quantifier  ∀ \forall :
∀ x P ( x )    ⟺    P ( x ) \forall xP(x) \iff P(x) xP(x)P(x) for all values of x x x in the (restricted) domain
 Existential Quantifier  ∃ \exist :
∃ x P ( x )    ⟺    \exist xP(x) \iff xP(x) There exists (at least) an element x x x in the domain such that P ( x ) P(x) P(x)
 De Morgan’s Laws for quantifiers:
¬ ∀ x P ( x ) ≡ ∃ x ¬ P ( x ) \neg \forall xP(x) \equiv \exist x \neg P(x) ¬xP(x)x¬P(x)
¬ ∃ x Q ( x ) ≡ ∀ x ¬ Q ( x ) \neg \exist xQ(x) \equiv \forall x \neg Q(x) ¬xQ(x)x¬Q(x)
Notice: ∀ \forall and ∃ \exist have higher precedence than any logical operators
 Remark:
 All P ( x ) P(x) P(x) are Q ( x )    ⟺    ∀ x ( P ( x ) → Q ( x ) ) Q(x) \iff \forall x (P(x) \to Q(x)) Q(x)x(P(x)Q(x))
 No P ( x ) P(x) P(x) are Q ( x )    ⟺    ∀ x ( P ( x ) → ¬ Q ( x ) ) Q(x) \iff \forall x (P(x) \to \neg Q(x)) Q(x)x(P(x)¬Q(x))
 Some P ( x ) P(x) P(x) are Q ( x )    ⟺    ∃ x ( P ( x ) ∧ Q ( x ) ) Q(x) \iff \exist x (P(x) \land Q(x)) Q(x)x(P(x)Q(x))
 Some P ( x ) P(x) P(x) are not Q ( x )    ⟺    ∃ x ( P ( x ) ∧ ¬ Q ( x ) ) Q(x) \iff \exist x (P(x) \land \neg Q(x)) Q(x)x(P(x)¬Q(x))
eg. Recall that the definition of lim ⁡ x → a f ( x ) = L {\lim_{x \to a}f(x)=L} xalimf(x)=L  is ∀ ϵ > 0   ∃ δ > 0   ∀ x ( 0 < ∣ x − a ∣ < δ → ∣ f ( x ) − L ∣ < ϵ ) {\forall \epsilon>0\ \exist \delta>0\ \forall x(0<|x-a|<\delta \to |f(x)-L|<\epsilon)} ϵ>0 δ>0 x(0<xa<δf(x)L<ϵ)  And what is the inverse proposition of this statement?

Propositional Normal Forms:
ENGCHNDenote
Maxterm极大项 M = a 1 ∨ a 2 ∨ ⋯ ∧ a i ∨ ⋯ M=a_1 \lor a_2 \lor \cdots \land a_i \lor \cdots M=a1a2ai
(there exists unique value of each a i a_i ai so that M = 0 M=0 M=0)
Minterm极小项 m = b 1 ∧ b 2 ∧ ⋯ ∧ b i ∧ ⋯ m=b_1 \land b_2 \land \cdots \land b_i \land \cdots m=b1b2bi
(there exists unique value of each b i b_i bi so that m = 1 m=1 m=1)
Conjunctive Normal Form (CNF)合取范式 C = A 1 ∧ A 2 ∧ ⋯ ∧ A i ∧ ⋯ C=A_1 \land A_2 \land \cdots \land A_i \land \cdots C=A1A2Ai, A i A_i Ai are propositions
Disjunctive Normal Form (DNF)析取范式 D = B 1 ∨ B 2 ∨ ⋯ ∨ B i ∨ ⋯ D=B_1 \lor B_2 \lor \cdots \lor B_i \lor \cdots D=B1B2Bi, B i B_i Bi are propositions
Full Conjunctive Normal Form主合取范式 X = M 1 ∧ M 2 ∧ ⋯ ∧ M i ∧ ⋯ X=M_1 \land M_2 \land \cdots \land M_i \land \cdots X=M1M2Mi, M i M_i Mi are maxterms
Full Disjunctive Normal Form主析取范式 Y = m 1 ∨ m 2 ∨ ⋯ ∨ m i ∨ ⋯ Y=m_1 \lor m_2 \lor \cdots \lor m_i \lor \cdots Y=m1m2mi, m i m_i mi are minterms
Prenex Normal Form前约束范式 O = Q 1 z 1 Q 2 z 2 ⋯ Q n z n E O=Q_1z_1Q_2z_2 \cdots Q_nz_nE O=Q1z1Q2z2QnznE, Q i = ∀ Q_i=\forall Qi= or ∃ \exist ,
E E E is a quantifier-free proposition

 Transforming to Prenex Normal Form:
  1.eliminate → \to and ↔ \leftrightarrow by:
   p ↔ q ≡ ( p → q ) ∧ ( q → p ) ≡ ( ¬ p ∨ q ) ∧ ( ¬ q ∨ p ) ≡ ( p ∧ q ) ∨ ( ¬ p ∧ ¬ q ) p \leftrightarrow q \equiv (p \to q) \land (q \to p) \equiv (\neg p \lor q) \land (\neg q \lor p) \equiv (p \land q) \lor (\neg p \land \neg q) pq(pq)(qp)(¬pq)(¬qp)(pq)(¬p¬q)
  2.move all ¬ \neg ¬ inward by applying De Morgan’s Laws
  3.rename variables to avoid ambiguity if necessary
  4.move all quantifiers to the front by:
   Q x A ( x ) ∧ P ≡ Q x ( A ( x ) ∧ P ) Q xA(x) \land P \equiv Q x(A(x) \land P) QxA(x)PQx(A(x)P),
   Q x A ( x ) ∨ P ≡ Q x ( A ( x ) ∨ P ) Q xA(x) \lor P \equiv Q x(A(x) \lor P) QxA(x)PQx(A(x)P),
   Q ′ x A ( x ) ∧ Q ′ ′ y B ( y ) ≡ Q ′ x Q ′ ′ y ( A ( x ) ∧ B ( y ) ) Q'xA(x) \land Q''yB(y) \equiv Q'xQ''y(A(x) \land B(y)) QxA(x)QyB(y)QxQy(A(x)B(y)),
   Q ′ x A ( x ) ∨ Q ′ ′ y B ( y ) ≡ Q ′ x Q ′ ′ y ( A ( x ) ∨ B ( y ) ) Q'xA(x) \lor Q''yB(y) \equiv Q'xQ''y(A(x) \lor B(y)) QxA(x)QyB(y)QxQy(A(x)B(y)),
   Q x Q y C ( x , y ) ≡ Q y Q x C ( x , y ) QxQyC(x,y) \equiv QyQxC(x,y) QxQyC(x,y)QyQxC(x,y),
  where we have:
   Q , Q ′ , Q ′ ′ = ∀ Q,Q',Q''=\forall Q,Q,Q= or ∃ \exist ,
   P P P is a quantifier-free proposition,
   A ( x ) , B ( y ) , C ( x , y ) A(x),B(y),C(x,y) A(x),B(y),C(x,y) are propositions.
 *5.transform to Prenex CNF/DNF

Rules of Inference:
RuleTautologyENGCHN
p p → q ∴    q \begin{aligned} &p \\ &p \to q \\ \hline \therefore \; &q \end{aligned} ppqq ( p ∧ ( p → q ) ) → q (p \land (p \to q)) \to q (p(pq))qModus ponens假言推理式
¬ q p → q ∴    ¬ p \begin{aligned} &\neg q \\ &p \to q \\ \hline \therefore \; &\neg p \end{aligned} ¬qpq¬p ( ¬ q ∧ ( p → q ) ) → ¬ p (\neg q \land (p \to q)) \to \neg p (¬q(pq))¬pModus tollens否定拒取式
p → q q → r ∴    p → r \begin{aligned}&p \to q \\ &q \to r \\ \hline \therefore \; &p \to r \end{aligned} pqqrpr ( ( p → q ) ∧ ( q → r ) ) → ( p → r ) ((p \to q) \land (q \to r)) \to (p \to r) ((pq)(qr))(pr)Hypothetical syllogism假言三段论
p ∨ q ¬ p ∴    q \begin{aligned}&p \lor q \\ &\neg p\\ \hline \therefore \; &q \end{aligned} pq¬pq ( ( p ∨ q ) ∧ ¬ p ) → q ((p \lor q) \land \neg p) \to q ((pq)¬p)qDisjunctive syllogism析取三段论
p ∴    p ∨ q \begin{aligned}&p \\ \hline \therefore \; &p \lor q \end{aligned} ppq p → ( p ∨ q ) p \to (p \lor q) p(pq)Addition附加律
p ∧ q ∴    q \begin{aligned}&p \land q \\ \hline \therefore \; &q \end{aligned} pqq ( p ∧ q ) → q (p \land q) \to q (pq)qSimplification消去律
p q ∴    p ∧ q \begin{aligned}&p \\ &q \\ \hline \therefore \; &p \land q \end{aligned} pqpq ( ( p ) ∧ ( q ) ) → ( p ∧ q ) ((p) \land (q)) \to (p \land q) ((p)(q))(pq)Conjunction合取式
p ∨ q ¬ p ∨ r ∴    q ∨ r \begin{aligned}&p \lor q \\ &\neg p \lor r \\ \hline \therefore \; &q \lor r \end{aligned} pq¬prqr ( ( p ∨ q ) ∧ ( ¬ p ∨ r ) ) → ( q ∨ r ) ((p \lor q) \land (\neg p \lor r)) \to (q \lor r) ((pq)(¬pr))(qr)Resolution消解规则
p → r q → s p ∨ q ∴    r ∨ s \begin{aligned}&p \to r \\ &q \to s \\ &p \lor q \\ \hline \therefore \; &r \lor s \end{aligned} prqspqrs ( ( p → r ) ∧ ( q → r ) ∧ ( p ∨ q ) ) → ( r ∨ s ) ((p \to r) \land (q \to r) \land (p \lor q)) \to (r \lor s) ((pr)(qr)(pq))(rs)Constructive dilemma构造性两难

Remark: ( P 1 ∧ P 2 ∧ ⋯ ∧ P n ∧ P ) → Q ≡ ( P 1 ∧ P 2 ∧ ⋯ ∧ P n ) → ( P → Q ) (P_1 \land P_2 \land \cdots \land P_n \land P) \to Q \equiv (P_1 \land P_2 \land \cdots \land P_n) \to (P \to Q) (P1P2PnP)Q(P1P2Pn)(PQ)

RuleName
∀ x P ( x ) ∴    P ( c ) \begin{aligned}&\forall xP(x) \\ \hline \therefore \; &P(c) \end{aligned} xP(x)P(c) , for an arbitary c c cUniversal instantiation (UI)
P ( c ) ∴    ∀ x P ( x ) \begin{aligned}&P(c) \\ \hline \therefore \; &\forall xP(x) \end{aligned} P(c)xP(x) , for an arbitary c c cUniversal generalization (UG)
∃ x P ( x ) ∴    P ( c ) \begin{aligned}&\exist xP(x) \\ \hline \therefore \; &P(c) \end{aligned} xP(x)P(c) , for some element c c cExistential instantiation (EI)
P ( c ) ∴    ∃ x P ( x ) \begin{aligned}&P(c) \\ \hline \therefore \; &\exist xP(x) \end{aligned} P(c)xP(x) , for some element c c cExistential generalization (EG)

Remark: ∃ ! x    s . t .    P ( x )    ⟺    ∃ x ( P ( x ) ∧ ∀ y ( x ≠ y → ¬ P ( y ) ) ) \exist!x \; \mathrm{s.t.} \; P(x) \iff \exist x(P(x) \land \forall y(x \ne y \to \neg P(y))) !xs.t.P(x)x(P(x)y(x=y¬P(y)))

2. Basic Structures: Sets, Functions, Sequences, Sums, and Matrices

DenoteENG
N = { 0 , 1 , 2 , …   } \mathbb{N}=\{0, 1, 2, \dots\} N={0,1,2,}Natural numbers
Z = { … , − 1 , 0 , 1 , …   } \mathbb{Z}=\{\dots, -1, 0, 1, \dots\} Z={,1,0,1,}Intergers
Z + = { 1 , 2 , 3 , …   } \mathbb{Z^+}=\{1, 2, 3, \dots\} Z+={1,2,3,}Positive integers
Q = { p q   ∣   p ∈ Z + ∪ Z − , q ∈ Z } \mathbb{Q}=\left\{\dfrac{p}{q} \, \Big \vert \, p \in \mathbb{Z}^+ \cup \mathbb{Z}^-, q \in \mathbb{Z} \right\} Q={qppZ+Z,qZ}Rational numbers
R \mathbb{R} RReal numbers
R + \mathbb{R^+} R+Positve real numbers
C \mathbb{C} CComplex numbers
ENGCHNDenotei.e.
Subset子集 A ⊆ B A \subseteq B AB ∀ x ( x ∈ A → x ∈ B ) \forall x(x \in A \to x \in B) x(xAxB)
Proper subset真子集 A ⊂ B A \subset B AB ∀ x ( x ∈ A → x ∈ B ) ∧ ∃ x ( x ∈ B ∧ x ∉ A ) \forall x(x \in A \to x \in B) \land \exist x(x \in B \land x \notin A) x(xAxB)x(xBx/A)
Equal等集 A = B A=B A=B A ⊆ B ∧ B ⊆ A A \subseteq B \land B \subseteq A ABBA
∀ x ( x ∈ A ↔ x ∈ B ) \forall x(x \in A \leftrightarrow x \in B) x(xAxB)
Cardinality基数 ∣ S ∣ Card ⁡ ( S ) \vert S \vert \\ \operatorname{Card}(S) SCard(S) ∑ x ∈ S 1 \sum_{x \in S}1 xS1
Power set幂集 P ( S ) \mathcal{P}(S) P(S) ⋃ A ⊆ S { A } \bigcup_{A \subseteq S}\{A\} AS{A}

Remark: for every set S S S, we have ∅ ∈ S \varnothing \in S S and S ∈ S S \in S SS
Cartesian products(笛卡尔积):
A × B = { ( a , b )   ∣   a ∈ A ∧ b ∈ B } A \times B=\{(a,b) \, \vert \, a \in A \land b \in B\} A×B={(a,b)aAbB}
A 1 × A 2 × ⋯ × A n = { ( a 1 , a 2 , … , a n )   ∣   ∀ i ∈ { 1 , 2 , … , n } ( a i ∈ A n ) } A_1 \times A_2 \times \cdots \times A_n=\{(a_1, a_2, \dots, a_n) \, \vert \, \forall i \in \{1, 2, \dots, n\}(a_i \in A_n)\} A1×A2××An={(a1,a2,,an)i{1,2,,n}(aiAn)}

Set Operations:
OperationCHNDenotei.e.
Union并集 A ∪ B A \cup B AB { x   ∣   x ∈ A ∨ x ∈ B } \{x \, \vert \, x \in A \lor x \in B\} {xxAxB}
Intersection交集 A ∩ B A \cap B AB { x   ∣   x ∈ A ∧ x ∈ B } \{x \, \vert \, x \in A \land x \in B\} {xxAxB}
Complement补集 A ‾ \overline{A} A { x ∈ U   ∣   x ∉ A } \{x \in U \, \vert \, x \notin A\} {xUx/A}
Difference差集 A − B A ∖ B A - B \\ A \setminus B ABAB { x   ∣   x ∈ A ∧ x ∉ B } \{x \, \vert \, x \in A \land x \notin B\} {xxAx/B}

Remark:
A − B = A ∩ B ‾ A-B=A \cap \overline{B} AB=AB
A ∩ B = ∅    ⟺    A A \cap B=\varnothing \iff A AB=A and B B B are disjoint
Principle of Inclusion–Exclusion(容斥原理):
∣ A ∪ B ∣ = ∣ A ∣ + ∣ B ∣ − ∣ A ∩ B ∣ |A \cup B|=|A|+|B|-|A \cap B| AB=A+BAB
Symmetric difference(对称差):
A ⊕ B = ( A − B ) ∪ ( B − A ) = ( A ∪ B ) − ( A ∩ B ) A \oplus B=(A-B) \cup (B-A)=(A \cup B)-(A \cap B) AB=(AB)(BA)=(AB)(AB)

Set Identities:
IdentityENGCHN
A ∪ ∅ = A A ∩ U = A A \cup \varnothing = A \\ A \cap U =A A=AAU=AIdentity Laws同一律
A ∪ U = U A ∩ ∅ = ∅ A \cup U = U \\ A \cap \varnothing = \varnothing AU=UA=Domination Laws支配律
A ∪ A = A A ∩ A = A A \cup A = A \\ A \cap A = A AA=AAA=AIdempotent Laws幂等律
( A ‾ ) ‾ = A \overline{(\overline{A})}=A (A)=AComplementation Law双重互补律
A ∪ B = B ∪ A A ∩ B = B ∩ A A \cup B = B \cup A \\ A \cap B = B \cap A AB=BAAB=BAComutative Laws交换律
( A ∪ B ) ∪ C = A ∪ ( B ∪ C ) ( A ∩ B ) ∩ C = A ∩ ( B ∩ C ) (A \cup B) \cup C = A \cup (B \cup C) \\ (A \cap B) \cap C = A \cap (B \cap C) (AB)C=A(BC)(AB)C=A(BC)Associative Laws结合律
A ∪ ( B ∩ C ) = ( A ∪ B ) ∩ ( A ∪ C ) A ∩ ( B ∪ C ) = ( A ∩ B ) ∪ ( A ∩ C ) A \cup (B \cap C) = (A \cup B) \cap (A \cup C) \\ A \cap (B \cup C) = (A \cap B) \cup (A \cap C) A(BC)=(AB)(AC)A(BC)=(AB)(AC)Distributive Laws分配律
A ∩ B ‾ = A ‾ ∪ B ‾ A ∪ B ‾ = A ‾ ∩ B ‾ \overline{A \cap B} = \overline{A} \cup \overline{B} \\ \overline{A \cup B} = \overline{A} \cap \overline{B} AB=ABAB=ABDe Morgan’s Laws德摩根定律
A ∪ ( A ∩ B ) = A A ∩ ( A ∪ B ) = A A \cup (A \cap B) = A \\ A \cap (A \cup B) = A A(AB)=AA(AB)=AAbsorption Laws吸收律
A ∪ A ‾ = U A ∩ A ‾ = ∅ A \cup \overline{A} = U \\ A \cap \overline{A} = \varnothing AA=UAA=Complement Laws互补律
Functions:

 Let A , B ≠ ∅ A,B \ne \varnothing A,B=, we define a mapping f f f from A A A to B B B: f : A ↦ B f:A \mapsto B f:AB i.e. ∀ a ( a ∈ A → ∃ ! b ( b ∈ B ∧ f ( a ) = b ) ) \forall a(a \in A \to \exist !b(b \in B \land f(a)=b)) a(aA!b(bBf(a)=b))

DenoteENGCHN
A A Adomain定义域
B B Bcodomain上域
f ( A ) f(A) f(A)range值域
b b bimage
a a apreimage原像

Remark: f ( A ) = { f ( x )   ∣   ∀ x ∈ A } ⊆ B f(A)=\{f(x) \, \vert \, \forall x \in A\} \subseteq B f(A)={f(x)xA}B

ENGCHNDenote
Injective/
One-to-one
单射 ∀ a ∈ A   ∀ b ∈ A ( f ( a ) = f ( b ) → a = b )    ⟺    ∀ a ∈ A   ∀ b ∈ A ( a ≠ b → f ( a ) ≠ f ( b ) ) \forall a \in A \ \forall b \in A(f(a)=f(b) \to a=b) \\ \iff \forall a \in A \ \forall b \in A(a \ne b \to f(a) \ne f(b)) aA bA(f(a)=f(b)a=b)aA bA(a=bf(a)=f(b))
Surjective/
Onto
满射 ∀ b ∈ B   ∃ a ∈ A ( f ( a ) = b ) \forall b \in B \ \exist a \in A(f(a)=b) bB aA(f(a)=b)
Bijective/
One-to-one correspondent
双射both injective and surjective
(strictly) Increasing(严格)单调递增 ∀ x ∈ D   ∀ y ∈ D ( x < y → f ( x ) ≤ f ( y ) ) ∀ x ∈ D   ∀ y ∈ D ( x < y → f ( x ) < f ( y ) ) \forall x \in D \ \forall y \in D(x < y \to f(x) \leq f(y)) \\ \forall x \in D \ \forall y \in D(x < y \to f(x) < f(y)) xD yD(x<yf(x)f(y))xD yD(x<yf(x)<f(y))
(strictly) Decreasing(严格)单调递减 ∀ x ∈ D   ∀ y ∈ D ( x < y → f ( x ) ≥ f ( y ) ) ∀ x ∈ D   ∀ y ∈ D ( x < y → f ( x ) > f ( y ) ) \forall x \in D \ \forall y \in D(x < y \to f(x) \ge f(y)) \\ \forall x \in D \ \forall y \in D(x < y \to f(x) > f(y)) xD yD(x<yf(x)f(y))xD yD(x<yf(x)>f(y))
Inverse function反函数 ∀ y ∈ B , ∃ ! x ∈ A   s . t . f ( x ) = y    ⟺    f − 1 ( y ) = x \forall y \in B , \exist !x \in A \ \mathrm{s.t.} f(x)=y \\ \iff f^{-1}(y)=x yB,!xA s.t.f(x)=yf1(y)=x

Remark: f : A ↦ B f:A \mapsto B f:AB is a bijection ⟹ ∣ A ∣ = ∣ B ∣ \Longrightarrow \vert A \vert = \vert B \vert A=B
Addition of Functions:
( f + g ) ( x ) = f ( x ) + g ( x ) (f+g)(x)=f(x)+g(x) (f+g)(x)=f(x)+g(x)
Mutiplication of Functions:
( f ⋅ g ) ( x ) = f ( x ) ⋅ g ( x ) (f \cdot g)(x)=f(x) \cdot g(x) (fg)(x)=f(x)g(x)
Composition of Functions:
( f ∘ g ) ( x ) = f ( g ( x ) ) (f \circ g)(x)=f(g(x)) (fg)(x)=f(g(x))
 Useful properties of Floor Function f ( x ) = ⌊ x ⌋ f(x)=\lfloor x \rfloor f(x)=x and Ceiling Function g ( x ) = ⌈ x ⌉ g(x)=\lceil x \rceil g(x)=x:
⌊ − x ⌋ = − ⌈ x ⌉ \lfloor -x \rfloor =- \lceil x \rceil x=x , ⌈ − x ⌉ = − ⌊ x ⌋ \lceil -x \rceil =- \lfloor x \rfloor x=x
x − 1 < ⌊ x ⌋ ≤ x ≤ ⌈ x ⌉ < x + 1 x-1<\lfloor x \rfloor \leq x \leq \lceil x \rceil <x+1 x1<xxx<x+1

Useful Summation Formulea:
SumClosed Form
∑ k = 0 n a r k , r ≠ 0 , 1 \sum\limits_{k=0}^{n}{ar^k},r \ne 0,1 k=0nark,r=0,1 a ( 1 − r n + 1 ) 1 − r \dfrac{a(1-r^{n+1})}{1-r} 1ra(1rn+1)
∑ k = 1 n k \sum\limits_{k=1}^{n}{k} k=1nk n ( n + 1 ) 2 \dfrac{n(n+1)}{2} 2n(n+1)
∑ k = 1 n k 2 \sum\limits_{k=1}^{n}{k^2} k=1nk2 n ( n + 1 ) ( 2 n + 1 ) 6 \dfrac{n(n+1)(2n+1)}{6} 6n(n+1)(2n+1)
∑ k = 1 n k 3 \sum\limits_{k=1}^{n}{k^3} k=1nk3 n 2 ( n + 1 ) 2 4 \dfrac{n^2(n+1)^2}{4} 4n2(n+1)2
∑ k = 0 ∞ x k , ∣ x ∣ < 1 \sum\limits_{k=0}^{\infty}{x^k},\vert x \vert <1 k=0xk,x<1 1 1 − x \dfrac{1}{1-x} 1x1
∑ k = 1 ∞ k x k − 1 , ∣ x ∣ < 1 \sum\limits_{k=1}^{\infty}{kx^{k-1}},\vert x \vert <1 k=1kxk1,x<1 1 ( 1 − x ) 2 \dfrac{1}{(1-x)^2} (1x)21
Cardinality of infinite sets:

Definition: infinite set A A A is countable    ⟺    ∣ A ∣ = ∣ Z + ∣ = ℵ 0 \iff |A|=|\mathbb{Z}^+|=\aleph_0 A=Z+=0
Remark:
   ∣ Q + ∣ = ∣ Z + × Z + ∣ = ℵ 0 ⟸ ∣ Q + ∣ ≤ ∣ Z + × Z + ∣ = ∣ Z + ∣ ≤ ∣ Q + ∣ |\mathbb{Q}^+|=|\mathbb{Z}^+\times\mathbb{Z}^+|=\aleph_0 \Longleftarrow|\mathbb{Q}^+|\leq|\mathbb{Z}^+\times\mathbb{Z}^+|=|\mathbb{Z}^+|\leq|\mathbb{Q}^+| Q+=Z+×Z+=0Q+Z+×Z+=Z+Q+
   ∣ R ∣ = ∣ ( 0 , 1 ) ∣ = ℵ 1 ⟸ f : ( − π 2 , π 2 ) ↦ R , f ( x ) = tan ⁡ ( x π + 1 2 ) |\mathbb{R}|=|(0,1)|=\aleph_1\Longleftarrow f:(-\frac{\pi}{2},\frac{\pi}{2}) \mapsto \mathbb{R},f(x)=\tan(\frac{x}{\pi}+\frac12) R=(0,1)=1f:(2π,2π)R,f(x)=tan(πx+21)
   ∣ [ 0 , 1 ] ∣ = ∣ ( 0 , 1 ) ∣ = ℵ 1 ⟸ ∣ ( 0 , 1 ) ∣ ≤ ∣ [ 0 , 1 ] ∣ = ∣ [ 1 4 , 3 4 ] ∣ ≤ ∣ ( 0 , 1 ) ∣ |[0,1]|=|(0,1)|=\aleph_1 \Longleftarrow |(0,1)|\leq|[0,1]|=|[\frac14,\frac34]|\leq|(0,1)| [0,1]=(0,1)=1(0,1)[0,1]=[41,43](0,1)

Cantor’s Theorem(康托尔定理) and proof: ∣ P ( A ) ∣ > ∣ A ∣ |\mathcal{P}(A)|>|A| P(A)>A
  Let f : A ↦ P ( A ) f:A \mapsto \mathcal{P}(A) f:AP(A) be an arbitary function.
  Consider B = { x ∈ A : x ∉ f ( x ) } B=\{x \in A : x \notin f(x)\} B={xA:x/f(x)}.
  Assume that there exists y ∈ A y \in A yA so that f ( y ) = B f(y)=B f(y)=B.
  If y ∈ B y \in B yB then y ∈ f ( y ) y \in f(y) yf(y), conflicting with the definition of B B B.
  If y ∉ B y \notin B y/B then y ∉ f ( y ) y \notin f(y) y/f(y), so we have y ∈ B y \in B yB conflicting with y ∉ B y \notin B y/B.
  Thus there is no such y y y, showing B ∈ P ( A ) B \in \mathcal{P}(A) BP(A) does not have preimage in A A A.
  Hence, f f f is not a surjection.
   Q . E . D . \mathrm{Q.E.D.} Q.E.D.
Schrőder-Bernstein Theorem(伯恩斯坦定理): ∣ A ∣ ≤ ∣ B ∣ ∧ ∣ B ∣ ≤ ∣ A ∣ ⟺ ∣ A ∣ = ∣ B ∣ |A|\leq|B|\land|B|\leq|A| \Longleftrightarrow |A|=|B| ABBAA=B
The Continuum Hypothesis(连续统假设): ∄ a   s . t .   ℵ 0 < a < ℵ 1 \not\exists a \ \mathrm{s.t.} \ \aleph_0<a<\aleph_1 a s.t. 0<a<1

6. Counting

The Generalized Pigeonhole Principle(鸽巢原理/抽屉原理):
  If N N N objects are placed into k k k boxes, then there is at least one box containing at least ⌈ N k ⌉ \lceil \frac{N}{k} \rceil kN objects.

Permutations and Combinations:

P ( n , r ) = n ( n − 1 ) ( n − 2 ) ⋯ ( n − r + 1 ) = n ! ( n − r ) ! P(n,r)=n(n-1)(n-2)\cdots(n-r+1)=\dfrac{n!}{(n-r)!} P(n,r)=n(n1)(n2)(nr+1)=(nr)!n!
C ( n , r ) = ( n r ) = P ( n , r ) r ! = n ( n − 1 ) ( n − 2 ) ⋯ ( n − r + 1 ) r ! = n ! r ! ( n − r ) ! C(n,r)=\dbinom{n}{r}=\dfrac{P(n,r)}{r!}=\dfrac{n(n-1)(n-2)\cdots(n-r+1)}{r!}=\dfrac{n!}{r!(n-r)!} C(n,r)=(rn)=r!P(n,r)=r!n(n1)(n2)(nr+1)=r!(nr)!n!
Remark: ( n r ) = ( n n − r ) \dbinom{n}{r}=\dbinom{n}{n-r} (rn)=(nrn)
The Binomial Theorem(二项式定理): ( x + y ) n = ∑ k = 0 n ( n k ) x n − k y k (x+y)^n=\sum\limits_{k=0}^{n}{\dbinom{n}{k}x^{n-k}y^k} (x+y)n=k=0n(kn)xnkyk
   ∑ k = 0 n ( n k ) = 2 n ⟸ x = y = 1 \sum\limits_{k=0}^{n}{\dbinom{n}{k}}=2^n \Longleftarrow x=y=1 k=0n(kn)=2nx=y=1
   ∑ k = 0 n ( − 1 ) k ( n k ) = 0 ⟸ x = − y = 1 \sum\limits_{k=0}^{n}{(-1)^k\dbinom{n}{k}}=0 \Longleftarrow x=-y=1 k=0n(1)k(kn)=0x=y=1
   ∑ k = 0 n 2 k ( n k ) = 3 n ⟸ x + 1 = y = 2 \sum\limits_{k=0}^{n}{2^k\dbinom{n}{k}}=3^n \Longleftarrow x+1=y=2 k=0n2k(kn)=3nx+1=y=2
Pascal’s Identity: ( n + 1 k ) = ( n k ) + ( n k − 1 ) \dbinom{n+1}{k}=\dbinom{n}{k}+\dbinom{n}{k-1} (kn+1)=(kn)+(k1n)
Vandermonde’s Identity and proof: ( m + n r ) = ∑ k = 0 r ( m r − k ) ( n k ) \dbinom{m+n}{r}=\sum\limits_{k=0}^r{\dbinom{m}{r-k}\dbinom{n}{k}} (rm+n)=k=0r(rkm)(kn)
   ( x + y ) m + n = ⋯ + ( m + n r ) x m + n − r y r + ⋯ (x+y)^{m+n}=\cdots+\dbinom{m+n}{r}x^{m+n-r}y^r+\cdots (x+y)m+n=+(rm+n)xm+nryr+
   ( x + y ) m ( x + y ) n = ⋯ + ( ∑ k = 0 r ( m r − k ) x m − r + k y r − k ) ( ∑ k = 0 n ( n k ) x n − k y k ) + ⋯ = ⋯ + ∑ k = 0 r ( ( m r − k ) x m − r + k y r − k ⋅ ( n k ) x n − k y k ) + ⋯ = ⋯ + ∑ k = 0 r ( m r − k ) ( n k ) x m + n − r y r + ⋯ \begin{aligned}(x+y)^m(x+y)^n&=\cdots+\left(\sum\limits_{k=0}^{r}{\dbinom{m}{r-k}x^{m-r+k}y^{r-k}}\right)\left(\sum\limits_{k=0}^{n}{\dbinom{n}{k}x^{n-k}y^k}\right)+\cdots \\ &=\cdots+\sum\limits_{k=0}^{r}{\left(\dbinom{m}{r-k}x^{m-r+k}y^{r-k}\cdot\dbinom{n}{k}x^{n-k}y^k\right)}+\cdots \\ &=\cdots+\sum\limits_{k=0}^{r}{\dbinom{m}{r-k}\dbinom{n}{k}x^{m+n-r}y^r}+\cdots\end{aligned} (x+y)m(x+y)n=+(k=0r(rkm)xmr+kyrk)(k=0n(kn)xnkyk)+=+k=0r((rkm)xmr+kyrk(kn)xnkyk)+=+k=0r(rkm)(kn)xm+nryr+
  Corollary: ( 2 n n ) = ∑ k = 0 n ( n n − k ) ( n k ) = ∑ k = 0 n ( n k ) 2 ⟸ m = r = n \dbinom{2n}{n}=\sum\limits_{k=0}^{n}{\dbinom{n}{n-k}\dbinom{n}{k}}=\sum\limits_{k=0}^{n}{\dbinom{n}{k}^2} \Longleftarrow m=r=n (n2n)=k=0n(nkn)(kn)=k=0n(kn)2m=r=n
Remark: ( n + 1 r + 1 ) = ∑ k = r n ( k r ) \dbinom{n+1}{r+1}=\sum\limits_{k=r}^{n}{\dbinom{k}{r}} (r+1n+1)=k=rn(rk)
   ( n + 1 r + 1 ) = ( n r + 1 ) + ( n r ) = ( n − 1 r + 1 ) + ( n − 1 r ) + ( n r ) = ⋯ = ( r + 1 r + 1 ) + ∑ k = r + 1 n ( k r ) = ( r r ) + ∑ k = r + 1 n ( k r ) = ∑ k = r n ( k r ) \begin{aligned}\dbinom{n+1}{r+1}&=\dbinom{n}{r+1}+\dbinom{n}{r}=\dbinom{n-1}{r+1}+\dbinom{n-1}{r}+\dbinom{n}{r}=\cdots \\ &=\dbinom{r+1}{r+1}+\sum\limits_{k=r+1}^{n}{\dbinom{k}{r}}=\dbinom{r}{r}+\sum\limits_{k=r+1}^{n}{\dbinom{k}{r}}=\sum\limits_{k=r}^{n}{\dbinom{k}{r}}\end{aligned} (r+1n+1)=(r+1n)+(rn)=(r+1n1)+(rn1)+(rn)==(r+1r+1)+k=r+1n(rk)=(rr)+k=r+1n(rk)=k=rn(rk)

Stirling Number(II):

n n n distinguishable objects into k k k indistinguishable boxes: ∑ j = 1 k S ( n , j ) = ∑ j = 1 k [ 1 j ! ∑ i = 0 j − 1 ( − 1 ) i ( j i ) ( j − i ) n ] \sum\limits_{j=1}^{k}{S(n, j)}=\sum\limits_{j=1}^{k}{\left[\dfrac{1}{j!}\sum\limits_{i=0}^{j-1}{(-1)^i\dbinom{j}{i}(j-i)^n}\right]} j=1kS(n,j)=j=1k[j!1i=0j1(1)i(ij)(ji)n]

8. Advanced Counting Techniques

Solving Linear Recurrence Relations:

a n = c 1 a n − 1 + c 2 a n − 2 + ⋯ + c k a n − k + F ( n ) a_n=c_1a_{n-1}+c_2a_{n-2}+\cdots+c_ka_{n-k}+F(n) an=c1an1+c2an2++ckank+F(n), F ( n ) = ( b t n t + b t − 1 n t − 1 + ⋯ + b 1 n + b 0 ) s n F(n)=(b_tn^t+b_{t-1}n^{t-1}+\cdots+b_1n+b_0)s^n F(n)=(btnt+bt1nt1++b1n+b0)sn.
 Let the form of general solutions be a n ( p ) + a n ( h ) a_n^{(p)}+a_n^{(h)} an(p)+an(h)
a n ( h ) a_n^{(h)} an(h) is the solution of homogeneous equation a n = c 1 a n − 1 + c 2 a n − 2 + ⋯ + c k a n − k a_n=c_1a_{n-1}+c_2a_{n-2}+\cdots+c_ka_{n-k} an=c1an1+c2an2++ckank
 Assume that s s s is a root of multiplicity m m m of the equation
 Then a n ( p ) a_n^{(p)} an(p)is the form as n m ( d t n t + d t − 1 n t − 1 + ⋯ + d 1 n + d 0 ) s n n^m(d_tn^t+d_{t-1}n^{t-1}+\cdots+d_1n+d_0)s^n nm(dtnt+dt1nt1++d1n+d0)sn.
 Particularly, when s s s is not a root of the homogeneous equation, m = 0 m=0 m=0.
 Now we can solve the coefficients e i e_i ei of a n = e 1 x 1 n + e 2 x 2 n + ⋯ + e k x k n + a n ( p ) a_n=e_1x_1^n+e_2x_2^n+\cdots+e_kx_k^n+a_n^{(p)} an=e1x1n+e2x2n++ekxkn+an(p).
 If x i x_i xi is of multiplicity l l l, the form is as ( e i n l + e i + 1 n l − 1 + ⋯ + e i + l − 2 n + e i + l − 1 ) x i n (e_in^l+e_{i+1}n^{l-1}+\cdots+e_{i+l-2}n+e_{i+l-1})x_i^n (einl+ei+1nl1++ei+l2n+ei+l1)xin.

Generating Functions:

G ( x ) = a 0 + a 1 x + a 2 x 2 + ⋯ + a n x n + ⋯ = ∑ k = 0 ∞ a k x k G(x)=a_0+a_1x+a_2x^2+\cdots+a_nx^n+\cdots=\sum\limits_{k=0}^{\infty}{a_kx^k} G(x)=a0+a1x+a2x2++anxn+=k=0akxk
Remark:
   f ( x ) + g ( x ) = ∑ k = 0 ∞ ( a k + b k ) x k f(x)+g(x)=\sum\limits_{k=0}^{\infty}{(a_k+b_k)x^k} f(x)+g(x)=k=0(ak+bk)xk
   α ⋅ f ( x ) = ∑ k = 0 ∞ α ⋅ a k x k \alpha \cdot f(x)=\sum\limits_{k=0}^{\infty}{\alpha \cdot a_kx^k} αf(x)=k=0αakxk
   x ⋅ f ′ ( x ) = ∑ k = 0 ∞ k ⋅ a k x k x \cdot f'(x)=\sum\limits_{k=0}^{\infty}{k \cdot a_kx^k} xf(x)=k=0kakxk
   f ( α x ) = ∑ k = 0 ∞ α k ⋅ a k x k f(\alpha x)=\sum\limits_{k=0}^{\infty}{\alpha^k \cdot a_kx^k} f(αx)=k=0αkakxk
   f ( x ) g ( x ) = ∑ k = 0 ∞ ( ∑ j = 0 k a j b k − j ) x k f(x)g(x)=\sum\limits_{k=0}^{\infty}{(\sum\limits_{j=0}^{k}{a_jb_{k-j}})x^k} f(x)g(x)=k=0(j=0kajbkj)xk
eg.
   b k = ∑ i = 0 k a i b_k=\sum\limits_{i=0}^{k}{a_i} bk=i=0kai
   ⟹ F ( x ) = ∑ k = 0 ∞ b k x k = ∑ k = 0 ∞ ( ∑ i = 0 k a i ⋅ 1 ) x k = G ( x ) ⋅ 1 1 − x \Longrightarrow F(x)=\sum\limits_{k=0}^{\infty}{b_kx^k}=\sum\limits_{k=0}^{\infty}{\left(\sum\limits_{i=0}^{k}{a_i \cdot 1}\right)x^k}=G(x) \cdot \dfrac{1}{1-x} F(x)=k=0bkxk=k=0(i=0kai1)xk=G(x)1x1
   a k = k 2 a_k=k^2 ak=k2
   ⟹ G ( x ) = ∑ k = 0 ∞ k 2 x k = x ( ∑ k = 0 ∞ k x k ) ′ = x [ x ( ∑ k = 0 ∞ x k ) ′ ] ′ = x [ x ( 1 1 − x ) ′ ] ′ = x ( 1 + x ) ( 1 − x ) 3 \Longrightarrow G(x)=\sum\limits_{k=0}^{\infty}{k^2x^k}=x\left(\sum\limits_{k=0}^{\infty}{kx^k}\right)'=x\left[x\left(\sum\limits_{k=0}^{\infty}{x^k}\right)'\right]'=x\left[x\left(\dfrac{1}{1-x}\right)'\right]'=\dfrac{x(1+x)}{(1-x)^3} G(x)=k=0k2xk=x(k=0kxk)=x[x(k=0xk)]=x[x(1x1)]=(1x)3x(1+x)
   a k = ∑ i = 0 k i 2 a_k=\sum\limits_{i=0}^{k}{i^2} ak=i=0ki2
   ⟹ G ( x ) = ∑ k = 0 ∞ ( ∑ i = 0 k i 2 ⋅ 1 ) x k = x ( 1 + x ) ( 1 − x ) 3 ⋅ 1 1 − x = x ( 1 + x ) ( 1 − x ) 4 \Longrightarrow G(x)=\sum\limits_{k=0}^{\infty}{(\sum\limits_{i=0}^{k}{i^2 \cdot 1})x^k}=\dfrac{x(1+x)}{(1-x)^3} \cdot \dfrac{1}{1-x}=\dfrac{x(1+x)}{(1-x)^4} G(x)=k=0(i=0ki21)xk=(1x)3x(1+x)1x1=(1x)4x(1+x)
   f ( x ) = 1 1 − 4 x 2 = 1 ( 1 − 2 x ) ( 1 + 2 x ) = 1 2 ( 1 1 − 2 x + 1 1 + 2 x ) = ∑ k = 0 ∞ a k x k f(x)=\dfrac{1}{1-4x^2}=\dfrac{1}{(1-2x)(1+2x)}=\dfrac12\left(\dfrac{1}{1-2x}+\dfrac{1}{1+2x}\right)=\sum\limits_{k=0}^{\infty}{a_kx^k} f(x)=14x21=(12x)(1+2x)1=21(12x1+1+2x1)=k=0akxk
   ⟹ a k = 2 k + ( − 2 ) k 2 \Longrightarrow a_k=\dfrac{2^k+(-2)^k}{2} ak=22k+(2)k
The Extended Binomial Therom:
   ( 1 + x ) u = ∑ k = 0 ∞ ( u k ) x k , ∣ x ∣ < 1 , u ∈ R (1+x)^u=\sum\limits_{k=0}^{\infty}{\dbinom{u}{k}x^k},|x|<1,u \in \mathbb{R} (1+x)u=k=0(ku)xk,x<1,uR
  Collary:
   ( 1 + x ) − n = ∑ k = 0 ∞ ( − n k ) x k = ∑ k = 0 ∞ ( − 1 ) k ( n + k − 1 k ) x k (1+x)^{-n}=\sum\limits_{k=0}^{\infty}{\dbinom{-n}{k}x^k}=\sum\limits_{k=0}^{\infty}{(-1)^k\dbinom{n+k-1}{k}x^k} (1+x)n=k=0(kn)xk=k=0(1)k(kn+k1)xk
   ( 1 − x ) − n = ∑ k = 0 ∞ ( − n k ) ( − x ) k = ∑ k = 0 ∞ ( n + k − 1 k ) x k (1-x)^{-n}=\sum\limits_{k=0}^{\infty}{\dbinom{-n}{k}(-x)^k}=\sum\limits_{k=0}^{\infty}{\dbinom{n+k-1}{k}x^k} (1x)n=k=0(kn)(x)k=k=0(kn+k1)xk

Generating Functions of Common Sequences:
SequenceGenerating Function
1 1 1 1 1 − x \dfrac{1}{1-x} 1x1
α k \alpha^k αk 1 1 − α x \dfrac{1}{1-\alpha x} 1αx1
k + 1 k+1 k+1 1 ( 1 − x ) 2 \dfrac{1}{(1-x)^2} (1x)21
( n k ) \dbinom{n}{k} (kn) ( 1 + x ) n (1+x)^n (1+x)n
( n k ) α k \dbinom{n}{k} \alpha^k (kn)αk ( 1 + α x ) n (1+\alpha x)^n (1+αx)n
( n + k − 1 k ) \dbinom{n+k-1}{k} (kn+k1) ( 1 − x ) − n (1-x)^{-n} (1x)n
( − 1 ) k ( n + k − 1 k ) (-1)^k\dbinom{n+k-1}{k} (1)k(kn+k1) ( 1 + x ) − n (1+x)^{-n} (1+x)n
1 k ! \dfrac{1}{k!} k!1 e x e^x ex
( − 1 ) k + 1 k ! \dfrac{(-1)^{k+1}}{k!} k!(1)k+1 ln ⁡ ( 1 + x ) \ln(1+x) ln(1+x)

9. Relations

Definition: A binary relation R R R from set A A A to set B B B is a subset of A × B A \times B A×B.
Remark: R = { ( a , b )   ∣   a ∈ A ∧ b ∈ B ∧ a R b } ⊆ A × B R=\{(a,b) \, | \, a \in A \land b \in B \land aRb\} \subseteq A \times B R={(a,b)aAbBaRb}A×B
Definition: A relation on set A A A is a binary relation from set A A A to set A A A.
eg. How many binary relations are there on a set A A A with n n n elements?
   ∣ A ∣ = n ⟹ ∣ A × A ∣ = n ⋅ n = n 2 ⟹ ∣ R ∣ = 2 n 2 |A|=n \Longrightarrow |A \times A|=n \cdot n=n^2 \Longrightarrow |R|=2^{n^2} A=nA×A=nn=n2R=2n2

Connection Matrices

 Let R R R be a relation from A = { a 1 , a 2 , … , a n } A=\{a_1, a_2, \dots , a_n\} A={a1,a2,,an} to B = { b 1 , b 2 , … , b m } B=\{b_1, b_2, \dots , b_m\} B={b1,b2,,bm}.
 The n × m n \times m n×m connection matrix M R = [ m i j ] M_R=[m_{ij}] MR=[mij] for R R R is defined by:
m i j = { 1 , ( a i , b j ) ∈ R 0 , ( a i , b j ) ∉ R m_{ij}=\begin{cases} 1, (a_i, b_j) \in R \\ 0, (a_i, b_j) \notin R \end{cases} mij={1,(ai,bj)R0,(ai,bj)/R

Special Properties of Binary Relations
TypeCHNDenote
Reflexive自反性 ∀ x ( x ∈ A → ( x , x ) ∈ R ) \forall x(x \in A \to (x,x) \in R) x(xA(x,x)R)
Irreflexive非自反性 ∀ x ( x ∈ A → ( x , x ) ∉ R ) \forall x(x \in A \to (x,x) \notin R) x(xA(x,x)/R)
Symmetric对称性 ∀ x ∀ y ( ( x , y ) ∈ R → ( y , x ) ∈ R ) \forall x \forall y((x,y) \in R \to (y,x) \in R) xy((x,y)R(y,x)R)
Antisymmetric反对称性 ∀ x ∀ y ( ( x , y ) ∈ R ∧ ( y , x ) ∈ R → x = y ) \forall x \forall y((x,y) \in R \land (y,x) \in R \to x=y) xy((x,y)R(y,x)Rx=y)
∀ x ∀ y ( ( x , y ) ∈ R ∧ x ≠ y → ( y , x ) ∉ R ) \forall x \forall y((x,y) \in R \land x \neq y \to (y,x) \notin R) xy((x,y)Rx=y(y,x)/R)
Asymmetric非对称性 ∀ x ∀ y ( x ≠ y → ( x , y ) ∈ R ∧ ( y , x ) ∉ R ∨ ( x , y ) ∉ R ∧ ( y , x ) ∈ R ) \forall x \forall y(x \neq y \to (x,y) \in R \land (y,x) \notin R \lor (x,y) \notin R \land (y,x) \in R) xy(x=y(x,y)R(y,x)/R(x,y)/R(y,x)R)
Transitive传递性 ∀ x ∀ y ∀ z ( ( x , y ) ∈ R ∧ ( y , z ) ∈ R → ( x , z ) ∈ R ) \forall x \forall y \forall z((x,y) \in R \land (y,z) \in R \to (x,z) \in R) xyz((x,y)R(y,z)R(x,z)R)

Remark: ( m i j ∧ m j k ) ‾ ∨ m i k = 1 \overline{(m_{ij} \land m_{jk})} \lor m_{ik}=1 (mijmjk)mik=1
eg.
  How many relations on a set with n n n elements that are reflexive? 2 n 2 − n 2^{n^2-n} 2n2n
  How many relations on a set with n n n elements that are symmetric? 2 n ⋅ 2 n 2 − n 2 = 2 n 2 + n 2 2^n \cdot 2^\frac{n^2-n}{2}=2^\frac{n^2+n}{2} 2n22n2n=22n2+n
  How many relations on a set with n n n elements that are antisymmetric? 2 n ⋅ 3 n 2 − n 2 2^n \cdot 3^\frac{n^2-n}{2} 2n32n2n
  How many relations on a set with n n n elements that are reflexive and symmetric? 2 n 2 − n 2 2^\frac{n^2-n}{2} 22n2n
  How many relations on a set with n n n elements that are transitive? ∑ j = 1 n S ( n , j ) \sum\limits_{j=1}^{n}{S(n,j)} j=1nS(n,j)

Combining Relations

 Let A = { a 1 , a 2 , … , a n } A=\{a_1, a_2, \dots , a_n\} A={a1,a2,,an}, B = { b 1 , b 2 , … , b m } B=\{b_1, b_2, \dots , b_m\} B={b1,b2,,bm}, M R 1 = [ c i j ] M_{R_1}=[c_{ij}] MR1=[cij], M R 2 = [ d i j ] M_{R_2}=[d_{ij}] MR2=[dij].

OperationDenote
R 1 ∪ R 2 R_1 \cup R_2 R1R2 M R 1 ∪ R 2 = [ c i j ∨ d i j ] M_{R_1 \cup R_2}=[c_{ij} \lor d_{ij}] MR1R2=[cijdij]
R 1 ∩ R 2 R_1 \cap R_2 R1R2 M R 1 ∩ R 2 = [ c i j ∧ d i j ] M_{R_1 \cap R_2}=[c_{ij} \land d_{ij}] MR1R2=[cijdij]
R 1 ‾ \overline{R_1} R1 M R 1 ‾ = [ c i j ‾ ] M_{\overline{R_1}}=[\overline{c_{ij}}] MR1=[cij]
R 1 − R 2 R_1-R_2 R1R2
R 1 ∩ R 2 ‾ R_1 \cap \overline{R_2} R1R2
M R 1 − R 2 = M R 1 ∩ R 2 ‾ = [ c i j ∧ d i j ‾ ] M_{R_1-R_2}=M_{R_1 \cap \overline{R_2}}=[c_{ij} \land \overline{d_{ij}}] MR1R2=MR1R2=[cijdij]

 Let R = { ( a , b )   ∣   a ∈ A ∧ b ∈ B ∧ a R b } R=\{(a,b) \, | \, a \in A \land b \in B \land aRb\} R={(a,b)aAbBaRb}, S = { ( b , c )   ∣   b ∈ B ∧ c ∈ C ∧ b S c } S=\{(b,c) \, | \, b \in B \land c \in C \land bSc\} S={(b,c)bBcCbSc}.
 The composition of R R R and S S S: S ∘ R = { ( a , c )   ∣   a ∈ A ∧ c ∈ C ∧ ∃ b ∈ B ( a R b ∧ b S c ) } S \circ R=\{(a,c) \, | \, a \in A \land c \in C \land \exists b \in B(aRb \land bSc)\} SR={(a,c)aAcCbB(aRbbSc)}
Remark: R n = R n − 1 ∘ R R^n=R^{n-1} \circ R Rn=Rn1R
Theroem: The relation R on a set A is transitive    ⟺    R n ⊆ R \iff R^n \subseteq R RnR
 Let R = { ( a , b )   ∣   a ∈ A ∧ b ∈ B ∧ a R b } R=\{(a,b) \, | \, a \in A \land b \in B \land aRb\} R={(a,b)aAbBaRb}.
 The inverse relation of R R R: R c = R − 1 = { ( b , a )   ∣   a ∈ A ∧ b ∈ B ∧ a R b } R^c=R^{-1}=\{(b,a) \, | \, a \in A \land b \in B \land aRb\} Rc=R1={(b,a)aAbBaRb}
Remark: M R − 1 = ( M R ) T M_{R^{-1}}=(M_R)^T MR1=(MR)T

Properties of Relation Operations

( R ∪ S ) − 1 = R − 1 ∪ S − 1 (R \cup S)^{-1}=R^{-1} \cup S^{-1} (RS)1=R1S1
( R ∩ S ) − 1 = R − 1 ∩ S − 1 (R \cap S)^{-1}=R^{-1} \cap S^{-1} (RS)1=R1S1
( R ‾ ) − 1 = R − 1 ‾ (\overline{R})^{-1}=\overline{R^{-1}} (R)1=R1
( R − S ) − 1 = R − 1 − S − 1 (R-S)^{-1}=R^{-1}-S^{-1} (RS)1=R1S1
( A × B ) − 1 = B × A (A \times B)^{-1}=B \times A (A×B)1=B×A
R ‾ = A × B − R \overline{R}=A \times B -R R=A×BR
( S ∘ T ) − 1 = T − 1 ∘ S − 1 (S \circ T)^{-1}=T^{-1} \circ S^{-1} (ST)1=T1S1
( R ∘ T ) ∘ P = R ∘ ( T ∘ P ) (R \circ T) \circ P=R \circ (T \circ P) (RT)P=R(TP)
( R ∪ S ) ∘ T = ( R ∘ T ) ∪ ( S ∘ T ) (R \cup S) \circ T=(R \circ T) \cup (S \circ T) (RS)T=(RT)(ST)

Closures of Relations
ClosureCHNDenote
Reflexive Closure自反闭包 r ( R ) = R ∪ I A r(R)=R \cup I_A r(R)=RIA
Symmetric Closure对称闭包 s ( R ) = R ∪ R − 1 s(R)=R \cup R^{-1} s(R)=RR1
Transitive Closure传递闭包 t ( R ) = R ∗ t(R)=R^* t(R)=R

 The diagonal relation on A A A: I A = { ( x , x )   ∣   x ∈ A } I_A=\{(x,x) \, | \, x \in A\} IA={(x,x)xA}
 The connectivity relation on A A A: R ∗ = ⋃ n = 1 ∞ R n R^*=\bigcup\limits_{n=1}^{\infty}{R^n} R=n=1Rn
Collary: ∣ A ∣ = n ⟹ t ( R ) = R ∪ R 2 ∪ ⋯ ∪ R n |A|=n \Longrightarrow t(R)=R \cup R^2 \cup \cdots \cup R^n A=nt(R)=RR2Rn

Equivalence Relations and Partitions

Definition:
  A relation R R R on set A A A is an equivalence relation iff R R R is reflexive, symmetric and transitive.
  The equivalence class of x ∈ A x \in A xA via equivalence relation R R R is [ x ] R [x]_R [x]R, or [ x ] [x] [x] for short.
   a a a and b b b of set A A A are equivalent by equivalence relation R R R    ⟺    a ∼ b \iff a \sim b ab
Remark:
  Congruence Modulo m m m: R = { ( a , b )   ∣   a ≡ b ( m o d m ) , a , b ∈ Z } R=\{(a,b) \, | \, a \equiv b \pmod{m}, a,b \in \mathbb{Z}\} R={(a,b)ab(modm),a,bZ}
  Congruence class Modulo m m m: [ t ] m = { t + k m   ∣   k ∈ Z } , t = 0 , 1 , 2 , … , m − 1 [t]_m=\{t+km \, | \, k \in \mathbb{Z}\}, t=0,1,2,\dots,m-1 [t]m={t+kmkZ},t=0,1,2,,m1
Theroem:
  Let R R R be an equivalence relation on set A A A.
   a R b    ⟺    [ a ] = [ b ]    ⟺    [ a ] ∩ [ b ] ≠ ∅ aRb \iff [a]=[b] \iff [a] \cap [b] \neq \varnothing aRb[a]=[b][a][b]=
Theroem:
  Let R 1 R_1 R1 and R 2 R_2 R2 be equivalence relations on A A A.
   R 1 ∩ R 2 R_1 \cap R_2 R1R2 is an equivalence relation, R 1 ∪ R 2 R_1 \cup R_2 R1R2 is reflexive and symmetric.
  Collary: ( R 1 ∪ R 2 ) ∗ (R_1 \cup R_2)^* (R1R2) is an equivalence relation
Definition:
  A partition of set A A A is a collection of disjoint nonempty subsets of A A A that have A A A as their union.
   p r ( A ) = { A i   ∣   i ∈ I } pr(A)=\{A_i \, | \, i \in I\} pr(A)={AiiI}, where I I I is an index set, A i ≠ ∅ A_i \neq \varnothing Ai=, A i ∩ A j = ∅ ( i ≠ j ) , ⋃ i ∈ I A i = A A_i \cap A_j=\varnothing(i \neq j), \bigcup\limits_{i \in I}{A_i}=A AiAj=(i=j),iIAi=A.

Partial Orderings

Definition:
  A relation R R R on set S S S is a partial ordering iff R R R is reflexive, antisymmetric and transitive.
  For notation, ( S , R ) (S,R) (S,R) is a partially ordered set, or poset for short.
  The elements a a a and b b b of a poset ( S , ≼ ) (S,\preccurlyeq) (S,) are comparable if either a ≼ b a \preccurlyeq b ab or b ≼ a b \preccurlyeq a ba.
  When neither a ≼ b a \preccurlyeq b ab or b ≼ a b \preccurlyeq a ba, then a a a and b b b are called incomparable.
  If ( S , ≼ ) (S,\preccurlyeq) (S,) is a poset and ∀ ( a , b ) ∈ S \forall (a,b) \in S (a,b)S are comparable, S S S is totally ordered or linearly ordered.
  In this case, ≼ \preccurlyeq is called a total order or linear order.

ENGCHNDenote
Maximal Element(s)极大值 ∃ a ∈ A ( ¬ ∃ b ∈ A ( a ≺ b ) ) \exist a \in A(\neg \exist b \in A(a \prec b)) aA(¬bA(ab))
Minimal Element(s)极小值 ∃ a ∈ A ( ¬ ∃ b ∈ A ( b ≺ a ) ) \exist a \in A(\neg \exist b \in A(b \prec a)) aA(¬bA(ba))
Greatest Element最大值 ∃ a ∈ A ( ∀ b ∈ A ( b ≼ a ) ) \exist a \in A(\forall b \in A(b \preccurlyeq a)) aA(bA(ba))
Least Element最小值 ∃ a ∈ A ( ∀ b ∈ A ( a ≼ b ) ) \exist a \in A(\forall b \in A(a \preccurlyeq b)) aA(bA(ab))
Upper Bound上界 ∃ a ∈ S ( ∀ b ∈ A ( b ≺ a ) ) \exist a \in S(\forall b \in A(b \prec a)) aS(bA(ba))
A ⊆ S A \subseteq S AS
Lower Bound下界 ∃ a ∈ S ( ∀ b ∈ A ( a ≺ b ) ) \exist a \in S(\forall b \in A(a \prec b)) aS(bA(ab))
A ⊆ S A \subseteq S AS
Least Upper Bound上确界 min ⁡ a \min{a} mina
Greatest Lower Bound下确界 max ⁡ a \max{a} maxa

  A poset ( A , R ) (A,R) (A,R) is well-ordered iff every nonempty subset of A A A has a least element.
  A poset is called a lattice iff every pair of elements has a l u b \mathrm{lub} lub and a g l b \mathrm{glb} glb.

10. Graphs

 Let G = ( V , E ) G=(V,E) G=(V,E) be an undirected graph with e e e edges, then ∑ v ∈ V deg ⁡ ( v ) = 2 e \sum\limits_{v \in V}{\deg(v)}=2e vVdeg(v)=2e.
 Let G = ( V , E ) G=(V,E) G=(V,E) be a digraph, then ∑ v ∈ V deg ⁡ + ( v ) = ∑ v ∈ V deg ⁡ − ( v ) = ∣ E ∣ \sum\limits_{v \in V}{\deg^+(v)}=\sum\limits_{v \in V}{\deg^-(v)}=|E| vVdeg+(v)=vVdeg(v)=E.

Some Special Simple Graphs
Denotei.e.
K n K_n KnComplete Graph
C n   ( n ≥ 3 ) C_n \ (n \ge 3) Cn (n3)Cycle
W n   ( n ≥ 3 ) W_n \ (n \ge 3) Wn (n3)Wheel
Q n Q_n Qn n n n-Cube
K m , n   ( m = ∣ V 1 ∣ , n = ∣ V 2 ∣ ) K_{m,n} \ (m=\vert V_1 \vert , n=\vert V_2 \vert) Km,n (m=V1,n=V2)Complete Bipartite Graph

Regular graph:
  A simply graph is called regular if every vertex of this graph has the same degree.
  A regular graph is called n n n-regular if every vertex in this graph has degree n n n.

New Graphs from Old

Subgraph:
  Let G = ( V , E ) G=(V,E) G=(V,E), H = ( W , F ) H=(W,F) H=(W,F).
   H H H is a subgraph of G G G if W ⊆ V W \subseteq V WV and F ⊆ E F \subseteq E FE.
  Subgraph H H H is a proper subgraph of G G G if H ≠ G H \neq G H=G.
   H H H is a spanning subgraph of G G G if W = V W=V W=V and F ⊆ E F \subseteq E FE.

Union:
  Let G 1 = ( V 1 , E 1 ) G_1=(V_1,E_1) G1=(V1,E1), G 2 = ( V 2 , E 2 ) G_2=(V_2,E_2) G2=(V2,E2), then G 1 ∪ G 2 = ( V 1 ∪ V 2 , E 1 ∪ E 2 ) G_1 \cup G_2=(V_1 \cup V_2, E_1 \cup E_2) G1G2=(V1V2,E1E2).

Representing Graphs

Adjacency matrix: A G = [ a i j ] n A_G=[a_{ij}]_n AG=[aij]n, a i j = 1 a_{ij}=1 aij=1 if { v i , v j } \{v_i,v_j\} {vi,vj} is an edge of G G G, or a i j = 0 a_{ij}=0 aij=0 otherwise.
Incidence matrix: M G = [ m i j ] n × m M_G=[m_{ij}]_{n \times m} MG=[mij]n×m, m i j = 1 m_{ij}=1 mij=1 if e j e_j ej is incident with v i v_i vi, or m i j = 0 m_{ij}=0 mij=0 otherwise.
Isomorphism(同构):
  Formally, two simple graphs G 1 = ( V 1 , E 1 ) G_1=(V_1,E_1) G1=(V1,E1) and G 2 = ( V 2 , E 2 ) G_2=(V_2,E_2) G2=(V2,E2) are isomorphic.
  If and only if there is an bijection f f f from V 1 V_1 V1 to V 2 V_2 V2 such that ∀ a , b ∈ V 1 \forall a, b \in V_1 a,bV1.
   a a a and b b b are adjacent in G 1 G_1 G1 while f ( a ) f(a) f(a) and f ( b ) f(b) f(b) are adjacent in G 2 G_2 G2.

Connectivity

 The number of different paths of length r r r from v i v_i vi to v j v_j vj is equal to the ( i , j ) (i, j) (i,j)-th entry of A r A^r Ar.
 The maximally connected subgraphs of G G G are called the connected components.
 A vertex is a cut vertex or articulation point, if removing it and its incident edges results in more connected components.
 Similarly if removal of an edge creates more components the edge is called a cut edge or bridge.
 A directed graph is strongly connected if there is a path from a a a to b b b and from b b b to a a a for all vertices a a a and b b b in the graph.
 The graph is weakly connected if the underlying undirected graph is connected.
 For directed graph, the maximal strongly connected subgraphs are called the strongly connected components.

Euler and Hamilton Paths

Definition:
  A connected multigraph has an Euler circuit if and only if each of its vertices has even degree.
  A connected multigraph has an Euler path but not an Euler circuit if and only if it has exactly two vertices of odd degree.
  A Hamilton path in a graph G G G is a path which visits every vertex in G G G exactly once.
  A Hamilton circuit visits every vertex exactly once, except for the first vertex, which is also the end of the cycle.
Sufficient Condition:
  Let G G G be a simple graph with n n n ( n ≥ 3 ) (n \ge 3) (n3) vertices.
  Dirac’s Theroem(狄拉克定理) If deg ⁡ v ∈ G ( v ) ≥ n 2 \deg\limits_{v \in G}(v)\ge \dfrac{n}{2} vGdeg(v)2n, then G G G has a Hamilton circuit.
  Ore’s Theroem(奥勒定理) If deg ⁡ ( u ) + deg ⁡ ( v ) ≥ n \deg(u)+\deg(v) \ge n deg(u)+deg(v)n ( ∀ u , v ∈ G , ¬ e u v ) (\forall u,v \in G, \neg e_{uv}) (u,vG,¬euv), then G G G has a Hamilton circuit.

Planar Graphs

Euler’s formula:
  Let G G G be a connected planar simple graph with e e e edges and v v v vertices.
  Let r r r be the number of regions in a planar representation of G G G.
  Then we have the formula r = e − v + 2 r=e-v+2 r=ev+2.
Degree of Region:
  Suppose R R R is a region of a connected planar simple graph.
  The number of edges on the boundary of R R R is called the Degree of R R R, denoted by D e g ( R ) \mathrm{Deg}(R) Deg(R).
Collary:
  If G G G is a connected planar simple graph with e e e edges and v v v ( v ≥ 3 ) (v \ge 3) (v3) vertices, then e ≤ 3 v − 6 e \leq3v-6 e3v6.
    2 e = ∑ R i ∈ G D e g ( R i ) ≥ 3 r ⟹ r = e − v + 2 ≤ 2 3 e ⟹ e ≤ 3 v − 6 2e=\sum\limits_{R_i \in G}{\mathrm{Deg}(R_i)} \ge 3r \Longrightarrow r=e-v+2 \leq \dfrac23 e \Longrightarrow e \leq 3v-6 2e=RiGDeg(Ri)3rr=ev+232ee3v6
  If G G G is a connected planar simple graph, then G G G has a vertex v i v_i vi with deg ⁡ ( v i ) ≤ 5 \deg(v_i) \leq 5 deg(vi)5.
    ( 2 e = ∑ v i ∈ V deg ⁡ ( v i ) ≥ 6 v ) ∧ ( e ≤ 3 v − 6 ⇔ 2 e ≤ 6 v − 12 ) = 0 (2e=\sum\limits_{v_i \in V}{\deg(v_i)} \ge 6v) \land (e \leq 3v-6 \Leftrightarrow 2e \leq 6v-12)=0 (2e=viVdeg(vi)6v)(e3v62e6v12)=0
  If G has e e e edges and v v v ( v ≥ 3 ) (v \ge 3) (v3) vertices and no circuits of length 3 3 3,then e ≤ 2 v − 4 e \leq 2v-4 e2v4.
    2 e = ∑ R i ∈ G D e g ( R i ) ≥ 4 r ⟹ r = e − v + 2 ≤ 1 2 e ⟹ e ≤ 2 v − 4 2e=\sum\limits_{R_i \in G}{\mathrm{Deg}(R_i)} \ge 4r \Longrightarrow r=e-v+2 \leq \dfrac12 e \Longrightarrow e \leq 2v-4 2e=RiGDeg(Ri)4rr=ev+221ee2v4
  Generally, if every region of G has at least k k k edges, then e ≤ k ( v − 2 ) k − 2 e \leq \dfrac{k(v-2)}{k-2} ek2k(v2).
Homeomorphism(同胚):
  The graph G 1 = ( V 1 , E 1 ) G_1=(V_1,E_1) G1=(V1,E1) and G 2 = ( V 2 , E 2 ) G_2=(V_2,E_2) G2=(V2,E2) are called homeomorphic.
  If and only if they can be obtained from the same graph by a sequence of elementary subdivision.
Kuratowski’s Theorem(库拉托斯基定理):
  A graph is nonplanar if and only if it contains a subgraph homeomorphic to K 3 , 3 K_{3,3} K3,3 or K 5 K_5 K5.


(updated 2021.5.14)

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值