2.1 Sets 2.2 Set Operations –Set Operations –Venn Diagrams –Set Identities –Union and Intersection of Indexed Collections 2.3 Functions 2.4 Sequences and.

Slides:



Advertisements
Similar presentations
Functions Reading: Epp Chp 7.1, 7.2, 7.4
Advertisements

Set Operations. When sets are equal A equals B iff for all x, x is in A iff x is in B or … and this is what we do to prove sets equal.
Union Definition: The union of sets A and B, denoted by A B, contains those elements that are in A or B or both: Example: { 1, 2, 3} {3, 4, 5} = { 1,
Basic Structures: Sets, Functions, Sequences, Sums, and Matrices
Discrete Structures & Algorithms Basics of Set Theory EECE 320 — UBC.
© by Kenneth H. Rosen, Discrete Mathematics & its Applications, Sixth Edition, Mc Graw-Hill, 2007 Chapter 1: (Part 2): The Foundations: Logic and Proofs.
Instructor: Hayk Melikya
(CSC 102) Discrete Structures Lecture 14.
2.1 Sets ‒Sets ‒Common Universal Sets ‒Subsets 2.2 Set Operations 2.3 Functions 2.4 Sequences and Summations 1.
Basic Structures: Sets, Functions, Sequences, Sums, and Matrices
Week 21 Basic Set Theory A set is a collection of elements. Use capital letters, A, B, C to denotes sets and small letters a 1, a 2, … to denote the elements.
1 Section 1.7 Set Operations. 2 Union The union of 2 sets A and B is the set containing elements found either in A, or in B, or in both The denotation.
SET.   A set is a collection of elements.   Sets are usually denoted by capital letters A, B, Ω, etc.   Elements are usually denoted by lower case.
Copyright © Zeph Grunschlag, Set Operations Zeph Grunschlag.
From Chapter 4 Formal Specification using Z David Lightfoot
Sets 1.
Sets 1.
Computing Fundamentals 1 Lecture 6 A Theory of Sets Lecturer: Patrick Browne Room K308 Based on Chapter 11. A Logical approach.
Rosen 1.6. Approaches to Proofs Membership tables (similar to truth tables) Convert to a problem in propositional logic, prove, then convert back Use.
Set Notation.
This section will discuss the symbolism and concepts of set theory
© by Kenneth H. Rosen, Discrete Mathematics & its Applications, Sifth Edition, Mc Graw-Hill, 2007 Chapter 2: Basic Structures: Sets, Functions, Sequences.
A Brief Summary for Exam 1 Subject Topics Propositional Logic (sections 1.1, 1.2) –Propositions Statement, Truth value, Proposition, Propositional symbol,
Chapter 3 – Set Theory  .
CSE 311 Foundations of Computing I Lecture 8 Proofs and Set Theory Spring
Barnett/Ziegler/Byleen Finite Mathematics 11e1 Chapter 7 Review Important Terms, Symbols, Concepts 7.1. Logic A proposition is a statement (not a question.
Set Theory Dr. Ahmed Elmoasry. Contents Ch I: Experiments, Models, and Probabilities. Ch II: Discrete Random Variables Ch III: Discrete Random Variables.
Discrete Structure Sets. 2 Set Theory Set: Collection of objects (“elements”) a  A “a is an element of A” “a is a member of A” a  A “a is not an element.
DISCRETE COMPUTATIONAL STRUCTURES
Propositional Calculus CS 270: Mathematical Foundations of Computer Science Jeremy Johnson.
CS201: Data Structures and Discrete Mathematics I
2.1 Sets ‒Sets ‒Common Universal Sets ‒Subsets 2.2 Set Operations 2.3 Functions 2.4 Sequences and Summations 1.
CompSci 102 Discrete Math for Computer Science
Copyright © Cengage Learning. All rights reserved.
Naïve Set Theory. Basic Definitions Naïve set theory is the non-axiomatic treatment of set theory. In the axiomatic treatment, which we will only allude.
1 Introduction to Abstract Mathematics Sets Section 2.1 Basic Notions of Sets Section 2.2 Operations with sets Section 2.3 Indexed Sets Instructor: Hayk.
Set Operations Chapter 2 Sec 3. Union What does the word mean to you? What does it mean in mathematics?
Mathematical Preliminaries
CSE 311 Foundations of Computing I Lecture 9 Proofs and Set Theory Autumn 2012 CSE
Chapter 2 With Question/Answer Animations. Section 2.1.
Review 2 Basic Definitions Set - Collection of objects, usually denoted by capital letter Member, element - Object in a set, usually denoted by lower.
Basic Definitions of Set Theory Lecture 24 Section 5.1 Fri, Mar 2, 2007.
Discrete Mathematics CS 2610 January 27, part 2.
Copyright Curt Hill Euler Circles With Venn Diagrams Thrown in for Good Measure.
CSE 311: Foundations of Computing Fall 2013 Lecture 8: Proofs and Set theory.
Basic Definitions of Set Theory Lecture 23 Section 5.1 Mon, Feb 21, 2005.
Set Operations Section 2.2.
The Basic Concepts of Set Theory. Chapter 1 Set Operations and Cartesian Products.
Chapter 2 1. Chapter Summary Sets (This Slide) The Language of Sets - Sec 2.1 – Lecture 8 Set Operations and Set Identities - Sec 2.2 – Lecture 9 Functions.
Venn Diagrams.
Section 6.1 Set and Set Operations. Set: A set is a collection of objects/elements. Ex. A = {w, a, r, d} Sets are often named with capital letters. Order.
Set Operators Goals Show how set identities are established
Sets (2.1) A set is a collection or group of objects or elements or members. (Cantor 1895) A set is said to contain its elements. There must be an underlying.
Chapter 2 Sets and Functions.
CHAPTER 3 SETS, BOOLEAN ALGEBRA & LOGIC CIRCUITS
The Language of Sets If S is a set, then
Copyright © Zeph Grunschlag,
Discrete Mathematical The Set Theory
Lecture 04 Set Theory Profs. Koike and Yukita
Chapter 1 Logic and Proofs Homework 2 Given the statement “A valid password is necessary for you to log on to the campus server.” Express the statement.
Taibah University College of Computer Science & Engineering Course Title: Discrete Mathematics Code: CS 103 Chapter 2 Sets Slides are adopted from “Discrete.
Set Theory A B C.
Set Operations Section 2.2.
Session – 2 SETS & Operations of SETS
A Brief Summary for Exam 1
L5 Set Operations.
Chapter 7 Logic, Sets, and Counting
Lecture Sets 2.2 Set Operations.
Logic Logic is a discipline that studies the principles and methods used to construct valid arguments. An argument is a related sequence of statements.
Set Theoretic Operations
Presentation transcript:

2.1 Sets 2.2 Set Operations –Set Operations –Venn Diagrams –Set Identities –Union and Intersection of Indexed Collections 2.3 Functions 2.4 Sequences and Summations P. 1 1

Propositional calculus and set theory are both instances of an algebraic system called a Boolean Algebra. The operators in set theory are defined in terms of the corresponding operator in propositional calculus. As always there must be a universe U. All sets are assumed to be subsets of U. P. 1 Set Operations 2

Definition: Two sets A and B are equal, denoted A = B, iff  x[x  A ↔ x  B]. Note: By a previous logical equivalence we have A = B iff  x[(x  A→ x  B) Λ (x  B → x  A)] or A = B iff A  B and B  A P. 1 Set Operations 3

Definitions: –The union of A and B, denoted A  B, is the set {x | x  A V x  B} –The intersection of A and B, denoted A  B, is the set {x | x  A Λ x  B} P. 1 Set Operations 4 FIGURE 1 FIGURE 2

Note: If the intersection is void, A and B are said to be disjoint. – The complement of A, denoted, is the set {x | x  A}={x | ¬(x  A)} Note: Alternative notation is, and {x|x  A}. – The difference of A and B, or the complement of B relative to A, denoted A - B, is the set A  Note: The complement of A is U - A. – The symmetric difference of A and B, denoted A  B, is the set (A - B)  (B - A). P. 1 Set Operations 5

Examples: U = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10} A= {1, 2, 3, 4, 5}, B = {4, 5, 6, 7, 8}. Then – A  B = {1, 2, 3, 4, 5, 6, 7, 8} – A  B = {4, 5} – = {0, 6, 7, 8, 9, 10} – = {0, 1, 2, 3, 9, 10} – A - B = {1, 2, 3} – B - A = {6, 7, 8} – A  B = {1, 2, 3, 6, 7, 8} P. 1 Set Operations 6

A useful geometric visualization tool (for 3 or less sets) – The Universe U is the rectangular box. – Each set is represented by a circle and its interior. – All possible combinations of the sets must be represented. Shade the appropriate region to represent the given set operation. P. 1 Venn Diagrams 7

Set identities correspond to the logical equivalences. Example: The complement of the union is the intersection of the complements P. 1 Set Identities 8

Proof: To show To show two sets are equal we show for all x that x is a member of one set if and only if it is a member of the other. We now apply an important rule of inference (defined later) called Universal Instantiation 9

Set Identities Universal Instantiation In a proof we can eliminate the universal quantifier which binds a variable if we do not assume anything about the variable other than it is an arbitrary member of the Universe. We can then treat the resulting predicate as a proposition. 10

We say 'Let x be arbitrary. ' Then we can treat the predicates as propositions: Assertion Reason Def. of complement ¬ Def. of   ¬ Def. of union  ¬ x  A Λ ¬ x  B DeMorgan's Laws Def. of  Def. of complement Def. of intersection Hence is a tautology. P. 1 Set Identities 11

Since – x was arbitrary – we have used only logically equivalent assertions and definitions we can apply another rule of inference called Universal Generalization We can apply a universal quantifier to bind a variable if we have shown the predicate to be true for all values of the variable in the Universe. and claim the assertion is true for all x, i.e., P. 1 Set Identities

Q. E. D. (an abbreviation for the Latin phrase “Quod Erat Demonstrandum” - “which was to be demonstrated” used to signal the end of a proof) Note: As an alternative which might be easier in some cases, use the identity 13

Example: Show A  (B - A) = Ø The void set is a subset of every set. Hence, A  (B - A)  Ø Therefore, it suffices to show A  (B - A)  Ø or  x[x  A  (B - A) → x  Ø] P. 1 Set Identities 14

Set Identities So as before we say 'let x be arbitrary’. Show x  A  (B- A) → x  Ø is a tautology. But the consequent is always false. Therefore, the antecedent better always be false also. 15

Solution: Apply the definitions: Assertion Reason x  A  (B- A)  x  A Λ x  (B- A) by Def. of   x  A Λ (x  B Λ x  A) by Def. of -  (x  A Λ x  A) Λ x  B by Def. of Associative  0 Λ x  B by Def. of Complement  0 (false) by Def. of Domination P. 1 Set Identities 16

Let A 1,A 2,..., A n be an indexed collection of sets. Definition: The union of a collection of sets is the set that contains those elements that are members of at least one set in the collection. we use the notation to denote the union of the sets A 1,A 2,..., A n P. 1 Union and Intersection of Indexed Collections 17

Union and Intersection of Indexed Collections Definition: The intersection of a collection of sets is the set that contains those elements that are members of all the set in the collection. we use the notation to denote the intersection of the sets A 1,A 2,..., A n 18

Examples: Let P. 1 Union and Intersection of Indexed Collections 19

Boolean Algebra Set operations Union Intersection Complement Difference P. 1 Terms 20 Symmetric difference Venn Diagram Set Identities Universal Instantiation Universal Generalization