教材是Discrete Mathematics and Its Applications 7th,做了一些简单的翻译和简单的笔记。
1. The Foundations: Logic and Proofs
ENG | CHN | Denote |
---|---|---|
negation | 否定 | ¬p\neg p¬p |
conjunction (and) | 合取 | p∧qp \land qp∧q |
disjunction (or) | 析取 | p∨qp \lor qp∨q |
exlusive or | 异或 | p⊕qp \oplus qp⊕q |
conditional statement/ implication | 蕴含 | p→qp \to qp→q |
biconditional statement | 等价 | p↔qp \leftrightarrow qp↔q |
tautology | 永真式 | ≡1\equiv 1≡1 |
contingency | 可能式 | 0/10/10/1 |
contradiction | 矛盾式 | ≡0\equiv 0≡0 |
proposition | 命题 | p→qp \to qp→q |
converse proposition | 逆命题 | q→pq \to pq→p |
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 \iffp→q≡¬p∨q⟺ if ppp then q ⟺ qq \iff qq⟺q if/when p ⟺ pp \iff pp⟺p only if q ⟺ qq \iff qq⟺q unless ¬p\neg p¬p
Equivalence Law:
p↔q≡(p→q)∧(q→p) ⟺ pp \leftrightarrow q \equiv (p \to q) \land (q \to p) \iff pp↔q≡(p→q)∧(q→p)⟺p if and only if q ⟺ pq \iff pq⟺p iff qqq
Logical Equivalences:
Equivalence | ENG | CHN |
---|---|---|
p∧T≡pp \land T \equiv pp∧T≡p p∨F≡pp \lor F \equiv pp∨F≡p | Identity Laws | 同一律 |
p∨T≡Tp \lor T \equiv Tp∨T≡T p∧F≡Fp \land F \equiv Fp∧F≡F | Domination Laws | 零律 |
p∨p≡pp \lor p \equiv pp∨p≡p p∧p≡pp \land p \equiv pp∧p≡p | Idempotent Laws | 幂等律 |
¬(¬p)≡p\neg (\neg p) \equiv p¬(¬p)≡p | Double Negation Law | 双重否定律 |
p∨q≡q∨pp \lor q \equiv q \lor pp∨q≡q∨p p∧q≡q∧pp \land q \equiv q \land pp∧q≡q∧p | Comutative Laws | 交换律 |
(p∨q)∨r≡p∨(q∨r)(p \lor q) \lor r \equiv p \lor (q \lor r)(p∨q)∨r≡p∨(q∨r) (p∧q)∧r≡p∧(q∧r)(p \land q) \land r \equiv p \land (q \land r)(p∧q)∧r≡p∧(q∧r) | Associative Laws | 结合律 |
p∨(q∧r)≡(p∨q)∧(p∨r)p \lor (q \land r) \equiv (p \lor q) \land (p \lor r)p∨(q∧r)≡(p∨q)∧(p∨r) p∧(q∨r)≡(p∧q)∨(p∧r)p \land (q \lor r) \equiv (p \land q) \lor (p \land r)p∧(q∨r)≡(p∧q)∨(p∧r) | Distributive Laws | 分配律 |
¬(p∧q)≡¬p∨¬q\neg (p \land q) \equiv \neg p \lor \neg q¬(p∧q)≡¬p∨¬q ¬(p∨q)≡¬p∧¬q\neg (p \lor q) \equiv \neg p \land \neg q¬(p∨q)≡¬p∧¬q | De Morgan’s Laws | 德摩根定律 |
p∨(p∧q)≡pp \lor (p \land q) \equiv pp∨(p∧q)≡p p∧(p∨q)≡pp \land (p \lor q) \equiv pp∧(p∨q)≡p | Absorption Laws | 吸收律 |
p∨¬p≡Tp \lor \neg p \equiv Tp∨¬p≡T p∧¬p≡Fp \land \neg p \equiv Fp∧¬p≡F | Negation Laws | 排中律 矛盾律 |
Show p≡qp \equiv qp≡q :
a. Using truth tables
b. Using already-proved equivalences (Recommended)
Predicates and Quantifiers:
Universal Quantifier ∀\forall∀ :
∀xP(x) ⟺ P(x)\forall xP(x) \iff P(x)∀xP(x)⟺P(x) for all values of xxx in the (restricted) domain
Existential Quantifier ∃\exist∃ :
∃xP(x) ⟺ \exist xP(x) \iff∃xP(x)⟺ There exists (at least) an element xxx in the domain such that P(x)P(x)P(x)
De Morgan’s Laws for quantifiers:
¬∀xP(x)≡∃x¬P(x)\neg \forall xP(x) \equiv \exist x \neg P(x)¬∀xP(x)≡∃x¬P(x)
¬∃xQ(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 limx→af(x)=L{\lim_{x \to a}f(x)=L}x→alimf(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<∣x−a∣<δ→∣f(x)−L∣<ϵ) And what is the inverse proposition of this statement?
Propositional Normal Forms:
ENG | CHN | Denote |
---|---|---|
Maxterm | 极大项 | M=a1∨a2∨⋯∧ai∨⋯M=a_1 \lor a_2 \lor \cdots \land a_i \lor \cdotsM=a1∨a2∨⋯∧ai∨⋯ (there exists unique value of each aia_iai so that M=0M=0M=0) |
Minterm | 极小项 | m=b1∧b2∧⋯∧bi∧⋯m=b_1 \land b_2 \land \cdots \land b_i \land \cdotsm=b1∧b2∧⋯∧bi∧⋯ (there exists unique value of each bib_ibi so that m=1m=1m=1) |
Conjunctive Normal Form (CNF) | 合取范式 | C=A1∧A2∧⋯∧Ai∧⋯C=A_1 \land A_2 \land \cdots \land A_i \land \cdotsC=A1∧A2∧⋯∧Ai∧⋯, AiA_iAi are propositions |
Disjunctive Normal Form (DNF) | 析取范式 | D=B1∨B2∨⋯∨Bi∨⋯D=B_1 \lor B_2 \lor \cdots \lor B_i \lor \cdotsD=B1∨B2∨⋯∨Bi∨⋯, BiB_iBi are propositions |
Full Conjunctive Normal Form | 主合取范式 | X=M1∧M2∧⋯∧Mi∧⋯X=M_1 \land M_2 \land \cdots \land M_i \land \cdotsX=M1∧M2∧⋯∧Mi∧⋯, MiM_iMi are maxterms |
Full Disjunctive Normal Form | 主析取范式 | Y=m1∨m2∨⋯∨mi∨⋯Y=m_1 \lor m_2 \lor \cdots \lor m_i \lor \cdotsY=m1∨m2∨⋯∨mi∨⋯, mim_imi are minterms |
Prenex Normal Form | 前约束范式 | O=Q1z1Q2z2⋯QnznEO=Q_1z_1Q_2z_2 \cdots Q_nz_nEO=Q1z1Q2z2⋯QnznE, Qi=∀Q_i=\forallQi=∀ or ∃\exist∃, EEE 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)p↔q≡(p→q)∧(q→p)≡(¬p∨q)∧(¬q∨p)≡(p∧q)∨(¬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:
QxA(x)∧P≡Qx(A(x)∧P)Q xA(x) \land P \equiv Q x(A(x) \land P)QxA(x)∧P≡Qx(A(x)∧P),
QxA(x)∨P≡Qx(A(x)∨P)Q xA(x) \lor P \equiv Q x(A(x) \lor P)QxA(x)∨P≡Qx(A(x)∨P),
Q′xA(x)∧Q′′yB(y)≡Q′xQ′′y(A(x)∧B(y))Q'xA(x) \land Q''yB(y) \equiv Q'xQ''y(A(x) \land B(y))Q′xA(x)∧Q′′yB(y)≡Q′xQ′′y(A(x)∧B(y)),
Q′xA(x)∨Q′′yB(y)≡Q′xQ′′y(A(x)∨B(y))Q'xA(x) \lor Q''yB(y) \equiv Q'xQ''y(A(x) \lor B(y))Q′xA(x)∨Q′′yB(y)≡Q′xQ′′y(A(x)∨B(y)),
QxQyC(x,y)≡QyQxC(x,y)QxQyC(x,y) \equiv QyQxC(x,y)QxQyC(x,y)≡QyQxC(x,y),
where we have:
Q,Q′,Q′′=∀Q,Q',Q''=\forallQ,Q′,Q′′=∀ or ∃\exist∃,
PPP 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:
Rule | Tautology | ENG | CHN |
---|---|---|---|
pp→q∴ q\begin{aligned} &p \\ &p \to q \\ \hline \therefore \; &q \end{aligned}∴pp→qq | (p∧(p→q))→q(p \land (p \to q)) \to q(p∧(p→q))→q | Modus ponens | 假言推理式 |
¬qp→q∴ ¬p\begin{aligned} &\neg q \\ &p \to q \\ \hline \therefore \; &\neg p \end{aligned}∴¬qp→q¬p | (¬q∧(p→q))→¬p(\neg q \land (p \to q)) \to \neg p(¬q∧(p→q))→¬p | Modus tollens | 否定拒取式 |
p→qq→r∴ p→r\begin{aligned}&p \to q \\ &q \to r \\ \hline \therefore \; &p \to r \end{aligned}∴p→qq→rp→r | ((p→q)∧(q→r))→(p→r)((p \to q) \land (q \to r)) \to (p \to r)((p→q)∧(q→r))→(p→r) | Hypothetical syllogism | 假言三段论 |
p∨q¬p∴ q\begin{aligned}&p \lor q \\ &\neg p\\ \hline \therefore \; &q \end{aligned}∴p∨q¬pq | ((p∨q)∧¬p)→q((p \lor q) \land \neg p) \to q((p∨q)∧¬p)→q | Disjunctive syllogism | 析取三段论 |
p∴ p∨q\begin{aligned}&p \\ \hline \therefore \; &p \lor q \end{aligned}∴pp∨q | p→(p∨q)p \to (p \lor q)p→(p∨q) | Addition | 附加律 |
p∧q∴ q\begin{aligned}&p \land q \\ \hline \therefore \; &q \end{aligned}∴p∧qq | (p∧q)→q(p \land q) \to q(p∧q)→q | Simplification | 消去律 |
pq∴ p∧q\begin{aligned}&p \\ &q \\ \hline \therefore \; &p \land q \end{aligned}∴pqp∧q | ((p)∧(q))→(p∧q)((p) \land (q)) \to (p \land q)((p)∧(q))→(p∧q) | Conjunction | 合取式 |
p∨q¬p∨r∴ q∨r\begin{aligned}&p \lor q \\ &\neg p \lor r \\ \hline \therefore \; &q \lor r \end{aligned}∴p∨q¬p∨rq∨r | ((p∨q)∧(¬p∨r))→(q∨r)((p \lor q) \land (\neg p \lor r)) \to (q \lor r)((p∨q)∧(¬p∨r))→(q∨r) | Resolution | 消解规则 |
p→rq→sp∨q∴ r∨s\begin{aligned}&p \to r \\ &q \to s \\ &p \lor q \\ \hline \therefore \; &r \lor s \end{aligned}∴p→rq→sp∨qr∨s | ((p→r)∧(q→r)∧(p∨q))→(r∨s)((p \to r) \land (q \to r) \land (p \lor q)) \to (r \lor s)((p→r)∧(q→r)∧(p∨q))→(r∨s) | Constructive dilemma | 构造性两难 |
Remark: (P1∧P2∧⋯∧Pn∧P)→Q≡(P1∧P2∧⋯∧Pn)→(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)(P1∧P2∧⋯∧Pn∧P)→Q≡(P1∧P2∧⋯∧Pn)→(P→Q)
Rule | Name |
---|---|
∀xP(x)∴ P(c)\begin{aligned}&\forall xP(x) \\ \hline \therefore \; &P(c) \end{aligned}∴∀xP(x)P(c) , for an arbitary ccc | Universal instantiation (UI) |
P(c)∴ ∀xP(x)\begin{aligned}&P(c) \\ \hline \therefore \; &\forall xP(x) \end{aligned}∴P(c)∀xP(x) , for an arbitary ccc | Universal generalization (UG) |
∃xP(x)∴ P(c)\begin{aligned}&\exist xP(x) \\ \hline \therefore \; &P(c) \end{aligned}∴∃xP(x)P(c) , for some element ccc | Existential instantiation (EI) |
P(c)∴ ∃xP(x)\begin{aligned}&P(c) \\ \hline \therefore \; &\exist xP(x) \end{aligned}∴P(c)∃xP(x) , for some element ccc | Existential 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
Denote | ENG |
---|---|
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={pq ∣ 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={qp∣∣∣p∈Z+∪Z−,q∈Z} | Rational numbers |
R\mathbb{R}R | Real numbers |
R+\mathbb{R^+}R+ | Positve real numbers |
C\mathbb{C}C | Complex numbers |
ENG | CHN | Denote | i.e. |
---|---|---|---|
Subset | 子集 | A⊆BA \subseteq BA⊆B | ∀x(x∈A→x∈B)\forall x(x \in A \to x \in B)∀x(x∈A→x∈B) |
Proper subset | 真子集 | A⊂BA \subset BA⊂B | ∀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(x∈A→x∈B)∧∃x(x∈B∧x∈/A) |
Equal | 等集 | A=BA=BA=B | A⊆B∧B⊆AA \subseteq B \land B \subseteq AA⊆B∧B⊆A ∀x(x∈A↔x∈B)\forall x(x \in A \leftrightarrow x \in B)∀x(x∈A↔x∈B) |
Cardinality | 基数 | ∣S∣Card(S)\vert S \vert \\ \operatorname{Card}(S)∣S∣Card(S) | ∑x∈S1\sum_{x \in S}1x∈S∑1 |
Power set | 幂集 | P(S)\mathcal{P}(S)P(S) | ⋃A⊆S{A}\bigcup_{A \subseteq S}\{A\}A⊆S⋃{A} |
Remark: for every set SSS, we have ∅∈S\varnothing \in S∅∈S and S∈SS \in SS∈S
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)∣a∈A∧b∈B}
A1×A2×⋯×An={(a1,a2,…,an) ∣ ∀i∈{1,2,…,n}(ai∈An)}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}(ai∈An)}
Set Operations:
Operation | CHN | Denote | i.e. |
---|---|---|---|
Union | 并集 | A∪BA \cup BA∪B | {x ∣ x∈A∨x∈B}\{x \, \vert \, x \in A \lor x \in B\}{x∣x∈A∨x∈B} |
Intersection | 交集 | A∩BA \cap BA∩B | {x ∣ x∈A∧x∈B}\{x \, \vert \, x \in A \land x \in B\}{x∣x∈A∧x∈B} |
Complement | 补集 | A‾\overline{A}A | {x∈U ∣ x∉A}\{x \in U \, \vert \, x \notin A\}{x∈U∣x∈/A} |
Difference | 差集 | A−BA∖BA - B \\ A \setminus BA−BA∖B | {x ∣ x∈A∧x∉B}\{x \, \vert \, x \in A \land x \notin B\}{x∣x∈A∧x∈/B} |
Remark:
A−B=A∩B‾A-B=A \cap \overline{B}A−B=A∩B
A∩B=∅ ⟺ AA \cap B=\varnothing \iff AA∩B=∅⟺A and BBB are disjoint
Principle of Inclusion–Exclusion(容斥原理):
∣A∪B∣=∣A∣+∣B∣−∣A∩B∣|A \cup B|=|A|+|B|-|A \cap B|∣A∪B∣=∣A∣+∣B∣−∣A∩B∣
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)A⊕B=(A−B)∪(B−A)=(A∪B)−(A∩B)
Set Identities:
Identity | ENG | CHN |
---|---|---|
A∪∅=AA∩U=AA \cup \varnothing = A \\ A \cap U =AA∪∅=AA∩U=A | Identity Laws | 同一律 |
A∪U=UA∩∅=∅A \cup U = U \\ A \cap \varnothing = \varnothingA∪U=UA∩∅=∅ | Domination Laws | 支配律 |
A∪A=AA∩A=AA \cup A = A \\ A \cap A = AA∪A=AA∩A=A | Idempotent Laws | 幂等律 |
(A‾)‾=A\overline{(\overline{A})}=A(A)=A | Complementation Law | 双重互补律 |
A∪B=B∪AA∩B=B∩AA \cup B = B \cup A \\ A \cap B = B \cap AA∪B=B∪AA∩B=B∩A | Comutative 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)(A∪B)∪C=A∪(B∪C)(A∩B)∩C=A∩(B∩C) | 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∪(B∩C)=(A∪B)∩(A∪C)A∩(B∪C)=(A∩B)∪(A∩C) | 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}A∩B=A∪BA∪B=A∩B | De Morgan’s Laws | 德摩根定律 |
A∪(A∩B)=AA∩(A∪B)=AA \cup (A \cap B) = A \\ A \cap (A \cup B) = AA∪(A∩B)=AA∩(A∪B)=A | Absorption Laws | 吸收律 |
A∪A‾=UA∩A‾=∅A \cup \overline{A} = U \\ A \cap \overline{A} = \varnothingA∪A=UA∩A=∅ | Complement Laws | 互补律 |
Functions:
Let A,B≠∅A,B \ne \varnothingA,B=∅, we define a mapping fff from AAA to BBB:f:A↦Bf:A \mapsto Bf:A↦B 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(a∈A→∃!b(b∈B∧f(a)=b))
Denote | ENG | CHN |
---|---|---|
AAA | domain | 定义域 |
BBB | codomain | 上域 |
f(A)f(A)f(A) | range | 值域 |
bbb | image | 像 |
aaa | preimage | 原像 |
Remark:f(A)={f(x) ∣ ∀x∈A}⊆Bf(A)=\{f(x) \, \vert \, \forall x \in A\} \subseteq Bf(A)={f(x)∣∀x∈A}⊆B
ENG | CHN | Denote |
---|---|---|
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))∀a∈A ∀b∈A(f(a)=f(b)→a=b)⟺∀a∈A ∀b∈A(a=b→f(a)=f(b)) |
Surjective/ Onto | 满射 | ∀b∈B ∃a∈A(f(a)=b)\forall b \in B \ \exist a \in A(f(a)=b)∀b∈B ∃a∈A(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))∀x∈D ∀y∈D(x<y→f(x)≤f(y))∀x∈D ∀y∈D(x<y→f(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))∀x∈D ∀y∈D(x<y→f(x)≥f(y))∀x∈D ∀y∈D(x<y→f(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∀y∈B,∃!x∈A s.t.f(x)=y⟺f−1(y)=x |
Remark: f:A↦Bf:A \mapsto Bf:A↦B 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)(f⋅g)(x)=f(x)⋅g(x)
Composition of Functions:
(f∘g)(x)=f(g(x))(f \circ g)(x)=f(g(x))(f∘g)(x)=f(g(x))
Useful properties of Floor Function f(x)=⌊x⌋f(x)=\lfloor x \rfloorf(x)=⌊x⌋ and Ceiling Function g(x)=⌈x⌉g(x)=\lceil x \rceilg(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+1x-1<\lfloor x \rfloor \leq x \leq \lceil x \rceil <x+1x−1<⌊x⌋≤x≤⌈x⌉<x+1
Useful Summation Formulea:
Sum | Closed Form |
---|---|
∑k=0nark,r≠0,1\sum\limits_{k=0}^{n}{ar^k},r \ne 0,1k=0∑nark,r=0,1 | a(1−rn+1)1−r\dfrac{a(1-r^{n+1})}{1-r}1−ra(1−rn+1) |
∑k=1nk\sum\limits_{k=1}^{n}{k}k=1∑nk | n(n+1)2\dfrac{n(n+1)}{2}2n(n+1) |
∑k=1nk2\sum\limits_{k=1}^{n}{k^2}k=1∑nk2 | n(n+1)(2n+1)6\dfrac{n(n+1)(2n+1)}{6}6n(n+1)(2n+1) |
∑k=1nk3\sum\limits_{k=1}^{n}{k^3}k=1∑nk3 | n2(n+1)24\dfrac{n^2(n+1)^2}{4}4n2(n+1)2 |
∑k=0∞xk,∣x∣<1\sum\limits_{k=0}^{\infty}{x^k},\vert x \vert <1k=0∑∞xk,∣x∣<1 | 11−x\dfrac{1}{1-x}1−x1 |
∑k=1∞kxk−1,∣x∣<1\sum\limits_{k=1}^{\infty}{kx^{k-1}},\vert x \vert <1k=1∑∞kxk−1,∣x∣<1 | 1(1−x)2\dfrac{1}{(1-x)^2}(1−x)21 |
Cardinality of infinite sets:
Definition: infinite set AAA 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+∣=ℵ0⟸∣Q+∣≤∣Z+×Z+∣=∣Z+∣≤∣Q+∣
∣R∣=∣(0,1)∣=ℵ1⟸f:(−π2,π2)↦R,f(x)=tan(xπ+12)|\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)∣=ℵ1⟸f:(−2π,2π)↦R,f(x)=tan(πx+21)
∣[0,1]∣=∣(0,1)∣=ℵ1⟸∣(0,1)∣≤∣[0,1]∣=∣[14,34]∣≤∣(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:A↦P(A) be an arbitary function.
Consider B={x∈A:x∉f(x)}B=\{x \in A : x \notin f(x)\}B={x∈A:x∈/f(x)}.
Assume that there exists y∈Ay \in Ay∈A so that f(y)=Bf(y)=Bf(y)=B.
If y∈By \in By∈B then y∈f(y)y \in f(y)y∈f(y), conflicting with the definition of BBB.
If y∉By \notin By∈/B then y∉f(y)y \notin f(y)y∈/f(y), so we have y∈By \in By∈B conflicting with y∉By \notin By∈/B.
Thus there is no such yyy, showing B∈P(A)B \in \mathcal{P}(A)B∈P(A) does not have preimage in AAA.
Hence, fff 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|∣A∣≤∣B∣∧∣B∣≤∣A∣⟺∣A∣=∣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 NNN objects are placed into kkk boxes, then there is at least one box containing at least ⌈Nk⌉\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(n−1)(n−2)⋯(n−r+1)=(n−r)!n!
C(n,r)=(nr)=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(n−1)(n−2)⋯(n−r+1)=r!(n−r)!n!
Remark: (nr)=(nn−r)\dbinom{n}{r}=\dbinom{n}{n-r}(rn)=(n−rn)
The Binomial Theorem(二项式定理): (x+y)n=∑k=0n(nk)xn−kyk(x+y)^n=\sum\limits_{k=0}^{n}{\dbinom{n}{k}x^{n-k}y^k}(x+y)n=k=0∑n(kn)xn−kyk
∑k=0n(nk)=2n⟸x=y=1\sum\limits_{k=0}^{n}{\dbinom{n}{k}}=2^n \Longleftarrow x=y=1k=0∑n(kn)=2n⟸x=y=1
∑k=0n(−1)k(nk)=0⟸x=−y=1\sum\limits_{k=0}^{n}{(-1)^k\dbinom{n}{k}}=0 \Longleftarrow x=-y=1k=0∑n(−1)k(kn)=0⟸x=−y=1
∑k=0n2k(nk)=3n⟸x+1=y=2\sum\limits_{k=0}^{n}{2^k\dbinom{n}{k}}=3^n \Longleftarrow x+1=y=2k=0∑n2k(kn)=3n⟸x+1=y=2
Pascal’s Identity: (n+1k)=(nk)+(nk−1)\dbinom{n+1}{k}=\dbinom{n}{k}+\dbinom{n}{k-1}(kn+1)=(kn)+(k−1n)
Vandermonde’s Identity and proof: (m+nr)=∑k=0r(mr−k)(nk)\dbinom{m+n}{r}=\sum\limits_{k=0}^r{\dbinom{m}{r-k}\dbinom{n}{k}}(rm+n)=k=0∑r(r−km)(kn)
(x+y)m+n=⋯+(m+nr)xm+n−ryr+⋯(x+y)^{m+n}=\cdots+\dbinom{m+n}{r}x^{m+n-r}y^r+\cdots(x+y)m+n=⋯+(rm+n)xm+n−ryr+⋯
(x+y)m(x+y)n=⋯+(∑k=0r(mr−k)xm−r+kyr−k)(∑k=0n(nk)xn−kyk)+⋯=⋯+∑k=0r((mr−k)xm−r+kyr−k⋅(nk)xn−kyk)+⋯=⋯+∑k=0r(mr−k)(nk)xm+n−ryr+⋯\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=0∑r(r−km)xm−r+kyr−k)(k=0∑n(kn)xn−kyk)+⋯=⋯+k=0∑r((r−km)xm−r+kyr−k⋅(kn)xn−kyk)+⋯=⋯+k=0∑r(r−km)(kn)xm+n−ryr+⋯
Corollary: (2nn)=∑k=0n(nn−k)(nk)=∑k=0n(nk)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=0∑n(n−kn)(kn)=k=0∑n(kn)2⟸m=r=n
Remark: (n+1r+1)=∑k=rn(kr)\dbinom{n+1}{r+1}=\sum\limits_{k=r}^{n}{\dbinom{k}{r}}(r+1n+1)=k=r∑n(rk)
(n+1r+1)=(nr+1)+(nr)=(n−1r+1)+(n−1r)+(nr)=⋯=(r+1r+1)+∑k=r+1n(kr)=(rr)+∑k=r+1n(kr)=∑k=rn(kr)\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+1n−1)+(rn−1)+(rn)=⋯=(r+1r+1)+k=r+1∑n(rk)=(rr)+k=r+1∑n(rk)=k=r∑n(rk)
Stirling Number(II):
nnn distinguishable objects into kkk indistinguishable boxes: ∑j=1kS(n,j)=∑j=1k[1j!∑i=0j−1(−1)i(ji)(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=1∑kS(n,j)=j=1∑k[j!1i=0∑j−1(−1)i(ij)(j−i)n]
8. Advanced Counting Techniques
Solving Linear Recurrence Relations:
an=c1an−1+c2an−2+⋯+ckan−k+F(n)a_n=c_1a_{n-1}+c_2a_{n-2}+\cdots+c_ka_{n-k}+F(n)an=c1an−1+c2an−2+⋯+ckan−k+F(n), F(n)=(btnt+bt−1nt−1+⋯+b1n+b0)snF(n)=(b_tn^t+b_{t-1}n^{t-1}+\cdots+b_1n+b_0)s^nF(n)=(btnt+bt−1nt−1+⋯+b1n+b0)sn.
Let the form of general solutions be an(p)+an(h)a_n^{(p)}+a_n^{(h)}an(p)+an(h)
an(h)a_n^{(h)}an(h) is the solution of homogeneous equation an=c1an−1+c2an−2+⋯+ckan−ka_n=c_1a_{n-1}+c_2a_{n-2}+\cdots+c_ka_{n-k}an=c1an−1+c2an−2+⋯+ckan−k
Assume that sss is a root of multiplicity mmm of the equation
Then an(p)a_n^{(p)}an(p)is the form as nm(dtnt+dt−1nt−1+⋯+d1n+d0)snn^m(d_tn^t+d_{t-1}n^{t-1}+\cdots+d_1n+d_0)s^nnm(dtnt+dt−1nt−1+⋯+d1n+d0)sn.
Particularly, when sss is not a root of the homogeneous equation, m=0m=0m=0.
Now we can solve the coefficients eie_iei of an=e1x1n+e2x2n+⋯+ekxkn+an(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 xix_ixi is of multiplicity lll, the form is as (einl+ei+1nl−1+⋯+ei+l−2n+ei+l−1)xin(e_in^l+e_{i+1}n^{l-1}+\cdots+e_{i+l-2}n+e_{i+l-1})x_i^n(einl+ei+1nl−1+⋯+ei+l−2n+ei+l−1)xin.
Generating Functions:
G(x)=a0+a1x+a2x2+⋯+anxn+⋯=∑k=0∞akxkG(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=0∑∞akxk
Remark:
f(x)+g(x)=∑k=0∞(ak+bk)xkf(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∞α⋅akxk\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⋅akxkx \cdot f'(x)=\sum\limits_{k=0}^{\infty}{k \cdot a_kx^k}x⋅f′(x)=k=0∑∞k⋅akxk
f(αx)=∑k=0∞αk⋅akxkf(\alpha x)=\sum\limits_{k=0}^{\infty}{\alpha^k \cdot a_kx^k}f(αx)=k=0∑∞αk⋅akxk
f(x)g(x)=∑k=0∞(∑j=0kajbk−j)xkf(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=0∑kajbk−j)xk
eg.
bk=∑i=0kaib_k=\sum\limits_{i=0}^{k}{a_i}bk=i=0∑kai
⟹F(x)=∑k=0∞bkxk=∑k=0∞(∑i=0kai⋅1)xk=G(x)⋅11−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=0∑∞bkxk=k=0∑∞(i=0∑kai⋅1)xk=G(x)⋅1−x1
ak=k2a_k=k^2ak=k2
⟹G(x)=∑k=0∞k2xk=x(∑k=0∞kxk)′=x[x(∑k=0∞xk)′]′=x[x(11−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=0∑∞k2xk=x(k=0∑∞kxk)′=x[x(k=0∑∞xk)′]′=x[x(1−x1)′]′=(1−x)3x(1+x)
ak=∑i=0ki2a_k=\sum\limits_{i=0}^{k}{i^2}ak=i=0∑ki2
⟹G(x)=∑k=0∞(∑i=0ki2⋅1)xk=x(1+x)(1−x)3⋅11−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=0∑ki2⋅1)xk=(1−x)3x(1+x)⋅1−x1=(1−x)4x(1+x)
f(x)=11−4x2=1(1−2x)(1+2x)=12(11−2x+11+2x)=∑k=0∞akxkf(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)=1−4x21=(1−2x)(1+2x)1=21(1−2x1+1+2x1)=k=0∑∞akxk
⟹ak=2k+(−2)k2\Longrightarrow a_k=\dfrac{2^k+(-2)^k}{2}⟹ak=22k+(−2)k
The Extended Binomial Therom:
(1+x)u=∑k=0∞(uk)xk,∣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,u∈R
Collary:
(1+x)−n=∑k=0∞(−nk)xk=∑k=0∞(−1)k(n+k−1k)xk(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∑∞(k−n)xk=k=0∑∞(−1)k(kn+k−1)xk
(1−x)−n=∑k=0∞(−nk)(−x)k=∑k=0∞(n+k−1k)xk(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}(1−x)−n=k=0∑∞(k−n)(−x)k=k=0∑∞(kn+k−1)xk
Generating Functions of Common Sequences:
Sequence | Generating Function |
---|---|
111 | 11−x\dfrac{1}{1-x}1−x1 |
αk\alpha^kαk | 11−αx\dfrac{1}{1-\alpha x}1−αx1 |
k+1k+1k+1 | 1(1−x)2\dfrac{1}{(1-x)^2}(1−x)21 |
(nk)\dbinom{n}{k}(kn) | (1+x)n(1+x)^n(1+x)n |
(nk)αk\dbinom{n}{k} \alpha^k(kn)αk | (1+αx)n(1+\alpha x)^n(1+αx)n |
(n+k−1k)\dbinom{n+k-1}{k}(kn+k−1) | (1−x)−n(1-x)^{-n}(1−x)−n |
(−1)k(n+k−1k)(-1)^k\dbinom{n+k-1}{k}(−1)k(kn+k−1) | (1+x)−n(1+x)^{-n}(1+x)−n |
1k!\dfrac{1}{k!}k!1 | exe^xex |
(−1)k+1k!\dfrac{(-1)^{k+1}}{k!}k!(−1)k+1 | ln(1+x)\ln(1+x)ln(1+x) |
9. Relations
Definition: A binary relation RRR from set AAA to set BBB is a subset of A×BA \times BA×B.
Remark: R={(a,b) ∣ a∈A∧b∈B∧aRb}⊆A×BR=\{(a,b) \, | \, a \in A \land b \in B \land aRb\} \subseteq A \times BR={(a,b)∣a∈A∧b∈B∧aRb}⊆A×B
Definition: A relation on set AAA is a binary relation from set AAA to set AAA.
eg. How many binary relations are there on a set AAA with nnn elements?
∣A∣=n⟹∣A×A∣=n⋅n=n2⟹∣R∣=2n2|A|=n \Longrightarrow |A \times A|=n \cdot n=n^2 \Longrightarrow |R|=2^{n^2}∣A∣=n⟹∣A×A∣=n⋅n=n2⟹∣R∣=2n2
Connection Matrices
Let RRR be a relation from A={a1,a2,…,an}A=\{a_1, a_2, \dots , a_n\}A={a1,a2,…,an} to B={b1,b2,…,bm}B=\{b_1, b_2, \dots , b_m\}B={b1,b2,…,bm}.
The n×mn \times mn×m connection matrix MR=[mij]M_R=[m_{ij}]MR=[mij] for RRR is defined by:
mij={1,(ai,bj)∈R0,(ai,bj)∉Rm_{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
Type | CHN | Denote |
---|---|---|
Reflexive | 自反性 | ∀x(x∈A→(x,x)∈R)\forall x(x \in A \to (x,x) \in R)∀x(x∈A→(x,x)∈R) |
Irreflexive | 非自反性 | ∀x(x∈A→(x,x)∉R)\forall x(x \in A \to (x,x) \notin R)∀x(x∈A→(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)∀x∀y((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)∀x∀y((x,y)∈R∧(y,x)∈R→x=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)∀x∀y((x,y)∈R∧x=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)∀x∀y(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)∀x∀y∀z((x,y)∈R∧(y,z)∈R→(x,z)∈R) |
Remark: (mij∧mjk)‾∨mik=1\overline{(m_{ij} \land m_{jk})} \lor m_{ik}=1(mij∧mjk)∨mik=1
eg.
How many relations on a set with nnn elements that are reflexive? 2n2−n2^{n^2-n}2n2−n
How many relations on a set with nnn elements that are symmetric? 2n⋅2n2−n2=2n2+n22^n \cdot 2^\frac{n^2-n}{2}=2^\frac{n^2+n}{2}2n⋅22n2−n=22n2+n
How many relations on a set with nnn elements that are antisymmetric? 2n⋅3n2−n22^n \cdot 3^\frac{n^2-n}{2}2n⋅32n2−n
How many relations on a set with nnn elements that are reflexive and symmetric? 2n2−n22^\frac{n^2-n}{2}22n2−n
How many relations on a set with nnn elements that are transitive? ∑j=1nS(n,j)\sum\limits_{j=1}^{n}{S(n,j)}j=1∑nS(n,j)
Combining Relations
Let A={a1,a2,…,an}A=\{a_1, a_2, \dots , a_n\}A={a1,a2,…,an}, B={b1,b2,…,bm}B=\{b_1, b_2, \dots , b_m\}B={b1,b2,…,bm}, MR1=[cij]M_{R_1}=[c_{ij}]MR1=[cij], MR2=[dij]M_{R_2}=[d_{ij}]MR2=[dij].
Operation | Denote |
---|---|
R1∪R2R_1 \cup R_2R1∪R2 | MR1∪R2=[cij∨dij]M_{R_1 \cup R_2}=[c_{ij} \lor d_{ij}]MR1∪R2=[cij∨dij] |
R1∩R2R_1 \cap R_2R1∩R2 | MR1∩R2=[cij∧dij]M_{R_1 \cap R_2}=[c_{ij} \land d_{ij}]MR1∩R2=[cij∧dij] |
R1‾\overline{R_1}R1 | MR1‾=[cij‾]M_{\overline{R_1}}=[\overline{c_{ij}}]MR1=[cij] |
R1−R2R_1-R_2R1−R2 R1∩R2‾R_1 \cap \overline{R_2}R1∩R2 | MR1−R2=MR1∩R2‾=[cij∧dij‾]M_{R_1-R_2}=M_{R_1 \cap \overline{R_2}}=[c_{ij} \land \overline{d_{ij}}]MR1−R2=MR1∩R2=[cij∧dij] |
Let R={(a,b) ∣ a∈A∧b∈B∧aRb}R=\{(a,b) \, | \, a \in A \land b \in B \land aRb\}R={(a,b)∣a∈A∧b∈B∧aRb}, S={(b,c) ∣ b∈B∧c∈C∧bSc}S=\{(b,c) \, | \, b \in B \land c \in C \land bSc\}S={(b,c)∣b∈B∧c∈C∧bSc}.
The composition of RRR and SSS: S∘R={(a,c) ∣ a∈A∧c∈C∧∃b∈B(aRb∧bSc)}S \circ R=\{(a,c) \, | \, a \in A \land c \in C \land \exists b \in B(aRb \land bSc)\}S∘R={(a,c)∣a∈A∧c∈C∧∃b∈B(aRb∧bSc)}
Remark: Rn=Rn−1∘RR^n=R^{n-1} \circ RRn=Rn−1∘R
Theroem: The relation R on a set A is transitive ⟺ Rn⊆R\iff R^n \subseteq R⟺Rn⊆R
Let R={(a,b) ∣ a∈A∧b∈B∧aRb}R=\{(a,b) \, | \, a \in A \land b \in B \land aRb\}R={(a,b)∣a∈A∧b∈B∧aRb}.
The inverse relation of RRR: Rc=R−1={(b,a) ∣ a∈A∧b∈B∧aRb}R^c=R^{-1}=\{(b,a) \, | \, a \in A \land b \in B \land aRb\}Rc=R−1={(b,a)∣a∈A∧b∈B∧aRb}
Remark: MR−1=(MR)TM_{R^{-1}}=(M_R)^TMR−1=(MR)T
Properties of Relation Operations
(R∪S)−1=R−1∪S−1(R \cup S)^{-1}=R^{-1} \cup S^{-1}(R∪S)−1=R−1∪S−1
(R∩S)−1=R−1∩S−1(R \cap S)^{-1}=R^{-1} \cap S^{-1}(R∩S)−1=R−1∩S−1
(R‾)−1=R−1‾(\overline{R})^{-1}=\overline{R^{-1}}(R)−1=R−1
(R−S)−1=R−1−S−1(R-S)^{-1}=R^{-1}-S^{-1}(R−S)−1=R−1−S−1
(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 -RR=A×B−R
(S∘T)−1=T−1∘S−1(S \circ T)^{-1}=T^{-1} \circ S^{-1}(S∘T)−1=T−1∘S−1
(R∘T)∘P=R∘(T∘P)(R \circ T) \circ P=R \circ (T \circ P)(R∘T)∘P=R∘(T∘P)
(R∪S)∘T=(R∘T)∪(S∘T)(R \cup S) \circ T=(R \circ T) \cup (S \circ T)(R∪S)∘T=(R∘T)∪(S∘T)
Closures of Relations
Closure | CHN | Denote |
---|---|---|
Reflexive Closure | 自反闭包 | r(R)=R∪IAr(R)=R \cup I_Ar(R)=R∪IA |
Symmetric Closure | 对称闭包 | s(R)=R∪R−1s(R)=R \cup R^{-1}s(R)=R∪R−1 |
Transitive Closure | 传递闭包 | t(R)=R∗t(R)=R^*t(R)=R∗ |
The diagonal relation on AAA: IA={(x,x) ∣ x∈A}I_A=\{(x,x) \, | \, x \in A\}IA={(x,x)∣x∈A}
The connectivity relation on AAA: R∗=⋃n=1∞RnR^*=\bigcup\limits_{n=1}^{\infty}{R^n}R∗=n=1⋃∞Rn
Collary: ∣A∣=n⟹t(R)=R∪R2∪⋯∪Rn|A|=n \Longrightarrow t(R)=R \cup R^2 \cup \cdots \cup R^n∣A∣=n⟹t(R)=R∪R2∪⋯∪Rn
Equivalence Relations and Partitions
Definition:
A relation RRR on set AAA is an equivalence relation iff RRR is reflexive, symmetric and transitive.
The equivalence class of x∈Ax \in Ax∈A via equivalence relation RRR is [x]R[x]_R[x]R, or [x][x][x] for short.
aaa and bbb of set AAA are equivalent by equivalence relation RRR ⟺ a∼b\iff a \sim b⟺a∼b
Remark:
Congruence Modulo mmm: R={(a,b) ∣ a≡b(modm),a,b∈Z}R=\{(a,b) \, | \, a \equiv b \pmod{m}, a,b \in \mathbb{Z}\}R={(a,b)∣a≡b(modm),a,b∈Z}
Congruence class Modulo mmm: [t]m={t+km ∣ 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+km∣k∈Z},t=0,1,2,…,m−1
Theroem:
Let RRR be an equivalence relation on set AAA.
aRb ⟺ [a]=[b] ⟺ [a]∩[b]≠∅aRb \iff [a]=[b] \iff [a] \cap [b] \neq \varnothingaRb⟺[a]=[b]⟺[a]∩[b]=∅
Theroem:
Let R1R_1R1 and R2R_2R2 be equivalence relations on AAA.
R1∩R2R_1 \cap R_2R1∩R2 is an equivalence relation, R1∪R2R_1 \cup R_2R1∪R2 is reflexive and symmetric.
Collary: (R1∪R2)∗(R_1 \cup R_2)^*(R1∪R2)∗ is an equivalence relation
Definition:
A partition of set AAA is a collection of disjoint nonempty subsets of AAA that have AAA as their union.
pr(A)={Ai ∣ i∈I}pr(A)=\{A_i \, | \, i \in I\}pr(A)={Ai∣i∈I}, where III is an index set, Ai≠∅A_i \neq \varnothingAi=∅, Ai∩Aj=∅(i≠j),⋃i∈IAi=AA_i \cap A_j=\varnothing(i \neq j), \bigcup\limits_{i \in I}{A_i}=AAi∩Aj=∅(i=j),i∈I⋃Ai=A.
Partial Orderings
Definition:
A relation RRR on set SSS is a partial ordering iff RRR is reflexive, antisymmetric and transitive.
For notation, (S,R)(S,R)(S,R) is a partially ordered set, or poset for short.
The elements aaa and bbb of a poset (S,≼)(S,\preccurlyeq)(S,≼) are comparable if either a≼ba \preccurlyeq ba≼b or b≼ab \preccurlyeq ab≼a.
When neither a≼ba \preccurlyeq ba≼b or b≼ab \preccurlyeq ab≼a, then aaa and bbb 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, SSS is totally ordered or linearly ordered.
In this case, ≼\preccurlyeq≼ is called a total order or linear order.
ENG | CHN | Denote |
---|---|---|
Maximal Element(s) | 极大值 | ∃a∈A(¬∃b∈A(a≺b))\exist a \in A(\neg \exist b \in A(a \prec b))∃a∈A(¬∃b∈A(a≺b)) |
Minimal Element(s) | 极小值 | ∃a∈A(¬∃b∈A(b≺a))\exist a \in A(\neg \exist b \in A(b \prec a))∃a∈A(¬∃b∈A(b≺a)) |
Greatest Element | 最大值 | ∃a∈A(∀b∈A(b≼a))\exist a \in A(\forall b \in A(b \preccurlyeq a))∃a∈A(∀b∈A(b≼a)) |
Least Element | 最小值 | ∃a∈A(∀b∈A(a≼b))\exist a \in A(\forall b \in A(a \preccurlyeq b))∃a∈A(∀b∈A(a≼b)) |
Upper Bound | 上界 | ∃a∈S(∀b∈A(b≺a))\exist a \in S(\forall b \in A(b \prec a))∃a∈S(∀b∈A(b≺a)) A⊆SA \subseteq SA⊆S |
Lower Bound | 下界 | ∃a∈S(∀b∈A(a≺b))\exist a \in S(\forall b \in A(a \prec b))∃a∈S(∀b∈A(a≺b)) A⊆SA \subseteq SA⊆S |
Least Upper Bound | 上确界 | mina\min{a}mina |
Greatest Lower Bound | 下确界 | maxa\max{a}maxa |
A poset (A,R)(A,R)(A,R) is well-ordered iff every nonempty subset of AAA has a least element.
A poset is called a lattice iff every pair of elements has a lub\mathrm{lub}lub and a glb\mathrm{glb}glb.
10. Graphs
Let G=(V,E)G=(V,E)G=(V,E) be an undirected graph with eee edges, then ∑v∈Vdeg(v)=2e\sum\limits_{v \in V}{\deg(v)}=2ev∈V∑deg(v)=2e.
Let G=(V,E)G=(V,E)G=(V,E) be a digraph, then ∑v∈Vdeg+(v)=∑v∈Vdeg−(v)=∣E∣\sum\limits_{v \in V}{\deg^+(v)}=\sum\limits_{v \in V}{\deg^-(v)}=|E|v∈V∑deg+(v)=v∈V∑deg−(v)=∣E∣.
Some Special Simple Graphs
Denote | i.e. |
---|---|
KnK_nKn | Complete Graph |
Cn (n≥3)C_n \ (n \ge 3)Cn (n≥3) | Cycle |
Wn (n≥3)W_n \ (n \ge 3)Wn (n≥3) | Wheel |
QnQ_nQn | nnn-Cube |
Km,n (m=∣V1∣,n=∣V2∣)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 nnn-regular if every vertex in this graph has degree nnn.
New Graphs from Old
Subgraph:
Let G=(V,E)G=(V,E)G=(V,E), H=(W,F)H=(W,F)H=(W,F).
HHH is a subgraph of GGG if W⊆VW \subseteq VW⊆V and F⊆EF \subseteq EF⊆E.
Subgraph HHH is a proper subgraph of GGG if H≠GH \neq GH=G.
HHH is a spanning subgraph of GGG if W=VW=VW=V and F⊆EF \subseteq EF⊆E.
Union:
Let G1=(V1,E1)G_1=(V_1,E_1)G1=(V1,E1), G2=(V2,E2)G_2=(V_2,E_2)G2=(V2,E2), then G1∪G2=(V1∪V2,E1∪E2)G_1 \cup G_2=(V_1 \cup V_2, E_1 \cup E_2)G1∪G2=(V1∪V2,E1∪E2).
Representing Graphs
Adjacency matrix: AG=[aij]nA_G=[a_{ij}]_nAG=[aij]n, aij=1a_{ij}=1aij=1 if {vi,vj}\{v_i,v_j\}{vi,vj} is an edge of GGG, or aij=0a_{ij}=0aij=0 otherwise.
Incidence matrix: MG=[mij]n×mM_G=[m_{ij}]_{n \times m}MG=[mij]n×m, mij=1m_{ij}=1mij=1 if eje_jej is incident with viv_ivi, or mij=0m_{ij}=0mij=0 otherwise.
Isomorphism(同构):
Formally, two simple graphs G1=(V1,E1)G_1=(V_1,E_1)G1=(V1,E1) and G2=(V2,E2)G_2=(V_2,E_2)G2=(V2,E2) are isomorphic.
If and only if there is an bijection fff from V1V_1V1 to V2V_2V2 such that ∀a,b∈V1\forall a, b \in V_1∀a,b∈V1.
aaa and bbb are adjacent in G1G_1G1 while f(a)f(a)f(a) and f(b)f(b)f(b) are adjacent in G2G_2G2.
Connectivity
The number of different paths of length rrr from viv_ivi to vjv_jvj is equal to the (i,j)(i, j)(i,j)-th entry of ArA^rAr.
The maximally connected subgraphs of GGG 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 aaa to bbb and from bbb to aaa for all vertices aaa and bbb 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 GGG is a path which visits every vertex in GGG 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 GGG be a simple graph with nnn (n≥3)(n \ge 3)(n≥3) vertices.
Dirac’s Theroem(狄拉克定理) If degv∈G(v)≥n2\deg\limits_{v \in G}(v)\ge \dfrac{n}{2}v∈Gdeg(v)≥2n, then GGG has a Hamilton circuit.
Ore’s Theroem(奥勒定理) If deg(u)+deg(v)≥n\deg(u)+\deg(v) \ge ndeg(u)+deg(v)≥n (∀u,v∈G,¬euv)(\forall u,v \in G, \neg e_{uv})(∀u,v∈G,¬euv), then GGG has a Hamilton circuit.
Planar Graphs
Euler’s formula:
Let GGG be a connected planar simple graph with eee edges and vvv vertices.
Let rrr be the number of regions in a planar representation of GGG.
Then we have the formula r=e−v+2r=e-v+2r=e−v+2.
Degree of Region:
Suppose RRR is a region of a connected planar simple graph.
The number of edges on the boundary of RRR is called the Degree of RRR, denoted by Deg(R)\mathrm{Deg}(R)Deg(R).
Collary:
If GGG is a connected planar simple graph with eee edges and vvv (v≥3)(v \ge 3)(v≥3) vertices, then e≤3v−6e \leq3v-6e≤3v−6.
2e=∑Ri∈GDeg(Ri)≥3r⟹r=e−v+2≤23e⟹e≤3v−62e=\sum\limits_{R_i \in G}{\mathrm{Deg}(R_i)} \ge 3r \Longrightarrow r=e-v+2 \leq \dfrac23 e \Longrightarrow e \leq 3v-62e=Ri∈G∑Deg(Ri)≥3r⟹r=e−v+2≤32e⟹e≤3v−6
If GGG is a connected planar simple graph, then GGG has a vertex viv_ivi with deg(vi)≤5\deg(v_i) \leq 5deg(vi)≤5.
(2e=∑vi∈Vdeg(vi)≥6v)∧(e≤3v−6⇔2e≤6v−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=vi∈V∑deg(vi)≥6v)∧(e≤3v−6⇔2e≤6v−12)=0
If G has eee edges and vvv (v≥3)(v \ge 3)(v≥3) vertices and no circuits of length 333,then e≤2v−4e \leq 2v-4e≤2v−4.
2e=∑Ri∈GDeg(Ri)≥4r⟹r=e−v+2≤12e⟹e≤2v−42e=\sum\limits_{R_i \in G}{\mathrm{Deg}(R_i)} \ge 4r \Longrightarrow r=e-v+2 \leq \dfrac12 e \Longrightarrow e \leq 2v-42e=Ri∈G∑Deg(Ri)≥4r⟹r=e−v+2≤21e⟹e≤2v−4
Generally, if every region of G has at least kkk edges, then e≤k(v−2)k−2e \leq \dfrac{k(v-2)}{k-2}e≤k−2k(v−2).
Homeomorphism(同胚):
The graph G1=(V1,E1)G_1=(V_1,E_1)G1=(V1,E1) and G2=(V2,E2)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 K3,3K_{3,3}K3,3 or K5K_5K5.
(updated 2021.5.14)