





Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!






Today is either Thursday or Friday On Thursdays I have to go to a lecture
Today is not Friday (alternatively, On Friday I have to go to the lecture) —————————————————– ∴ I have to go to a lecture today
p → q p ————– ∴ q
saying that there is at least one registered student, returns true if there is some student who is registered and false otherwise.
Table 1: Laws of boolean algebras, logic and sets Name Logic law Set theory law Boolean algebra law
Double Negation ¬¬p ⇐⇒ p A = A x = x DeMorgan’s laws ¬(p ∨ q) ⇐⇒ (¬p ∧ ¬q) A ∪ B = A ∩ B x + y = x · y ¬(p ∧ q) ⇐⇒ (¬p ∨ ¬q) A ∩ B = A ∪ B x · y = x + y Associativity (p ∨ q) ∨ r ⇐⇒ p ∨ (q ∨ r) (A ∪ B) ∪ C = A ∪ (B ∪ C) (x + y) + z = x + (y + z) (p ∧ q) ∧ r ⇐⇒ p ∧ (q ∧ r) (A ∩ B) ∩ C = A ∩ (B ∩ C) (x · y) · z = x · (y · z)
Commutativity p ∨ q ⇐⇒ q ∨ p A ∪ B = B ∪ A x + y = y + x p ∧ q ⇐⇒ q ∧ p A ∩ B = B ∩ A x · y = y · x
Distributivity p ∧ (q ∨ r) ⇐⇒ (p ∨ q) ∧ (p ∨ r) A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C) x · (y + z) = (x · y) + (x · z) p ∨ (q ∧ r) ⇐⇒ (p ∧ q) ∨ (p ∧ r) A ∪ (B ∩ C) = (A ∪ B) ∩ (A ∪ C) x + (y · z) = (x + y) · (x + z) Idempotence (p ∨ p) ⇐⇒ p ⇐⇒ (p ∧ p) A ∪ A = A = A ∩ A x + x = x = x · x Identity p ∨ F ⇐⇒ p ⇐⇒ p ∧ T A ∪ ∅ = A = A ∩ U x + 0 = x = x · 1 Inverse p ∨ ¬p ⇐⇒ T A ∪ A¯ = U x + ¯x = 1 p ∧ ¬p ⇐⇒ F A ∩ A¯ = ∅ x · x¯ = 0 Domination p ∨ T ⇐⇒ T A ∪ U = U x + 1 = 1 p ∧ F ⇐⇒ F A ∩ ∅ = ∅ x · 0 = 0
take f (x) =
2 x x ≥ 0 1 − 2 x x < 0
. It is one-to-one because f (x) = f (y) only if x = y, and it is onto
because for any y ∈ N, if it is even then its preimage is y/2, if it is odd − y− 2 1. Often it is easier to give instead two one-to-one functions, from the first set to the second and another from the second to the third. Also, often instead of a full description of a function it is enough to show that there is an enumeration such that every element of, say, Z is mapped to a distinct element of N. To show that one finite set is smaller than another, just compare the number of elements. To show that one infinite set is smaller than another, in particular that a set is uncountable, use diagonalization: suppose that a there is an enumeration of elements of a set, say, 2N^ by elements of N. List all elements of 2N^ according to that enumeration. Now, construct a new set which is not in the enumeration by making it differ from the kth^ element of the enumeration in the kth^ place (e.g., if the second set contains element 2, then the diagonal set will not contain the element 2, and vice versa).
about parallel lines, there are other possible models such as geometry on a sphere (where parallel lines intersect).
(P (n 0 ) ∧ ∀n ≥ n 0 (P (n) → P (n + 1))) → ∀n ≥ n 0 P (n)
That is, to prove that a statement is true for all (sufficiently large) n, it is enough to prove that it holds for the smallest n = n 0 (base case) and prove that if it holds for some arbitrary n > n 0 (induction hypothesis) then it also holds for the next value of n, n + 1 (induction step). A strong induction is a variant of induction in which instead of assuming that the statement holds for just one value of n we assume it holds for several: P (k) ∧ P (k + 1) ∧ · · · ∧ P (n) → P (n + 1) instead of just P (n) → P (n + 1). In particular, in complete induction k = n 0 , so we are assuming that the statement holds for all values smaller than n + 1. A well-ordering principle states that every set of natural numbers has the smallest element. It is used to prove statements by counterexample: e.g., “define set of elements for which P (n) does not hold. Take the smallest such n. Show that it is either not the smallest, or P (n) holds for it”. These three principles, Induction, Strong Induction and Well-ordering are equivalent. If you can prove a statement by one of them, you can prove it by the others. The following is the structure of an induction proof.
(a) P (n). State which assertion P (n) you are proving by induction. E.g., P (n): 2n^ < n!. (b) Base case: Prove P (n 0 ) (usually just put n 0 in the expression and check that it works). E.g., P (4): 2^4 < 4! holds because 2^4 = 16 and 4! = 24 and 16 < 24. (c) Induction hypothesis: “assume P (n) for some n > n 0 ”. I like to rewrite the statement for P (n) at this point, just to see what I am using. For example, “Assume 2n^ < n!”.