Student Responsibilities — Week 4 ◮ Reading : Textbook, Section 2.1–2.3 Mat 2345 ◮ Attendance : Strongly Encouraged Week 4 ◮ Week 4 Overview Fall 2013 ◮ 2.1 Sets ◮ 2.2 Set Operations ◮ 2.3 Functions 2.1 Sets Notation used to specify sets ◮ list the elements between braces ; listing an object more than once does not change the set—ordering means nothing. ◮ Set : an unordered collection or group of objects, which are said to be elements , or members of the set S = { a , b , c , d } = { b , c , a , d , d } ◮ Set builder notation – specify by predicate; here, S contains all ◮ A set is said to contain its elements elements from U which make the predicate P true S = { x | P ( x ) } ◮ There must be an underlying Universal Set, U , either specifically stated or understood ◮ brace notation with ellipses ; here, the negative integers: S = { . . . , − 3 , − 2 , − 1 } Common Universal Sets Notation ◮ R — Real Numbers ◮ x ∈ S — x is a member of S , or x is an element of S ◮ x ∈ S — x is not an element of S / ◮ N — Natural Numbers: { 0 , 1 , 2 , 3 , . . . } Set Equality — Definition #1 ◮ Z — Integers: { . . . , − 3 , − 2 , − 1 , 0 , 1 , 2 , 3 , . . . } ◮ Two sets are equal if and only if they have the same elements. ◮ Z + — Positive Integers ◮ That is, if A and B are sets, then A and B are equal if and only if ∀ x [ x ∈ A ↔ x ∈ B ]. ◮ Q — Rational Numbers: { p q | p , q ∈ Z ∧ q � = 0 } ◮ We write A = B if A and B are equal sets.
Subsets Power Set ◮ Subset : Let A and B be sets. Then ◮ Power Set : P ( A ) is the set of all possible subsets of the set A A ⊆ B ⇔ ∀ x [ x ∈ A → x ∈ B ] ◮ If A = { a , b } , then ◮ Empty, void, or Null Set : ∅ is the set with no members P ( A ) = { ∅ , { a } , { b } , { a , b }} ◮ the assertion x ∈ ∅ is always false , thus: ◮ What is the power set of the set B = { 0 , 1 , 2 } ? ∀ x [ x ∈ ∅ → x ∈ B ] is always (vacuously) true , and therefore ∅ is a subset of every set ◮ Note : a set B is always a subset of itself: B ⊆ B ◮ How many elements would P ( { a , b , c , d } ) have? ◮ Proper subset : A ⊂ B if A ⊆ B , but A � = B Cardinality Example ◮ Cardinality : | A | is the number of distinct elements in A ◮ Let A = { ∅ , { ∅ }} ◮ If the cardinality is a natural number (in N ), then the set is ◮ A has two elements and hence four subsets: called finite ; otherwise, it’s called infinite ∅ , { ∅ } , {{ ∅ }} , { ∅ , { ∅ }} ◮ Example : Let A = { a , b } ◮ Note that ∅ is both a member of A and a subset of A ◮ | A | = |{ a , b }| = 2 ◮ | P ( A ) | = | P ( { a , b } ) | = 4 ◮ Russell’s Paradox : Let S be the set of all sets which are not members of themselves. ◮ A is finite, and so is P ( A ) Is S a member of itself or not? ◮ Note 1 : | A | = n | P ( A ) | = 2 n → ◮ The Paradox of the Barber of Seville : The (male) barber of ◮ Note 2 : N is infinite since | N | is not a natural number — Seville shaves all and only men who do not shave themselves. it is called a transfinite cardinal number Who shaves the barber of Seville? ◮ Note 3 : Sets can be both members and subsets of other sets Cartesian Product ◮ Cartesian Product of A with B : A × B is the set of ordered ◮ The Cartesian product of the sets A 1 , A 2 , . . . , A n , denoted by pairs: { < a , b > | a ∈ A ∧ b ∈ B } A 1 × A 2 × · · · × A n is the set of ordered n –tuples < a 1 , a 2 , . . . , a n > , where a i ∈ A i for 1 ≤ i ≤ n . ◮ Notation : Π n i =1 A i = { < a 1 , a 2 , . . . , a n > | a i ∈ A i } , an n–tuple ◮ A 1 × A 2 × · · · × A n = { < a 1 , a 2 , . . . , a n > | a i ∈ A i , i = 1 , 2 , . . . , n } ◮ The Cartesian product of any set with ∅ is ∅ — why? ◮ Example 1 . Let A = { a , b } and B = { 1 , 2 , 3 } ◮ If A = { a , b } and B = { 1 , 2 , 3 } , what is A × B × A ? A × B = { < a , 1 >, < a , 2 >, < a , 3 >, < b , 1 >, < b , 2 >, < b , 3 > } What is B × A ? If | A | = m and | B | = n , what is | A × B | ?
Quantifiers Truth Sets The Universe of Discourse , also known as the Domain of ◮ Let P be a predicate and D a domain. The Truth Set of P is Discourse , is often referred to simply as the domain . the set of elements x ∈ D ∋ P ( x ) is true. The domain specifies the possible values of our variables. ◮ The truth set of P ( x ) is denoted: { x ∈ D | P ( x ) } We can use quantifiers to restrict the domain ◮ Assume the domain is the set of integers. What are the truth sets: ◮ ∀ x ∈ S [ P ( x )] denotes ∀ x [ x ∈ S → P ( x )] ◮ P = { x ∈ Z | | x | = 1 } Truth Set: Ex: ∀ x ∈ R [ x 2 ≥ 0] means: ◮ Q = { x ∈ Z | x 2 = 2 } for every real number x, x 2 is non-negative Truth Set: ◮ R = { x ∈ Z | | x | = x } Truth Set: Note : The meaning of the universal quantifier changes when we change the domain. ◮ Note : ∀ xP ( x ) is true over the domain U IFF the truth set of P is U . ◮ ∃ x ∈ S [ P ( x )] denotes ∃ x [ x ∈ S ∧ P ( x )] ◮ Note : ∃ xP ( x ) is true over the domain U IFF the truth set of Ex: ∃ x ∈ Z [ x 2 = 1] means: P � = ∅ . there exists an integer x such that x 2 = 1 2.2 Set Operations Equality of Sets By a previous logical equivalence, we have: ◮ Boolean Algebra : an algebraic system, instances of which are propositional calculus and set theory . A = B IFF ◮ The operators in set theory are defined in terms of the ∀ x [( x ∈ A → x ∈ B ) ∧ ( x ∈ B → x ∈ A )] corresponding operator in propositional calculus. — or another definition — ◮ As before, there must be a universe, U , and all sets are assumed to be subsets of U . A = B IFF A ⊆ B and B ⊆ A Set Operations More Set Operations ◮ Union of A and B , denoted A ∪ B , is the set { x | x ∈ A ∨ x ∈ B } ◮ Difference of A and B , or the complement of B relative to A , denoted A − B , is the set A ∩ B ◮ Intersection of A and B , denoted A ∩ B , is the set Note: The absolute complement of A is U − A { x | x ∈ A ∧ x ∈ B } If the intersection is void, A and B are said to be disjoint ◮ Symmetric Difference of A and B , denoted A ⊕ B , is the set ( A − B ) ∪ ( B − A ) ◮ Complement of A , denoted A , is the set { x | ¬ ( x ∈ A ) } = { x | x �∈ A }
Examples Venn Diagrams U = { 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 } A = { 1 , 2 , 3 , 4 , 5 } and B = { 4 , 5 , 6 , 7 , 8 } Venn Diagrams are a useful geometric visualization tool for 3 or fewer sets. ◮ A ∪ B = { 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 } ◮ The Universal set U is a rectangular box ◮ A ∩ B = { 4 , 5 } ◮ A = { 0 , 6 , 7 , 8 , 9 , 10 } ◮ Each set is represented by a circle and its interior ◮ B = { 0 , 1 , 2 , 3 , 9 , 10 } ◮ All possible combinations of the sets must be represented ◮ A − B = { 1 , 2 , 3 } ◮ Shade the appropriate region to represent the given set operation ◮ B − A = { 6 , 7 , 8 } ◮ A ⊕ B = { 1 , 2 , 3 , 6 , 7 , 8 } Examples U U A B A B For 2 sets A ∩ B U U A B A B C C For 3 sets A ∪ ( C ∩ B ) Set Identities Universal Instantiation Set identities correspond to the logical equivalences. We now apply an important rule of inference called Example Universal Instantiation The complement of the union is the intersection of the complements: In a proof, we can eliminate the universal quantifier A ∪ B = A ∩ B which binds a variable if we do not assume anything about the variable other than it is an arbitrary mem- To prove this statement, we would need to show: ber of the Universe. We can then treat the resulting ∀ x [ x ∈ A ∪ B ↔ x ∈ A ∩ B ] predicate as a proposition. To show two sets are equal : ◮ we can show for all x that x is a member of one set IFF it is a We say, “Let x be arbitrary.” Then we can treat the predicates member of the other, or as propositions. ◮ show that each is a subset of the other
Recommend
More recommend