308
Basic Structures: Sets, Functions, Sequences, Sums, and Matrices Chapter 2 Marc Moreno-Maza 2020 UWO – October 3, 2021

Basic Structures: Sets, Functions, Sequences, Sums, and

  • Upload
    others

  • View
    7

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Basic Structures: Sets, Functions, Sequences, Sums, and

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

Chapter 2

© Marc Moreno-Maza 2020

UWO – October 3, 2021

Page 2: Basic Structures: Sets, Functions, Sequences, Sums, and

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

Chapter 2

© Marc Moreno-Maza 2020

UWO – October 3, 2021

Page 3: Basic Structures: Sets, Functions, Sequences, Sums, and

Introduction

1 Sets are the basic building blocks for the types of objectsconsidered in discrete mathematics and in mathematics, ingeneral.

2 Set theory is an important branch of mathematics:

a Many different systems of axioms have been used to developset theory.

b Here, we are not concerned with a formal set of axioms for settheory.

c Instead, we will use what is called naıve set theory.

Page 4: Basic Structures: Sets, Functions, Sequences, Sums, and

Introduction

1 Sets are the basic building blocks for the types of objectsconsidered in discrete mathematics and in mathematics, ingeneral.

2 Set theory is an important branch of mathematics:

a Many different systems of axioms have been used to developset theory.

b Here, we are not concerned with a formal set of axioms for settheory.

c Instead, we will use what is called naıve set theory.

Page 5: Basic Structures: Sets, Functions, Sequences, Sums, and

Introduction

1 Sets are the basic building blocks for the types of objectsconsidered in discrete mathematics and in mathematics, ingeneral.

2 Set theory is an important branch of mathematics:

a Many different systems of axioms have been used to developset theory.

b Here, we are not concerned with a formal set of axioms for settheory.

c Instead, we will use what is called naıve set theory.

Page 6: Basic Structures: Sets, Functions, Sequences, Sums, and

Introduction

1 Sets are the basic building blocks for the types of objectsconsidered in discrete mathematics and in mathematics, ingeneral.

2 Set theory is an important branch of mathematics:

a Many different systems of axioms have been used to developset theory.

b Here, we are not concerned with a formal set of axioms for settheory.

c Instead, we will use what is called naıve set theory.

Page 7: Basic Structures: Sets, Functions, Sequences, Sums, and

Introduction

1 Sets are the basic building blocks for the types of objectsconsidered in discrete mathematics and in mathematics, ingeneral.

2 Set theory is an important branch of mathematics:

a Many different systems of axioms have been used to developset theory.

b Here, we are not concerned with a formal set of axioms for settheory.

c Instead, we will use what is called naıve set theory.

Page 8: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 9: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 10: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets

1 A set is an unordered collection of “objects”, e.g. intuitivelydescribed by some common property or properties (in naıveset theory):

a the students in this class,b the chairs in this room.

2 The objects in a set are called the elements, or members ofthe set. A set is said to contain its elements.

3 The notation a ∈ A denotes that a is an element of set A.

4 If a is not a member of A, write a ∉ A

Page 11: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets

1 A set is an unordered collection of “objects”, e.g. intuitivelydescribed by some common property or properties (in naıveset theory):

a the students in this class,

b the chairs in this room.

2 The objects in a set are called the elements, or members ofthe set. A set is said to contain its elements.

3 The notation a ∈ A denotes that a is an element of set A.

4 If a is not a member of A, write a ∉ A

Page 12: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets

1 A set is an unordered collection of “objects”, e.g. intuitivelydescribed by some common property or properties (in naıveset theory):

a the students in this class,b the chairs in this room.

2 The objects in a set are called the elements, or members ofthe set. A set is said to contain its elements.

3 The notation a ∈ A denotes that a is an element of set A.

4 If a is not a member of A, write a ∉ A

Page 13: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets

1 A set is an unordered collection of “objects”, e.g. intuitivelydescribed by some common property or properties (in naıveset theory):

a the students in this class,b the chairs in this room.

2 The objects in a set are called the elements, or members ofthe set. A set is said to contain its elements.

3 The notation a ∈ A denotes that a is an element of set A.

4 If a is not a member of A, write a ∉ A

Page 14: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets

1 A set is an unordered collection of “objects”, e.g. intuitivelydescribed by some common property or properties (in naıveset theory):

a the students in this class,b the chairs in this room.

2 The objects in a set are called the elements, or members ofthe set. A set is said to contain its elements.

3 The notation a ∈ A denotes that a is an element of set A.

4 If a is not a member of A, write a ∉ A

Page 15: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets

1 A set is an unordered collection of “objects”, e.g. intuitivelydescribed by some common property or properties (in naıveset theory):

a the students in this class,b the chairs in this room.

2 The objects in a set are called the elements, or members ofthe set. A set is said to contain its elements.

3 The notation a ∈ A denotes that a is an element of set A.

4 If a is not a member of A, write a ∉ A

Page 16: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}

3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}

5 Ellipses (. . . ) may be used to describe a set without listing allof the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 17: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}

2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}

3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}

5 Ellipses (. . . ) may be used to describe a set without listing allof the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 18: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}

3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}

5 Ellipses (. . . ) may be used to describe a set without listing allof the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 19: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}

5 Ellipses (. . . ) may be used to describe a set without listing allof the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 20: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}5 Ellipses (. . . ) may be used to describe a set without listing all

of the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 21: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}

5 Ellipses (. . . ) may be used to describe a set without listing allof the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 22: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}5 Ellipses (. . . ) may be used to describe a set without listing all

of the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 23: Basic Structures: Sets, Functions, Sequences, Sums, and

Describing a set: the roster method

The roster method is defined as a way to show the members of aset by listing the members inside of brackets.

1 Example: S = {a,b, c ,d}2 The order of the elements in that list is not important.

a For instance, {a,b, c ,d} = {b, c , a,d}3 Each object in the universe is either a member or not.

4 Listing a member more than once does not change the set.

a For instance, {a,b, c ,d} = {a,b, c ,b, c ,d}5 Ellipses (. . . ) may be used to describe a set without listing all

of the members when the pattern is clear:

a For instance, S = {a,b, c ,d , . . . , z}.

Page 24: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 25: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}

2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 26: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 27: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}

3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 28: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 29: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}

4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 30: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 31: Basic Structures: Sets, Functions, Sequences, Sums, and

The roster method: more examples

1 The set of all vowels in the English alphabet:

V = {a,e,i,o,u}2 The set of all odd positive integers less than 10:

O = {1,3,5,7,9}3 The set of all positive integers less than 100:

S = {1,2,3,. . . ,99}4 The set of all integers less than 0:

S = {. . . , -3,-2,-1}

Page 32: Basic Structures: Sets, Functions, Sequences, Sums, and

Some important sets

N = natural numbers = {0,1,2,3, . . .}

Z = integers = {. . . ,−3,−2,−1,0,1,2,3, . . .}Z+ = positive integers = {1,2,3, . . .}Q = set of rational numbers

R = set of real numbers

R+ = set of positive real numbers

C = set of complex numbers.

Page 33: Basic Structures: Sets, Functions, Sequences, Sums, and

Some important sets

N = natural numbers = {0,1,2,3, . . .}Z = integers = {. . . ,−3,−2,−1,0,1,2,3, . . .}

Z+ = positive integers = {1,2,3, . . .}Q = set of rational numbers

R = set of real numbers

R+ = set of positive real numbers

C = set of complex numbers.

Page 34: Basic Structures: Sets, Functions, Sequences, Sums, and

Some important sets

N = natural numbers = {0,1,2,3, . . .}Z = integers = {. . . ,−3,−2,−1,0,1,2,3, . . .}Z+ = positive integers = {1,2,3, . . .}

Q = set of rational numbers

R = set of real numbers

R+ = set of positive real numbers

C = set of complex numbers.

Page 35: Basic Structures: Sets, Functions, Sequences, Sums, and

Some important sets

N = natural numbers = {0,1,2,3, . . .}Z = integers = {. . . ,−3,−2,−1,0,1,2,3, . . .}Z+ = positive integers = {1,2,3, . . .}Q = set of rational numbers

R = set of real numbers

R+ = set of positive real numbers

C = set of complex numbers.

Page 36: Basic Structures: Sets, Functions, Sequences, Sums, and

Some important sets

N = natural numbers = {0,1,2,3, . . .}Z = integers = {. . . ,−3,−2,−1,0,1,2,3, . . .}Z+ = positive integers = {1,2,3, . . .}Q = set of rational numbers

R = set of real numbers

R+ = set of positive real numbers

C = set of complex numbers.

Page 37: Basic Structures: Sets, Functions, Sequences, Sums, and

Some important sets

N = natural numbers = {0,1,2,3, . . .}Z = integers = {. . . ,−3,−2,−1,0,1,2,3, . . .}Z+ = positive integers = {1,2,3, . . .}Q = set of rational numbers

R = set of real numbers

R+ = set of positive real numbers

C = set of complex numbers.

Page 38: Basic Structures: Sets, Functions, Sequences, Sums, and

Some important sets

N = natural numbers = {0,1,2,3, . . .}Z = integers = {. . . ,−3,−2,−1,0,1,2,3, . . .}Z+ = positive integers = {1,2,3, . . .}Q = set of rational numbers

R = set of real numbers

R+ = set of positive real numbers

C = set of complex numbers.

Page 39: Basic Structures: Sets, Functions, Sequences, Sums, and

The set-builder notation

1 It is used to specify the property or properties that allmembers must satisfy. Examples:

a S = {x ∣ x is a positive integer less than 100}b O = {x ∣ x is an odd positive integer less than 10}c O = {x ∈ Z+ ∣ x is odd and x < 10}d the set of positive rational numbers:

Q+ = {x ∈ R ∣ x = pq

, for some positive integers p,q}2 A predicate may be used, as in S = {x ∣ P(x)}

a Example: S = {x ∣ Prime(x)}

Page 40: Basic Structures: Sets, Functions, Sequences, Sums, and

The set-builder notation

1 It is used to specify the property or properties that allmembers must satisfy. Examples:

a S = {x ∣ x is a positive integer less than 100}

b O = {x ∣ x is an odd positive integer less than 10}c O = {x ∈ Z+ ∣ x is odd and x < 10}d the set of positive rational numbers:

Q+ = {x ∈ R ∣ x = pq

, for some positive integers p,q}2 A predicate may be used, as in S = {x ∣ P(x)}

a Example: S = {x ∣ Prime(x)}

Page 41: Basic Structures: Sets, Functions, Sequences, Sums, and

The set-builder notation

1 It is used to specify the property or properties that allmembers must satisfy. Examples:

a S = {x ∣ x is a positive integer less than 100}b O = {x ∣ x is an odd positive integer less than 10}

c O = {x ∈ Z+ ∣ x is odd and x < 10}d the set of positive rational numbers:

Q+ = {x ∈ R ∣ x = pq

, for some positive integers p,q}2 A predicate may be used, as in S = {x ∣ P(x)}

a Example: S = {x ∣ Prime(x)}

Page 42: Basic Structures: Sets, Functions, Sequences, Sums, and

The set-builder notation

1 It is used to specify the property or properties that allmembers must satisfy. Examples:

a S = {x ∣ x is a positive integer less than 100}b O = {x ∣ x is an odd positive integer less than 10}c O = {x ∈ Z+ ∣ x is odd and x < 10}

d the set of positive rational numbers:

Q+ = {x ∈ R ∣ x = pq

, for some positive integers p,q}2 A predicate may be used, as in S = {x ∣ P(x)}

a Example: S = {x ∣ Prime(x)}

Page 43: Basic Structures: Sets, Functions, Sequences, Sums, and

The set-builder notation

1 It is used to specify the property or properties that allmembers must satisfy. Examples:

a S = {x ∣ x is a positive integer less than 100}b O = {x ∣ x is an odd positive integer less than 10}c O = {x ∈ Z+ ∣ x is odd and x < 10}d the set of positive rational numbers:

Q+ = {x ∈ R ∣ x = pq

, for some positive integers p,q}

2 A predicate may be used, as in S = {x ∣ P(x)}

a Example: S = {x ∣ Prime(x)}

Page 44: Basic Structures: Sets, Functions, Sequences, Sums, and

The set-builder notation

1 It is used to specify the property or properties that allmembers must satisfy. Examples:

a S = {x ∣ x is a positive integer less than 100}b O = {x ∣ x is an odd positive integer less than 10}c O = {x ∈ Z+ ∣ x is odd and x < 10}d the set of positive rational numbers:

Q+ = {x ∈ R ∣ x = pq

, for some positive integers p,q}2 A predicate may be used, as in S = {x ∣ P(x)}

a Example: S = {x ∣ Prime(x)}

Page 45: Basic Structures: Sets, Functions, Sequences, Sums, and

The set-builder notation

1 It is used to specify the property or properties that allmembers must satisfy. Examples:

a S = {x ∣ x is a positive integer less than 100}b O = {x ∣ x is an odd positive integer less than 10}c O = {x ∈ Z+ ∣ x is odd and x < 10}d the set of positive rational numbers:

Q+ = {x ∈ R ∣ x = pq

, for some positive integers p,q}2 A predicate may be used, as in S = {x ∣ P(x)}

a Example: S = {x ∣ Prime(x)}

Page 46: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:

▸ [a,b] = {x ∣ a ≤ x ≤ b}▸ [a,b) = {x ∣ a ≤ x < b}▸ (a,b] = {x ∣ a < x ≤ b}▸ (a,b) = {x ∣ a < x < b}▸ closed interval [a,b]▸ open interval (a,b)

Page 47: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:

▸ [a,b] = {x ∣ a ≤ x ≤ b}▸ [a,b) = {x ∣ a ≤ x < b}▸ (a,b] = {x ∣ a < x ≤ b}▸ (a,b) = {x ∣ a < x < b}▸ closed interval [a,b]▸ open interval (a,b)

Page 48: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:▸ [a,b] = {x ∣ a ≤ x ≤ b}

▸ [a,b) = {x ∣ a ≤ x < b}▸ (a,b] = {x ∣ a < x ≤ b}▸ (a,b) = {x ∣ a < x < b}▸ closed interval [a,b]▸ open interval (a,b)

Page 49: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:▸ [a,b] = {x ∣ a ≤ x ≤ b}▸ [a,b) = {x ∣ a ≤ x < b}

▸ (a,b] = {x ∣ a < x ≤ b}▸ (a,b) = {x ∣ a < x < b}▸ closed interval [a,b]▸ open interval (a,b)

Page 50: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:▸ [a,b] = {x ∣ a ≤ x ≤ b}▸ [a,b) = {x ∣ a ≤ x < b}▸ (a,b] = {x ∣ a < x ≤ b}

▸ (a,b) = {x ∣ a < x < b}▸ closed interval [a,b]▸ open interval (a,b)

Page 51: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:▸ [a,b] = {x ∣ a ≤ x ≤ b}▸ [a,b) = {x ∣ a ≤ x < b}▸ (a,b] = {x ∣ a < x ≤ b}▸ (a,b) = {x ∣ a < x < b}

▸ closed interval [a,b]▸ open interval (a,b)

Page 52: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:▸ [a,b] = {x ∣ a ≤ x ≤ b}▸ [a,b) = {x ∣ a ≤ x < b}▸ (a,b] = {x ∣ a < x ≤ b}▸ (a,b) = {x ∣ a < x < b}▸ closed interval [a,b]

▸ open interval (a,b)

Page 53: Basic Structures: Sets, Functions, Sequences, Sums, and

The interval notation

1 It is used to specify a range of real numbers.

2 Consider two real numbers a,b with a ≤ b. The followingnotations are commonly used:▸ [a,b] = {x ∣ a ≤ x ≤ b}▸ [a,b) = {x ∣ a ≤ x < b}▸ (a,b] = {x ∣ a < x ≤ b}▸ (a,b) = {x ∣ a < x < b}▸ closed interval [a,b]▸ open interval (a,b)

Page 54: Basic Structures: Sets, Functions, Sequences, Sums, and

Truth sets of quantifiers

1 Given a predicate P and a domain D, we define the truth setof P to be the set of the elements in D for which P(x) is true.

2 The truth set of P(x) is denoted by:

{x ∈ D ∣ P(x)}

3 Example: The truth set of P(x) where the domain is theintegers and P(x) is “∣x ∣ = 1” is the set {-1,1}

Page 55: Basic Structures: Sets, Functions, Sequences, Sums, and

Truth sets of quantifiers

1 Given a predicate P and a domain D, we define the truth setof P to be the set of the elements in D for which P(x) is true.

2 The truth set of P(x) is denoted by:

{x ∈ D ∣ P(x)}

3 Example: The truth set of P(x) where the domain is theintegers and P(x) is “∣x ∣ = 1” is the set {-1,1}

Page 56: Basic Structures: Sets, Functions, Sequences, Sums, and

Truth sets of quantifiers

1 Given a predicate P and a domain D, we define the truth setof P to be the set of the elements in D for which P(x) is true.

2 The truth set of P(x) is denoted by:

{x ∈ D ∣ P(x)}

3 Example: The truth set of P(x) where the domain is theintegers and P(x) is “∣x ∣ = 1” is the set {-1,1}

Page 57: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets can be elements of sets

Examples:

1 {{1,2,3},a, {b, c}}2 {N,Z,Q,R}

Page 58: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets can be elements of sets

Examples:

1 {{1,2,3},a, {b, c}}

2 {N,Z,Q,R}

Page 59: Basic Structures: Sets, Functions, Sequences, Sums, and

Sets can be elements of sets

Examples:

1 {{1,2,3},a, {b, c}}2 {N,Z,Q,R}

Page 60: Basic Structures: Sets, Functions, Sequences, Sums, and

Russell’s paradox

1 Let S be the set of all sets which are not members ofthemselves.

2 A paradox results from trying to answer the question “Is S amember of itself?”

Related simple example:

a Henry is a barber who shaves allpeople who do not shave themselves. Aparadox results from trying to answer thequestion “Does Henry shave himself?”

Bertrand Russell

(1872 - 1970)

Nobel Prize

Winner,

Cambridge, UK

1 To avoid this and other paradoxes, sets can be (formally)defined via appropriate axioms more carefully than just anunordered collection of “objects”

2 where objects are intuitively described by any given property in

naıve set theory

Page 61: Basic Structures: Sets, Functions, Sequences, Sums, and

Russell’s paradox

1 Let S be the set of all sets which are not members ofthemselves.

2 A paradox results from trying to answer the question “Is S amember of itself?”

Related simple example:

a Henry is a barber who shaves allpeople who do not shave themselves. Aparadox results from trying to answer thequestion “Does Henry shave himself?”

Bertrand Russell

(1872 - 1970)

Nobel Prize

Winner,

Cambridge, UK

1 To avoid this and other paradoxes, sets can be (formally)defined via appropriate axioms more carefully than just anunordered collection of “objects”

2 where objects are intuitively described by any given property in

naıve set theory

Page 62: Basic Structures: Sets, Functions, Sequences, Sums, and

Russell’s paradox

1 Let S be the set of all sets which are not members ofthemselves.

2 A paradox results from trying to answer the question “Is S amember of itself?”

Related simple example:

a Henry is a barber who shaves allpeople who do not shave themselves. Aparadox results from trying to answer thequestion “Does Henry shave himself?”

Bertrand Russell

(1872 - 1970)

Nobel Prize

Winner,

Cambridge, UK

1 To avoid this and other paradoxes, sets can be (formally)defined via appropriate axioms more carefully than just anunordered collection of “objects”

2 where objects are intuitively described by any given property in

naıve set theory

Page 63: Basic Structures: Sets, Functions, Sequences, Sums, and

Russell’s paradox

1 Let S be the set of all sets which are not members ofthemselves.

2 A paradox results from trying to answer the question “Is S amember of itself?”

Related simple example:

a Henry is a barber who shaves allpeople who do not shave themselves. Aparadox results from trying to answer thequestion “Does Henry shave himself?”

Bertrand Russell

(1872 - 1970)

Nobel Prize

Winner,

Cambridge, UK

1 To avoid this and other paradoxes, sets can be (formally)defined via appropriate axioms more carefully than just anunordered collection of “objects”

2 where objects are intuitively described by any given property in

naıve set theory

Page 64: Basic Structures: Sets, Functions, Sequences, Sums, and

Russell’s paradox

1 Let S be the set of all sets which are not members ofthemselves.

2 A paradox results from trying to answer the question “Is S amember of itself?”

Related simple example:

a Henry is a barber who shaves allpeople who do not shave themselves. Aparadox results from trying to answer thequestion “Does Henry shave himself?”

Bertrand Russell

(1872 - 1970)

Nobel Prize

Winner,

Cambridge, UK

1 To avoid this and other paradoxes, sets can be (formally)defined via appropriate axioms more carefully than just anunordered collection of “objects”

2 where objects are intuitively described by any given property in

naıve set theory

Page 65: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 66: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 67: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,

b sometimes implicitly stated,c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 68: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,

c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 69: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,c sometimes explicitly stated,

d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 70: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 71: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 72: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.

b Important: the empty set is different from a set containingthe empty set:

∅ ≠ { ∅ }

Page 73: Basic Structures: Sets, Functions, Sequences, Sums, and

The universal set U and the empty set ∅

1 The universal set is the set containing all the “objects”currently under consideration:

a often symbolized by U,b sometimes implicitly stated,c sometimes explicitly stated,d its contents depend on the context.

2 The empty set is the set with no elements.

a symbolized by ∅, but {} is also used.b Important: the empty set is different from a set containing

the empty set:

∅ ≠ { ∅ }

Page 74: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 75: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

Sets and their elements can be represented via Venn diagrams

◻ – Universal set U● – elements◯ – Some set V

Page 76: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

Sets and their elements can be represented via Venn diagrams

◻ – Universal set U

● – elements◯ – Some set V

Page 77: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

Sets and their elements can be represented via Venn diagrams

◻ – Universal set U● – elements

◯ – Some set V

Page 78: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

Sets and their elements can be represented via Venn diagrams

◻ – Universal set U● – elements◯ – Some set V

Page 79: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal setU: all letters in theLatin alphabetletters – elements◯ – Set V : all vow-

els

Page 80: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal setU: all letters in theLatin alphabet

letters – elements◯ – Set V : all vow-

els

Page 81: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal setU: all letters in theLatin alphabetletters – elements

◯ – Set V : all vow-els

Page 82: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal setU: all letters in theLatin alphabetletters – elements◯ – Set V : all vow-

els

Page 83: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal set U◯ – Set A◯ – Set B

1 Venn diagrams are often drawn to abstractly illustraterelations between multiple sets. Elements are implicit/omitted(shown as dots only when an explicit element is needed)

2 Example: shaded area illustrates a set of elements that are inboth sets A and B (i.e. intersection of two sets, see later).E.g consider A={a,b,c,f,z} and B={c,d,e,f,x,y}.

Page 84: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal set U

◯ – Set A◯ – Set B

1 Venn diagrams are often drawn to abstractly illustraterelations between multiple sets. Elements are implicit/omitted(shown as dots only when an explicit element is needed)

2 Example: shaded area illustrates a set of elements that are inboth sets A and B (i.e. intersection of two sets, see later).E.g consider A={a,b,c,f,z} and B={c,d,e,f,x,y}.

Page 85: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal set U◯ – Set A

◯ – Set B

1 Venn diagrams are often drawn to abstractly illustraterelations between multiple sets. Elements are implicit/omitted(shown as dots only when an explicit element is needed)

2 Example: shaded area illustrates a set of elements that are inboth sets A and B (i.e. intersection of two sets, see later).E.g consider A={a,b,c,f,z} and B={c,d,e,f,x,y}.

Page 86: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal set U◯ – Set A◯ – Set B

1 Venn diagrams are often drawn to abstractly illustraterelations between multiple sets. Elements are implicit/omitted(shown as dots only when an explicit element is needed)

2 Example: shaded area illustrates a set of elements that are inboth sets A and B (i.e. intersection of two sets, see later).E.g consider A={a,b,c,f,z} and B={c,d,e,f,x,y}.

Page 87: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn DiagramJohn Venn (1834 -

1923) Cambridge, UK

◻ – Universal set U◯ – Set A◯ – Set B

1 Venn diagrams are often drawn to abstractly illustraterelations between multiple sets. Elements are implicit/omitted(shown as dots only when an explicit element is needed)

2 Example: shaded area illustrates a set of elements that are inboth sets A and B (i.e. intersection of two sets, see later).E.g consider A={a,b,c,f,z} and B={c,d,e,f,x,y}.

Page 88: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 89: Basic Structures: Sets, Functions, Sequences, Sums, and

Set equality

Definition: Two sets are equal if and only if they have the sameelements.

1 If A and B are sets, then A and B are equal iff:

∀x (x ∈ A ↔ x ∈ B)

2 We write A = B if A and B are equal sets.

{1,3,5} = {3,5,1}{1,5,5,5,3,3,1} = {1,3,5}

Page 90: Basic Structures: Sets, Functions, Sequences, Sums, and

Set equality

Definition: Two sets are equal if and only if they have the sameelements.

1 If A and B are sets, then A and B are equal iff:

∀x (x ∈ A ↔ x ∈ B)

2 We write A = B if A and B are equal sets.

{1,3,5} = {3,5,1}{1,5,5,5,3,3,1} = {1,3,5}

Page 91: Basic Structures: Sets, Functions, Sequences, Sums, and

Set equality

Definition: Two sets are equal if and only if they have the sameelements.

1 If A and B are sets, then A and B are equal iff:

∀x (x ∈ A ↔ x ∈ B)

2 We write A = B if A and B are equal sets.

{1,3,5} = {3,5,1}{1,5,5,5,3,3,1} = {1,3,5}

Page 92: Basic Structures: Sets, Functions, Sequences, Sums, and

Set equality

Definition: Two sets are equal if and only if they have the sameelements.

1 If A and B are sets, then A and B are equal iff:

∀x (x ∈ A ↔ x ∈ B)

2 We write A = B if A and B are equal sets.

{1,3,5} = {3,5,1}{1,5,5,5,3,3,1} = {1,3,5}

Page 93: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 94: Basic Structures: Sets, Functions, Sequences, Sums, and

Subsets

Definition: The set A is a subset of B, if and only if every elementof A is also an element of B.

1 The notation A ⊆ B is used to indicate that A is a subset ofthe set B

2 A ⊆ B holds if and only if ∀x (x ∈ A → x ∈ B) is true.

3 Observe that:

a Because a ∈ ∅ is always false, for every set S we have:

∅ ⊆ S .

b Because a ∈ S →a ∈ S , for every set S, we have:

S ⊆ S .

Page 95: Basic Structures: Sets, Functions, Sequences, Sums, and

Subsets

Definition: The set A is a subset of B, if and only if every elementof A is also an element of B.

1 The notation A ⊆ B is used to indicate that A is a subset ofthe set B

2 A ⊆ B holds if and only if ∀x (x ∈ A → x ∈ B) is true.

3 Observe that:

a Because a ∈ ∅ is always false, for every set S we have:

∅ ⊆ S .

b Because a ∈ S →a ∈ S , for every set S, we have:

S ⊆ S .

Page 96: Basic Structures: Sets, Functions, Sequences, Sums, and

Subsets

Definition: The set A is a subset of B, if and only if every elementof A is also an element of B.

1 The notation A ⊆ B is used to indicate that A is a subset ofthe set B

2 A ⊆ B holds if and only if ∀x (x ∈ A → x ∈ B) is true.

3 Observe that:

a Because a ∈ ∅ is always false, for every set S we have:

∅ ⊆ S .

b Because a ∈ S →a ∈ S , for every set S, we have:

S ⊆ S .

Page 97: Basic Structures: Sets, Functions, Sequences, Sums, and

Subsets

Definition: The set A is a subset of B, if and only if every elementof A is also an element of B.

1 The notation A ⊆ B is used to indicate that A is a subset ofthe set B

2 A ⊆ B holds if and only if ∀x (x ∈ A → x ∈ B) is true.

3 Observe that:

a Because a ∈ ∅ is always false, for every set S we have:

∅ ⊆ S .

b Because a ∈ S →a ∈ S , for every set S, we have:

S ⊆ S .

Page 98: Basic Structures: Sets, Functions, Sequences, Sums, and

Subsets

Definition: The set A is a subset of B, if and only if every elementof A is also an element of B.

1 The notation A ⊆ B is used to indicate that A is a subset ofthe set B

2 A ⊆ B holds if and only if ∀x (x ∈ A → x ∈ B) is true.

3 Observe that:

a Because a ∈ ∅ is always false, for every set S we have:

∅ ⊆ S .

b Because a ∈ S →a ∈ S , for every set S, we have:

S ⊆ S .

Page 99: Basic Structures: Sets, Functions, Sequences, Sums, and

Showing that a set is or is not a subset of another set

1 Showing that A is a Subset of B: To show that A ⊆ B,show that if x belongs to A, then x also belongs to B.

2 Showing that A is not a Subset of B: To show that A isnot a subset of B, that is A ⊈ B, find an element x ∈ A with x∉ B.

(Such an x is a counterexample to the claim that x ∈ Aimplies x ∈ B.)

3 Examples:

a The set of all computer science majors at your school is asubset of all students at your school.

b The set of integers with squares less than 100 is not a subsetof the set of all non-negative integers.

Page 100: Basic Structures: Sets, Functions, Sequences, Sums, and

Showing that a set is or is not a subset of another set

1 Showing that A is a Subset of B: To show that A ⊆ B,show that if x belongs to A, then x also belongs to B.

2 Showing that A is not a Subset of B: To show that A isnot a subset of B, that is A ⊈ B, find an element x ∈ A with x∉ B.

(Such an x is a counterexample to the claim that x ∈ Aimplies x ∈ B.)

3 Examples:

a The set of all computer science majors at your school is asubset of all students at your school.

b The set of integers with squares less than 100 is not a subsetof the set of all non-negative integers.

Page 101: Basic Structures: Sets, Functions, Sequences, Sums, and

Showing that a set is or is not a subset of another set

1 Showing that A is a Subset of B: To show that A ⊆ B,show that if x belongs to A, then x also belongs to B.

2 Showing that A is not a Subset of B: To show that A isnot a subset of B, that is A ⊈ B, find an element x ∈ A with x∉ B. (Such an x is a counterexample to the claim that x ∈ Aimplies x ∈ B.)

3 Examples:

a The set of all computer science majors at your school is asubset of all students at your school.

b The set of integers with squares less than 100 is not a subsetof the set of all non-negative integers.

Page 102: Basic Structures: Sets, Functions, Sequences, Sums, and

Showing that a set is or is not a subset of another set

1 Showing that A is a Subset of B: To show that A ⊆ B,show that if x belongs to A, then x also belongs to B.

2 Showing that A is not a Subset of B: To show that A isnot a subset of B, that is A ⊈ B, find an element x ∈ A with x∉ B. (Such an x is a counterexample to the claim that x ∈ Aimplies x ∈ B.)

3 Examples:

a The set of all computer science majors at your school is asubset of all students at your school.

b The set of integers with squares less than 100 is not a subsetof the set of all non-negative integers.

Page 103: Basic Structures: Sets, Functions, Sequences, Sums, and

Showing that a set is or is not a subset of another set

1 Showing that A is a Subset of B: To show that A ⊆ B,show that if x belongs to A, then x also belongs to B.

2 Showing that A is not a Subset of B: To show that A isnot a subset of B, that is A ⊈ B, find an element x ∈ A with x∉ B. (Such an x is a counterexample to the claim that x ∈ Aimplies x ∈ B.)

3 Examples:

a The set of all computer science majors at your school is asubset of all students at your school.

b The set of integers with squares less than 100 is not a subsetof the set of all non-negative integers.

Page 104: Basic Structures: Sets, Functions, Sequences, Sums, and

Showing that a set is or is not a subset of another set

1 Showing that A is a Subset of B: To show that A ⊆ B,show that if x belongs to A, then x also belongs to B.

2 Showing that A is not a Subset of B: To show that A isnot a subset of B, that is A ⊈ B, find an element x ∈ A with x∉ B. (Such an x is a counterexample to the claim that x ∈ Aimplies x ∈ B.)

3 Examples:

a The set of all computer science majors at your school is asubset of all students at your school.

b The set of integers with squares less than 100 is not a subsetof the set of all non-negative integers.

Page 105: Basic Structures: Sets, Functions, Sequences, Sums, and

Another look at equality of sets

1 Recall that two sets A and B are equal (denoted by A = B)iff:

∀x (x ∈ A ↔ x ∈ B)

2 That is, using logical equivalences we have that A = B iff:

∀x ((x ∈ A → x ∈ B) ∧ (x ∈ B → x ∈ A))

3 This is also equivalent to:

A ⊆ B and B ⊆ A

Page 106: Basic Structures: Sets, Functions, Sequences, Sums, and

Another look at equality of sets

1 Recall that two sets A and B are equal (denoted by A = B)iff:

∀x (x ∈ A ↔ x ∈ B)

2 That is, using logical equivalences we have that A = B iff:

∀x ((x ∈ A → x ∈ B) ∧ (x ∈ B → x ∈ A))

3 This is also equivalent to:

A ⊆ B and B ⊆ A

Page 107: Basic Structures: Sets, Functions, Sequences, Sums, and

Another look at equality of sets

1 Recall that two sets A and B are equal (denoted by A = B)iff:

∀x (x ∈ A ↔ x ∈ B)

2 That is, using logical equivalences we have that A = B iff:

∀x ((x ∈ A → x ∈ B) ∧ (x ∈ B → x ∈ A))

3 This is also equivalent to:

A ⊆ B and B ⊆ A

Page 108: Basic Structures: Sets, Functions, Sequences, Sums, and

Proper subsets

Definition: If A ⊆ B, but A ≠B, then we say A is a proper subsetof B, denoted by A ⊂ B. If A ⊂ B, then the following is true:

∀x (x ∈ A → x ∈ B) ∧ ∃x (x ∈ B ∧ x ∉ A)

Example:A = {c, f , z} andB = {a,b, c ,d , e, f , t, x , z}.

Venn Diagram for a proper subset A ⊂ B

Page 109: Basic Structures: Sets, Functions, Sequences, Sums, and

Proper subsets

Definition: If A ⊆ B, but A ≠B, then we say A is a proper subsetof B, denoted by A ⊂ B. If A ⊂ B, then the following is true:

∀x (x ∈ A → x ∈ B) ∧ ∃x (x ∈ B ∧ x ∉ A)

Example:A = {c, f , z} andB = {a,b, c ,d , e, f , t, x , z}.

Venn Diagram for a proper subset A ⊂ B

Page 110: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 111: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and truth sets

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set ofP = { x ∣ P(x) }

that is, all elements x whereP(x) is true

Note that: x ∈ P ≡ P(x)

Page 112: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and truth sets

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set ofP = { x ∣ P(x) }

that is, all elements x whereP(x) is true

Note that: x ∈ P ≡ P(x)

Page 113: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and truth sets

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set ofP = { x ∣ P(x) }

that is, all elements x whereP(x) is true

Note that: x ∈ P ≡ P(x)

Page 114: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and truth sets

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set ofP = { x ∣ P(x) }

that is, all elements x whereP(x) is true

Note that: x ∈ P ≡ P(x)

Page 115: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and logical connectives: negations

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set of {x ∣ ¬P(x)}

all elements x where ¬P(x) istrue, i.e. where P(x) is false

Same as complement of set P (see section 2.4)

Note that: x ∉ P ≡ ¬P(x)

Page 116: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and logical connectives: negations

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set of {x ∣ ¬P(x)}

all elements x where ¬P(x) istrue, i.e. where P(x) is false

Same as complement of set P (see section 2.4)

Note that: x ∉ P ≡ ¬P(x)

Page 117: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and logical connectives: negations

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set of {x ∣ ¬P(x)}

all elements x where ¬P(x) istrue, i.e. where P(x) is false

Same as complement of set P (see section 2.4)

Note that: x ∉ P ≡ ¬P(x)

Page 118: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and logical connectives: negations

Consider any predicate P(x) for elements x in U and its truthset P = {x ∣ P(x)}.

– truth set of {x ∣ ¬P(x)}

all elements x where ¬P(x) istrue, i.e. where P(x) is false

Same as complement of set P (see section 2.4)

Note that: x ∉ P ≡ ¬P(x)

Page 119: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn Diagrams and logical connectives: conjunctions

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set of{x ∣ P(x) ∧Q(x)} that is, allelements x where both P(x)

and Q(x) is true

Same as intersection of sets P and Q (see section 2.3)

Page 120: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn Diagrams and logical connectives: conjunctions

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set of{x ∣ P(x) ∧Q(x)} that is, allelements x where both P(x)

and Q(x) is true

Same as intersection of sets P and Q (see section 2.3)

Page 121: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn Diagrams and logical connectives: conjunctions

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set of{x ∣ P(x) ∧Q(x)} that is, allelements x where both P(x)

and Q(x) is true

Same as intersection of sets P and Q (see section 2.3)

Page 122: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn Diagrams and logical connectives: conjunctions

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set of{x ∣ P(x) ∧Q(x)} that is, allelements x where both P(x)

and Q(x) is true

Same as intersection of sets P and Q (see section 2.3)

Page 123: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn Diagrams and logical connectives: disjunctions

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set{x ∣ P(x) ∨Q(x)} that is, all

elements x where P(x) orQ(x) is true

Same as union of sets P and Q (see section 2.2)

Page 124: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and logical connectives: implications

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set {x ∣ P(x) →Q(x)}

(all x where implication P(x)→ Q(x) is true)

– set where implicationP(x)→ Q(x) is false:

{x ∣ ¬(¬P(x) ∨Q(x))} = {x ∣ P(x) ∧ ¬Q(x)}

= {x ∣ x ∈ P ∧ x ∉ Q}

1 Remember:

p → q ≡ ¬p ∨ q

2 Thus, we have:

{x ∣ P(x)→ Q(x)} = {x ∣ ¬P(x) ∨Q(x)} = {x ∣ x ∉ P ∨ x ∈ Q}

Page 125: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and logical connectives: implications

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set {x ∣ P(x) →Q(x)}

(all x where implication P(x)→ Q(x) is true)

– set where implicationP(x)→ Q(x) is false:

{x ∣ ¬(¬P(x) ∨Q(x))} = {x ∣ P(x) ∧ ¬Q(x)}

= {x ∣ x ∈ P ∧ x ∉ Q}

1 Remember:

p → q ≡ ¬p ∨ q

2 Thus, we have:

{x ∣ P(x)→ Q(x)} = {x ∣ ¬P(x) ∨Q(x)} = {x ∣ x ∉ P ∨ x ∈ Q}

Page 126: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagrams and logical connectives: implications

Consider two arbitrary predicates P(x) and Q(x) defined forelements x in U together with their corresponding truth setsP = {x ∣ P(x)} and Q = {x ∣ Q(x)}.

– truth set {x ∣ P(x) →Q(x)}

(all x where implication P(x)→ Q(x) is true)

– set where implicationP(x)→ Q(x) is false:

{x ∣ ¬(¬P(x) ∨Q(x))} = {x ∣ P(x) ∧ ¬Q(x)}

= {x ∣ x ∈ P ∧ x ∉ Q}

1 Remember:

p → q ≡ ¬p ∨ q

2 Thus, we have:

{x ∣ P(x)→ Q(x)} = {x ∣ ¬P(x) ∨Q(x)} = {x ∣ x ∉ P ∨ x ∈ Q}

Page 127: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 128: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 129: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 130: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 131: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 132: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 133: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 134: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))

≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 135: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))≡ ¬∃x(P(x) ∧ ¬Q(x))

≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 136: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

∀x(P(x)→ Q(x)) ≡ ∀x(¬P(x) ∨Q(x))≡ ¬∃x(P(x) ∧ ¬Q(x))≡ ¬∃x(x ∈ P ∧ x ∉ Q)

Page 137: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

1 This gives intuitive interpretation for logical “implications”:

2 Proving theorems of the form ∀x(P(x)→ Q(x)) is equivalentto proving the subset relationship for the truth sets P ⊆ Q.

Page 138: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

1 This gives intuitive interpretation for logical “implications”:

2 Proving theorems of the form ∀x(P(x)→ Q(x)) is equivalentto proving the subset relationship for the truth sets P ⊆ Q.

Page 139: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and implication: special case

1 Assume that implication P(x)→ Q(x) is true for all x .

2 That is, assume {x ∣ P(x)→ Q(x)} ≡ U is true.

3 Note that, from the definition of subsets:

∀x(P(x)→ Q(x)) ≡ ∀x(x ∈ P → x ∈ Q) ≡ P ⊆ Q

Venn diagram for P ⊆ Q often shows P as a

proper subset of Q, thus assuming P ≠ Q

– truth set{x ∣ P(x) → Q(x)}

(all x where implication P(x)→ Q(x) is true)

– setwhere implicationP(x) → Q(x) is false:

empty in this case: {x ∣ x ∈ P ∧ x ∉ Q} = ∅

1 This gives intuitive interpretation for logical “implications”:

2 Proving theorems of the form ∀x(P(x)→ Q(x)) is equivalentto proving the subset relationship for the truth sets P ⊆ Q.

Page 140: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and logical connectives: biconditional

1 Similarly one can show that

∀xP(x)↔ Q(x) ≡ P = Q

2 that is,

∀x(P(x)→ Q(x) ∧Q(x)→ P(x)) ≡ P ⊆ Q ∧Q ⊆ P.

– truth set of{x ∣ P(x)↔ Q(x)}

assuming ∀x(P(x)↔ Q(x)) is true

1 This gives intuitive interpretation for “biconditional”:

2 Proving theorems of the form ∀x(P(x)↔ Q(x)) is equivalentto proving the subset relationship for the truth sets P = Q.

Page 141: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and logical connectives: biconditional

1 Similarly one can show that

∀xP(x)↔ Q(x) ≡ P = Q

2 that is,

∀x(P(x)→ Q(x) ∧Q(x)→ P(x)) ≡ P ⊆ Q ∧Q ⊆ P.

– truth set of{x ∣ P(x)↔ Q(x)}

assuming ∀x(P(x)↔ Q(x)) is true

1 This gives intuitive interpretation for “biconditional”:

2 Proving theorems of the form ∀x(P(x)↔ Q(x)) is equivalentto proving the subset relationship for the truth sets P = Q.

Page 142: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and logical connectives: biconditional

1 Similarly one can show that

∀xP(x)↔ Q(x) ≡ P = Q

2 that is,

∀x(P(x)→ Q(x) ∧Q(x)→ P(x)) ≡ P ⊆ Q ∧Q ⊆ P.

– truth set of{x ∣ P(x)↔ Q(x)}

assuming ∀x(P(x)↔ Q(x)) is true

1 This gives intuitive interpretation for “biconditional”:

2 Proving theorems of the form ∀x(P(x)↔ Q(x)) is equivalentto proving the subset relationship for the truth sets P = Q.

Page 143: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and logical connectives: biconditional

1 Similarly one can show that

∀xP(x)↔ Q(x) ≡ P = Q

2 that is,

∀x(P(x)→ Q(x) ∧Q(x)→ P(x)) ≡ P ⊆ Q ∧Q ⊆ P.

– truth set of{x ∣ P(x)↔ Q(x)}

assuming ∀x(P(x)↔ Q(x)) is true

1 This gives intuitive interpretation for “biconditional”:

2 Proving theorems of the form ∀x(P(x)↔ Q(x)) is equivalentto proving the subset relationship for the truth sets P = Q.

Page 144: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and logical connectives: biconditional

1 Similarly one can show that

∀xP(x)↔ Q(x) ≡ P = Q

2 that is,

∀x(P(x)→ Q(x) ∧Q(x)→ P(x)) ≡ P ⊆ Q ∧Q ⊆ P.

– truth set of{x ∣ P(x)↔ Q(x)}

assuming ∀x(P(x)↔ Q(x)) is true

1 This gives intuitive interpretation for “biconditional”:

2 Proving theorems of the form ∀x(P(x)↔ Q(x)) is equivalentto proving the subset relationship for the truth sets P = Q.

Page 145: Basic Structures: Sets, Functions, Sequences, Sums, and

Venn diagram and logical connectives: biconditional

1 Similarly one can show that

∀xP(x)↔ Q(x) ≡ P = Q

2 that is,

∀x(P(x)→ Q(x) ∧Q(x)→ P(x)) ≡ P ⊆ Q ∧Q ⊆ P.

– truth set of{x ∣ P(x)↔ Q(x)}

assuming ∀x(P(x)↔ Q(x)) is true

1 This gives intuitive interpretation for “biconditional”:

2 Proving theorems of the form ∀x(P(x)↔ Q(x)) is equivalentto proving the subset relationship for the truth sets P = Q.

Page 146: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 147: Basic Structures: Sets, Functions, Sequences, Sums, and

Set cardinality

Definition: If there are exactly n (distinct) elements in S where nis a non-negative integer, we say that S is finite. Otherwise, theset S is said infinite.

Definition: The cardinality of a finite set A, denoted by ∣A∣, is thenumber of (distinct) elements of A.

Examples:

1 ∣ ∅ ∣ = 0

2 Let S be the letters of the English alphabet. Then ∣S ∣ = 26

3 ∣{1,2,3}∣ = 3

4 ∣ {∅} ∣ = 1

5 The set of integers is infinite.

Page 148: Basic Structures: Sets, Functions, Sequences, Sums, and

Set cardinality

Definition: If there are exactly n (distinct) elements in S where nis a non-negative integer, we say that S is finite. Otherwise, theset S is said infinite.

Definition: The cardinality of a finite set A, denoted by ∣A∣, is thenumber of (distinct) elements of A.

Examples:

1 ∣ ∅ ∣ = 0

2 Let S be the letters of the English alphabet. Then ∣S ∣ = 26

3 ∣{1,2,3}∣ = 3

4 ∣ {∅} ∣ = 1

5 The set of integers is infinite.

Page 149: Basic Structures: Sets, Functions, Sequences, Sums, and

Set cardinality

Definition: If there are exactly n (distinct) elements in S where nis a non-negative integer, we say that S is finite. Otherwise, theset S is said infinite.

Definition: The cardinality of a finite set A, denoted by ∣A∣, is thenumber of (distinct) elements of A.

Examples:

1 ∣ ∅ ∣ = 0

2 Let S be the letters of the English alphabet. Then ∣S ∣ = 26

3 ∣{1,2,3}∣ = 3

4 ∣ {∅} ∣ = 1

5 The set of integers is infinite.

Page 150: Basic Structures: Sets, Functions, Sequences, Sums, and

Set cardinality

Definition: If there are exactly n (distinct) elements in S where nis a non-negative integer, we say that S is finite. Otherwise, theset S is said infinite.

Definition: The cardinality of a finite set A, denoted by ∣A∣, is thenumber of (distinct) elements of A.

Examples:

1 ∣ ∅ ∣ = 0

2 Let S be the letters of the English alphabet. Then ∣S ∣ = 26

3 ∣{1,2,3}∣ = 3

4 ∣ {∅} ∣ = 1

5 The set of integers is infinite.

Page 151: Basic Structures: Sets, Functions, Sequences, Sums, and

Set cardinality

Definition: If there are exactly n (distinct) elements in S where nis a non-negative integer, we say that S is finite. Otherwise, theset S is said infinite.

Definition: The cardinality of a finite set A, denoted by ∣A∣, is thenumber of (distinct) elements of A.

Examples:

1 ∣ ∅ ∣ = 0

2 Let S be the letters of the English alphabet. Then ∣S ∣ = 26

3 ∣{1,2,3}∣ = 3

4 ∣ {∅} ∣ = 1

5 The set of integers is infinite.

Page 152: Basic Structures: Sets, Functions, Sequences, Sums, and

Set cardinality

Definition: If there are exactly n (distinct) elements in S where nis a non-negative integer, we say that S is finite. Otherwise, theset S is said infinite.

Definition: The cardinality of a finite set A, denoted by ∣A∣, is thenumber of (distinct) elements of A.

Examples:

1 ∣ ∅ ∣ = 0

2 Let S be the letters of the English alphabet. Then ∣S ∣ = 26

3 ∣{1,2,3}∣ = 3

4 ∣ {∅} ∣ = 1

5 The set of integers is infinite.

Page 153: Basic Structures: Sets, Functions, Sequences, Sums, and

Set cardinality

Definition: If there are exactly n (distinct) elements in S where nis a non-negative integer, we say that S is finite. Otherwise, theset S is said infinite.

Definition: The cardinality of a finite set A, denoted by ∣A∣, is thenumber of (distinct) elements of A.

Examples:

1 ∣ ∅ ∣ = 0

2 Let S be the letters of the English alphabet. Then ∣S ∣ = 26

3 ∣{1,2,3}∣ = 3

4 ∣ {∅} ∣ = 1

5 The set of integers is infinite.

Page 154: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 155: Basic Structures: Sets, Functions, Sequences, Sums, and

Power sets

Definition: The set of all subsets of a set A, denoted P(A), iscalled the power set of A.

Example: If A = {a,b} then:

P(A) = {∅,{a},{b},{a,b}}

1 If a set has n elements, then the cardinality of the power set is2n.

2 In Chapters 5 and 6, we will discuss different ways to showthis.

Page 156: Basic Structures: Sets, Functions, Sequences, Sums, and

Power sets

Definition: The set of all subsets of a set A, denoted P(A), iscalled the power set of A.

Example: If A = {a,b} then:

P(A) = {∅,{a},{b},{a,b}}

1 If a set has n elements, then the cardinality of the power set is2n.

2 In Chapters 5 and 6, we will discuss different ways to showthis.

Page 157: Basic Structures: Sets, Functions, Sequences, Sums, and

Power sets

Definition: The set of all subsets of a set A, denoted P(A), iscalled the power set of A.

Example: If A = {a,b} then:

P(A) = {∅,{a},{b},{a,b}}

1 If a set has n elements, then the cardinality of the power set is2n.

2 In Chapters 5 and 6, we will discuss different ways to showthis.

Page 158: Basic Structures: Sets, Functions, Sequences, Sums, and

Power sets

Definition: The set of all subsets of a set A, denoted P(A), iscalled the power set of A.

Example: If A = {a,b} then:

P(A) = {∅,{a},{b},{a,b}}

1 If a set has n elements, then the cardinality of the power set is2n.

2 In Chapters 5 and 6, we will discuss different ways to showthis.

Page 159: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 160: Basic Structures: Sets, Functions, Sequences, Sums, and

Tuples

1 The ordered n-tuple (a1, a2, . . . ,an) is the ordered collectionthat has a1 as its first element and a2 as its second elementand so on until an as its last element.

2 Two n-tuples are equal if and only if their correspondingelements are equal.

3 2-tuples are called ordered pairs, e.g. (a1,a2)4 The ordered pairs (a,b) and (c,d) are equal if and only if

a = c and b = d .

Page 161: Basic Structures: Sets, Functions, Sequences, Sums, and

Tuples

1 The ordered n-tuple (a1, a2, . . . ,an) is the ordered collectionthat has a1 as its first element and a2 as its second elementand so on until an as its last element.

2 Two n-tuples are equal if and only if their correspondingelements are equal.

3 2-tuples are called ordered pairs, e.g. (a1,a2)4 The ordered pairs (a,b) and (c,d) are equal if and only if

a = c and b = d .

Page 162: Basic Structures: Sets, Functions, Sequences, Sums, and

Tuples

1 The ordered n-tuple (a1, a2, . . . ,an) is the ordered collectionthat has a1 as its first element and a2 as its second elementand so on until an as its last element.

2 Two n-tuples are equal if and only if their correspondingelements are equal.

3 2-tuples are called ordered pairs, e.g. (a1,a2)

4 The ordered pairs (a,b) and (c,d) are equal if and only ifa = c and b = d .

Page 163: Basic Structures: Sets, Functions, Sequences, Sums, and

Tuples

1 The ordered n-tuple (a1, a2, . . . ,an) is the ordered collectionthat has a1 as its first element and a2 as its second elementand so on until an as its last element.

2 Two n-tuples are equal if and only if their correspondingelements are equal.

3 2-tuples are called ordered pairs, e.g. (a1,a2)4 The ordered pairs (a,b) and (c,d) are equal if and only if

a = c and b = d .

Page 164: Basic Structures: Sets, Functions, Sequences, Sums, and

Cartesian Product

Rene

Descartes

(1596-1650)

Definition: The Cartesian Product of two sets A and B, denotedby A ×B is the set of ordered pairs (a,b) where a ∈ A and b ∈ B.

Example:

A = {a,b},B = {1,2,3}

A ×B = {(a,1), (a,2), (a,3), (b,1), (b,2), (b,3)}

Definition: A subset R of the Cartesian product A × B is called arelation from the set A to the set B. Relations will be covered indepth in Chapter 9.

Page 165: Basic Structures: Sets, Functions, Sequences, Sums, and

Cartesian Product

Rene

Descartes

(1596-1650)

Definition: The Cartesian Product of two sets A and B, denotedby A ×B is the set of ordered pairs (a,b) where a ∈ A and b ∈ B.

Example:

A = {a,b},B = {1,2,3}

A ×B = {(a,1), (a,2), (a,3), (b,1), (b,2), (b,3)}

Definition: A subset R of the Cartesian product A × B is called arelation from the set A to the set B. Relations will be covered indepth in Chapter 9.

Page 166: Basic Structures: Sets, Functions, Sequences, Sums, and

Cartesian Product

Rene

Descartes

(1596-1650)

Definition: The Cartesian Product of two sets A and B, denotedby A ×B is the set of ordered pairs (a,b) where a ∈ A and b ∈ B.

Example:

A = {a,b},B = {1,2,3}

A ×B = {(a,1), (a,2), (a,3), (b,1), (b,2), (b,3)}

Definition: A subset R of the Cartesian product A × B is called arelation from the set A to the set B.

Relations will be covered indepth in Chapter 9.

Page 167: Basic Structures: Sets, Functions, Sequences, Sums, and

Cartesian Product

Rene

Descartes

(1596-1650)

Definition: The Cartesian Product of two sets A and B, denotedby A ×B is the set of ordered pairs (a,b) where a ∈ A and b ∈ B.

Example:

A = {a,b},B = {1,2,3}

A ×B = {(a,1), (a,2), (a,3), (b,1), (b,2), (b,3)}

Definition: A subset R of the Cartesian product A × B is called arelation from the set A to the set B. Relations will be covered indepth in Chapter 9.

Page 168: Basic Structures: Sets, Functions, Sequences, Sums, and

Cartesian product

Definition: The Cartesian products of the sets A1,A2, . . . ,An

denoted by A1 ×A2 × ⋅ ⋅ ⋅ ×An is the set of ordered n-tuples(a1, a2, . . . , an) where ai belongs to Ai for i = 1,2, . . . ,n.

A1 ×A2 × ⋅ ⋅ ⋅ ×An = {(a1, a2, . . . , an) ∣ ai ∈ Ai for i = 1,2, . . . ,n}

Question: What is A × B × C where A = {0,1}, B = {1,2} and C= {0,1,2}

?

Solution: A × B × C = {(0,1,0), (0,1,1), (0,1,2),(0,2,0), (0,2,1),(0,2,2),(1,1,0), (1,1,1), (1,1,2), (1,2,0), (1,2,1), (1,2,2)}

Page 169: Basic Structures: Sets, Functions, Sequences, Sums, and

Cartesian product

Definition: The Cartesian products of the sets A1,A2, . . . ,An

denoted by A1 ×A2 × ⋅ ⋅ ⋅ ×An is the set of ordered n-tuples(a1, a2, . . . , an) where ai belongs to Ai for i = 1,2, . . . ,n.

A1 ×A2 × ⋅ ⋅ ⋅ ×An = {(a1, a2, . . . , an) ∣ ai ∈ Ai for i = 1,2, . . . ,n}

Question: What is A × B × C where A = {0,1}, B = {1,2} and C= {0,1,2}?

Solution: A × B × C = {(0,1,0), (0,1,1), (0,1,2),(0,2,0), (0,2,1),(0,2,2),(1,1,0), (1,1,1), (1,1,2), (1,2,0), (1,2,1), (1,2,2)}

Page 170: Basic Structures: Sets, Functions, Sequences, Sums, and

Cartesian product

Definition: The Cartesian products of the sets A1,A2, . . . ,An

denoted by A1 ×A2 × ⋅ ⋅ ⋅ ×An is the set of ordered n-tuples(a1, a2, . . . , an) where ai belongs to Ai for i = 1,2, . . . ,n.

A1 ×A2 × ⋅ ⋅ ⋅ ×An = {(a1, a2, . . . , an) ∣ ai ∈ Ai for i = 1,2, . . . ,n}

Question: What is A × B × C where A = {0,1}, B = {1,2} and C= {0,1,2}?

Solution: A × B × C = {(0,1,0), (0,1,1), (0,1,2),(0,2,0), (0,2,1),(0,2,2),(1,1,0), (1,1,1), (1,1,2), (1,2,0), (1,2,1), (1,2,2)}

Page 171: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 172: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 173: Basic Structures: Sets, Functions, Sequences, Sums, and

Boolean Algebra

1 Propositional calculus and set theory are both instances of analgebraic system called a Boolean Algebra. This is discussedin CS2209.

2 The operators in set theory are analogous to correspondingoperators in propositional calculus.

3 As always there must be a universal set U.

4 All sets A,B, . . . shown in the next slides are assumed to besubsets of U.

Page 174: Basic Structures: Sets, Functions, Sequences, Sums, and

Boolean Algebra

1 Propositional calculus and set theory are both instances of analgebraic system called a Boolean Algebra. This is discussedin CS2209.

2 The operators in set theory are analogous to correspondingoperators in propositional calculus.

3 As always there must be a universal set U.

4 All sets A,B, . . . shown in the next slides are assumed to besubsets of U.

Page 175: Basic Structures: Sets, Functions, Sequences, Sums, and

Boolean Algebra

1 Propositional calculus and set theory are both instances of analgebraic system called a Boolean Algebra. This is discussedin CS2209.

2 The operators in set theory are analogous to correspondingoperators in propositional calculus.

3 As always there must be a universal set U.

4 All sets A,B, . . . shown in the next slides are assumed to besubsets of U.

Page 176: Basic Structures: Sets, Functions, Sequences, Sums, and

Boolean Algebra

1 Propositional calculus and set theory are both instances of analgebraic system called a Boolean Algebra. This is discussedin CS2209.

2 The operators in set theory are analogous to correspondingoperators in propositional calculus.

3 As always there must be a universal set U.

4 All sets A,B, . . . shown in the next slides are assumed to besubsets of U.

Page 177: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 178: Basic Structures: Sets, Functions, Sequences, Sums, and

Union

1 Definition: Let A and B be sets. The union of the sets A andB, denoted by A ∪ B, is the set:

{x ∣ x ∈ A ∨ x ∈ B}

2 Example: What is {1,2,3} ∪ {3, 4, 5}?

Solution: {1,2,3,4,5}

Venn Diagram for A ∪ B

Union is analogous to disjunction, see earlier slides.

Page 179: Basic Structures: Sets, Functions, Sequences, Sums, and

Union

1 Definition: Let A and B be sets. The union of the sets A andB, denoted by A ∪ B, is the set:

{x ∣ x ∈ A ∨ x ∈ B}

2 Example: What is {1,2,3} ∪ {3, 4, 5}?

Solution: {1,2,3,4,5}

Venn Diagram for A ∪ B

Union is analogous to disjunction, see earlier slides.

Page 180: Basic Structures: Sets, Functions, Sequences, Sums, and

Union

1 Definition: Let A and B be sets. The union of the sets A andB, denoted by A ∪ B, is the set:

{x ∣ x ∈ A ∨ x ∈ B}

2 Example: What is {1,2,3} ∪ {3, 4, 5}?

Solution: {1,2,3,4,5}

Venn Diagram for A ∪ B

Union is analogous to disjunction, see earlier slides.

Page 181: Basic Structures: Sets, Functions, Sequences, Sums, and

Union

1 Definition: Let A and B be sets. The union of the sets A andB, denoted by A ∪ B, is the set:

{x ∣ x ∈ A ∨ x ∈ B}

2 Example: What is {1,2,3} ∪ {3, 4, 5}?

Solution: {1,2,3,4,5}

Venn Diagram for A ∪ B

Union is analogous to disjunction, see earlier slides.

Page 182: Basic Structures: Sets, Functions, Sequences, Sums, and

Union

1 Definition: Let A and B be sets. The union of the sets A andB, denoted by A ∪ B, is the set:

{x ∣ x ∈ A ∨ x ∈ B}

2 Example: What is {1,2,3} ∪ {3, 4, 5}?

Solution: {1,2,3,4,5}

Venn Diagram for A ∪ B

Union is analogous to disjunction, see earlier slides.

Page 183: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 184: Basic Structures: Sets, Functions, Sequences, Sums, and

Intersection

1 Definition: The intersection of sets A and B, denoted by A ∩B, is:

{x ∣ x ∈ A ∧ x ∈ B}

2 If the intersection is empty, then A and B are said to bedisjoint.

1 Example: What is{1,2,3} ∩ {3,4,5} ?

Solution: {3}

1 Example: What is{1,2,3} ∩ {4,5,6} ?

Solution: ∅

Venn Diagram for A ∩ B

Intersection is analogous to conjunction, see earlier slides.

Page 185: Basic Structures: Sets, Functions, Sequences, Sums, and

Intersection

1 Definition: The intersection of sets A and B, denoted by A ∩B, is:

{x ∣ x ∈ A ∧ x ∈ B}

2 If the intersection is empty, then A and B are said to bedisjoint.

1 Example: What is{1,2,3} ∩ {3,4,5} ?

Solution: {3}

1 Example: What is{1,2,3} ∩ {4,5,6} ?

Solution: ∅

Venn Diagram for A ∩ B

Intersection is analogous to conjunction, see earlier slides.

Page 186: Basic Structures: Sets, Functions, Sequences, Sums, and

Intersection

1 Definition: The intersection of sets A and B, denoted by A ∩B, is:

{x ∣ x ∈ A ∧ x ∈ B}

2 If the intersection is empty, then A and B are said to bedisjoint.

1 Example: What is{1,2,3} ∩ {3,4,5} ?

Solution: {3}

1 Example: What is{1,2,3} ∩ {4,5,6} ?

Solution: ∅

Venn Diagram for A ∩ B

Intersection is analogous to conjunction, see earlier slides.

Page 187: Basic Structures: Sets, Functions, Sequences, Sums, and

Intersection

1 Definition: The intersection of sets A and B, denoted by A ∩B, is:

{x ∣ x ∈ A ∧ x ∈ B}

2 If the intersection is empty, then A and B are said to bedisjoint.

1 Example: What is{1,2,3} ∩ {3,4,5} ?

Solution: {3}

1 Example: What is{1,2,3} ∩ {4,5,6} ?

Solution: ∅

Venn Diagram for A ∩ B

Intersection is analogous to conjunction, see earlier slides.

Page 188: Basic Structures: Sets, Functions, Sequences, Sums, and

Intersection

1 Definition: The intersection of sets A and B, denoted by A ∩B, is:

{x ∣ x ∈ A ∧ x ∈ B}

2 If the intersection is empty, then A and B are said to bedisjoint.

1 Example: What is{1,2,3} ∩ {3,4,5} ?

Solution: {3}

1 Example: What is{1,2,3} ∩ {4,5,6} ?

Solution: ∅

Venn Diagram for A ∩ B

Intersection is analogous to conjunction, see earlier slides.

Page 189: Basic Structures: Sets, Functions, Sequences, Sums, and

Intersection

1 Definition: The intersection of sets A and B, denoted by A ∩B, is:

{x ∣ x ∈ A ∧ x ∈ B}

2 If the intersection is empty, then A and B are said to bedisjoint.

1 Example: What is{1,2,3} ∩ {3,4,5} ?

Solution: {3}

1 Example: What is{1,2,3} ∩ {4,5,6} ?

Solution: ∅

Venn Diagram for A ∩ B

Intersection is analogous to conjunction, see earlier slides.

Page 190: Basic Structures: Sets, Functions, Sequences, Sums, and

Intersection

1 Definition: The intersection of sets A and B, denoted by A ∩B, is:

{x ∣ x ∈ A ∧ x ∈ B}

2 If the intersection is empty, then A and B are said to bedisjoint.

1 Example: What is{1,2,3} ∩ {3,4,5} ?

Solution: {3}

1 Example: What is{1,2,3} ∩ {4,5,6} ?

Solution: ∅

Venn Diagram for A ∩ B

Intersection is analogous to conjunction, see earlier slides.

Page 191: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 192: Basic Structures: Sets, Functions, Sequences, Sums, and

Complement

Definition: If A is a set, then the complement of the A (withrespect to U), denoted by A is the set:

A = {x ∈ U ∣ x ∉ A}

(The complement of A is sometimes denoted by Ac .)

Example: If U is the posi-tive integers less than 100,what is the complement of{x ∣ x > 70}?

Solution: {x ∣ x ≤ 70}

Venn Diagram for complement

Complement is analogous to negation, see earlier.

Page 193: Basic Structures: Sets, Functions, Sequences, Sums, and

Complement

Definition: If A is a set, then the complement of the A (withrespect to U), denoted by A is the set:

A = {x ∈ U ∣ x ∉ A}

(The complement of A is sometimes denoted by Ac .)

Example: If U is the posi-tive integers less than 100,what is the complement of{x ∣ x > 70}?

Solution: {x ∣ x ≤ 70}

Venn Diagram for complement

Complement is analogous to negation, see earlier.

Page 194: Basic Structures: Sets, Functions, Sequences, Sums, and

Complement

Definition: If A is a set, then the complement of the A (withrespect to U), denoted by A is the set:

A = {x ∈ U ∣ x ∉ A}

(The complement of A is sometimes denoted by Ac .)

Example: If U is the posi-tive integers less than 100,what is the complement of{x ∣ x > 70}?

Solution: {x ∣ x ≤ 70}

Venn Diagram for complement

Complement is analogous to negation, see earlier.

Page 195: Basic Structures: Sets, Functions, Sequences, Sums, and

Complement

Definition: If A is a set, then the complement of the A (withrespect to U), denoted by A is the set:

A = {x ∈ U ∣ x ∉ A}

(The complement of A is sometimes denoted by Ac .)

Example: If U is the posi-tive integers less than 100,what is the complement of{x ∣ x > 70}?

Solution: {x ∣ x ≤ 70}

Venn Diagram for complement

Complement is analogous to negation, see earlier.

Page 196: Basic Structures: Sets, Functions, Sequences, Sums, and

Complement

Definition: If A is a set, then the complement of the A (withrespect to U), denoted by A is the set:

A = {x ∈ U ∣ x ∉ A}

(The complement of A is sometimes denoted by Ac .)

Example: If U is the posi-tive integers less than 100,what is the complement of{x ∣ x > 70}?

Solution: {x ∣ x ≤ 70}

Venn Diagram for complement

Complement is analogous to negation, see earlier.

Page 197: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 198: Basic Structures: Sets, Functions, Sequences, Sums, and

Difference

Definition: Let A and B be sets. The difference of A and B,denoted by A − B, is the set containing the elements of A that arenot in B. The difference of A and B is also called the complementof B with respect to A.

A −B = {x ∣ x ∈ A ∧ x ∉ B} = A ∩B

Note: A = U - A

Venn Diagram for A − B

Page 199: Basic Structures: Sets, Functions, Sequences, Sums, and

Difference

Definition: Let A and B be sets. The difference of A and B,denoted by A − B, is the set containing the elements of A that arenot in B. The difference of A and B is also called the complementof B with respect to A.

A −B = {x ∣ x ∈ A ∧ x ∉ B} = A ∩B

Note: A = U - A

Venn Diagram for A − B

Page 200: Basic Structures: Sets, Functions, Sequences, Sums, and

Difference

Definition: Let A and B be sets. The difference of A and B,denoted by A − B, is the set containing the elements of A that arenot in B. The difference of A and B is also called the complementof B with respect to A.

A −B = {x ∣ x ∈ A ∧ x ∉ B} = A ∩B

Note: A = U - A

Venn Diagram for A − B

Page 201: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 202: Basic Structures: Sets, Functions, Sequences, Sums, and

The cardinality of the union of two sets

1 Inclusion-Exclusion:

∣A ∪ B ∣ = ∣A∣ + ∣ B ∣ - ∣A ∩ B ∣

Venn Diagram for A,B,A ∩ B,A ∪ B

1 Example:

a Let A be the math majors in your class and B be the CSmajors in your class.

b To count the number of students in your class who are eithermath majors or CS majors, add the number of math majorsand the number of CS majors, and subtract the number ofjoint CS/math majors.

c We will return to this principle in Chapter 6 and Chapter 8,where we will derive a formula for the cardinality of the unionof n sets, where n is a positive integer.

Page 203: Basic Structures: Sets, Functions, Sequences, Sums, and

The cardinality of the union of two sets

1 Inclusion-Exclusion:

∣A ∪ B ∣ = ∣A∣ + ∣ B ∣ - ∣A ∩ B ∣

Venn Diagram for A,B,A ∩ B,A ∪ B

1 Example:

a Let A be the math majors in your class and B be the CSmajors in your class.

b To count the number of students in your class who are eithermath majors or CS majors, add the number of math majorsand the number of CS majors, and subtract the number ofjoint CS/math majors.

c We will return to this principle in Chapter 6 and Chapter 8,where we will derive a formula for the cardinality of the unionof n sets, where n is a positive integer.

Page 204: Basic Structures: Sets, Functions, Sequences, Sums, and

The cardinality of the union of two sets

1 Inclusion-Exclusion:

∣A ∪ B ∣ = ∣A∣ + ∣ B ∣ - ∣A ∩ B ∣

Venn Diagram for A,B,A ∩ B,A ∪ B

1 Example:

a Let A be the math majors in your class and B be the CSmajors in your class.

b To count the number of students in your class who are eithermath majors or CS majors, add the number of math majorsand the number of CS majors, and subtract the number ofjoint CS/math majors.

c We will return to this principle in Chapter 6 and Chapter 8,where we will derive a formula for the cardinality of the unionof n sets, where n is a positive integer.

Page 205: Basic Structures: Sets, Functions, Sequences, Sums, and

The cardinality of the union of two sets

1 Inclusion-Exclusion:

∣A ∪ B ∣ = ∣A∣ + ∣ B ∣ - ∣A ∩ B ∣

Venn Diagram for A,B,A ∩ B,A ∪ B

1 Example:

a Let A be the math majors in your class and B be the CSmajors in your class.

b To count the number of students in your class who are eithermath majors or CS majors, add the number of math majorsand the number of CS majors, and subtract the number ofjoint CS/math majors.

c We will return to this principle in Chapter 6 and Chapter 8,where we will derive a formula for the cardinality of the unionof n sets, where n is a positive integer.

Page 206: Basic Structures: Sets, Functions, Sequences, Sums, and

The cardinality of the union of two sets

1 Inclusion-Exclusion:

∣A ∪ B ∣ = ∣A∣ + ∣ B ∣ - ∣A ∩ B ∣

Venn Diagram for A,B,A ∩ B,A ∪ B

1 Example:

a Let A be the math majors in your class and B be the CSmajors in your class.

b To count the number of students in your class who are eithermath majors or CS majors, add the number of math majorsand the number of CS majors, and subtract the number ofjoint CS/math majors.

c We will return to this principle in Chapter 6 and Chapter 8,where we will derive a formula for the cardinality of the unionof n sets, where n is a positive integer.

Page 207: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 208: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 209: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 210: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}

3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 211: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 212: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 213: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 214: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 215: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 216: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}

6 B − A

Solution: {6,7,8}

Page 217: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 218: Basic Structures: Sets, Functions, Sequences, Sums, and

Review questions

Example: Given U = {0,1,2,3,4,5,6,7,8,9,10},A = {1,2,3,4,5}, B = {4,5,6,7,8} solve the following:

1 A ∪ B

Solution:{1,2,3,4,5,6,7,8}

2 A ∩ B

Solution: {4,5}3 A

Solution:{0,6,7,8,9,10}

4 B

Solution:{0,1,2,3,9,10}

5 A − B

Solution: {1,2,3}6 B − A

Solution: {6,7,8}

Page 219: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 220: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 Identity laws

A ∪ ∅ = A A ∩U = A

2 Domination laws

A ∪U = U A ∩ ∅ = ∅

3 Idempotent laws

A ∪A = A A ∩A = A

4 Complementation law

(A) = A

Continued on next slide ↪

Page 221: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 Identity laws

A ∪ ∅ = A A ∩U = A

2 Domination laws

A ∪U = U A ∩ ∅ = ∅

3 Idempotent laws

A ∪A = A A ∩A = A

4 Complementation law

(A) = A

Continued on next slide ↪

Page 222: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 Identity laws

A ∪ ∅ = A A ∩U = A

2 Domination laws

A ∪U = U A ∩ ∅ = ∅

3 Idempotent laws

A ∪A = A A ∩A = A

4 Complementation law

(A) = A

Continued on next slide ↪

Page 223: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 Identity laws

A ∪ ∅ = A A ∩U = A

2 Domination laws

A ∪U = U A ∩ ∅ = ∅

3 Idempotent laws

A ∪A = A A ∩A = A

4 Complementation law

(A) = A

Continued on next slide ↪

Page 224: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 Commutative laws

A ∪B = B ∪A A ∩B = B ∩A

2 Associative laws

A ∪ (B ∪ C) = (A ∪B) ∪ C A ∩ (B ∩ C) = (A ∩B) ∩ C

3 Distributive laws

A ∩ (B ∪ C) = (A ∩B) ∪ (A ∩ C) A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Continued on next slide ↪

Page 225: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 Commutative laws

A ∪B = B ∪A A ∩B = B ∩A

2 Associative laws

A ∪ (B ∪ C) = (A ∪B) ∪ C A ∩ (B ∩ C) = (A ∩B) ∩ C

3 Distributive laws

A ∩ (B ∪ C) = (A ∩B) ∪ (A ∩ C) A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Continued on next slide ↪

Page 226: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 Commutative laws

A ∪B = B ∪A A ∩B = B ∩A

2 Associative laws

A ∪ (B ∪ C) = (A ∪B) ∪ C A ∩ (B ∩ C) = (A ∩B) ∩ C

3 Distributive laws

A ∩ (B ∪ C) = (A ∩B) ∪ (A ∩ C) A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Continued on next slide ↪

Page 227: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 De Morgan’s laws

A ∪B = A ∩B A ∩B = A ∪B

2 Absorption laws

A ∪ (A ∩B) = A A ∩ (A ∪B) = A

3 Complement laws

A ∪A = U A ∩A = ∅

Page 228: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 De Morgan’s laws

A ∪B = A ∩B A ∩B = A ∪B

2 Absorption laws

A ∪ (A ∩B) = A A ∩ (A ∪B) = A

3 Complement laws

A ∪A = U A ∩A = ∅

Page 229: Basic Structures: Sets, Functions, Sequences, Sums, and

Set identities

1 De Morgan’s laws

A ∪B = A ∩B A ∩B = A ∪B

2 Absorption laws

A ∪ (A ∩B) = A A ∩ (A ∪B) = A

3 Complement laws

A ∪A = U A ∩A = ∅

Page 230: Basic Structures: Sets, Functions, Sequences, Sums, and

Proving set identities

1 Different ways to prove set identities:

a Prove that each set (i.e. each side of the identity) is a subsetof the other.

b Use set builder notation and propositional logic.c Membership tables

(to be explained)

Page 231: Basic Structures: Sets, Functions, Sequences, Sums, and

Proving set identities

1 Different ways to prove set identities:

a Prove that each set (i.e. each side of the identity) is a subsetof the other.

b Use set builder notation and propositional logic.c Membership tables

(to be explained)

Page 232: Basic Structures: Sets, Functions, Sequences, Sums, and

Proving set identities

1 Different ways to prove set identities:

a Prove that each set (i.e. each side of the identity) is a subsetof the other.

b Use set builder notation and propositional logic.

c Membership tables

(to be explained)

Page 233: Basic Structures: Sets, Functions, Sequences, Sums, and

Proving set identities

1 Different ways to prove set identities:

a Prove that each set (i.e. each side of the identity) is a subsetof the other.

b Use set builder notation and propositional logic.c Membership tables

(to be explained)

Page 234: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

Example: Prove that A ∩B = A ∪B

Solution: We prove this identity by showing that:

1 A ∩B ⊆ A ∪B

2 A ∪B ⊆ A ∩B

Continued on next slide ↪

Page 235: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

Example: Prove that A ∩B = A ∪B

Solution: We prove this identity by showing that:

1 A ∩B ⊆ A ∪B

2 A ∪B ⊆ A ∩B

Continued on next slide ↪

Page 236: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

Example: Prove that A ∩B = A ∪B

Solution: We prove this identity by showing that:

1 A ∩B ⊆ A ∪B

2 A ∪B ⊆ A ∩B

Continued on next slide ↪

Page 237: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 238: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 239: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 240: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 241: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 242: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 243: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 244: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∩B ⊆ A ∪B

x ∈ A ∩B by assumption

x ∉ A ∩B definition of complement

¬((x ∈ A) ∧ (x ∈ B)) definition of intersection

¬(x ∈ A) ∨ ¬(x ∈ B) De Morgan’s 1st Law

(x ∉ A) ∨ (x ∉ B) definition of negation

(x ∈ A) ∨ (x ∈ B) definition of complement

x ∈ A ∪B definition of union

Continued on next slide ↪

Page 245: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 246: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 247: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 248: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 249: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 250: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 251: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 252: Basic Structures: Sets, Functions, Sequences, Sums, and

Proof of second De Morgan law

These steps show that: A ∪B ⊆ A ∩B

x ∈ A ∪B by assumption

(x ∈ A) ∨ (x ∈ B) definition of union

(x ∉ A) ∨ (x ∉ B) definition of complement

¬(x ∈ A) ∨ ¬(x ∈ B) definition of negation

¬((x ∈ A) ∧ (x ∈ B)) De Morgan’s 1st Law

¬x ∈ (A ∩B) definition of intersection

x ∈ A ∩B definition of complement

Page 253: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 254: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 255: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 256: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 257: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 258: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 259: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 260: Basic Structures: Sets, Functions, Sequences, Sums, and

Set-builder notation: second De Morgan law

A ∩B = {x ∣ x ∉ A ∩B} by definition of complement

= {x ∣ ¬x ∈ (A ∩B)} by definition of ‘not in’

= {x ∣ ¬((x ∈ A) ∧ (x ∈ B))} by definition of intersection

= {x ∣ ¬(x ∈ A) ∨ ¬(x ∈ B)} by De Morgan’s 1st Law

= {x ∣ (x ∉ A) ∨ (x ∉ B)} by definition of ‘not’

= {x ∣ (x ∈ A) ∨ (x ∈ B)} by definition of complement

= {x ∣ x ∈ A ∪B} by definition of union

= A ∪B by definition of notation

Page 261: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1

1 1 1

1 1 0

0 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 262: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1

1 1 1

1 1 0

0 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 263: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1

1 1

1 1 0

0 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 264: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1

1 1

1 1 0

0 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 265: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1

1

1 1 0

0 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 266: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1

1 1 0

0 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 267: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0

0 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 268: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0

1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 269: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1

1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 270: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1

1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 271: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 272: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1

0 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 273: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0

1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 274: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1

1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 275: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1

1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 276: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 277: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0

0 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 278: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0

1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 279: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1

1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 280: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1

1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 281: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 282: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1

1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 283: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1

1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 284: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1

1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 285: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1

1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 286: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 287: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0

0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 288: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0

1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 289: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0

1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 290: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1

0

0 0 1

0 0 1

0 0 0

0 0 0

Page 291: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 292: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1

0 0 1

0 0 0

0 0 0

Page 293: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0

0 1

0 0 0

0 0 0

Page 294: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0

0 1

0 0 0

0 0 0

Page 295: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0

1

0 0 0

0 0 0

Page 296: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1

0 0 0

0 0 0

Page 297: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1 0

0 0 0

0 0 0

Page 298: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1 0

0 0 0 0

0 0

Page 299: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1 0

0 0 0 0 0

0 0

Page 300: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1 0

0 0 0 0 0 0

0

Page 301: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1 0

0 0 0 0 0 0 0

Page 302: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1 0

0 0 0 0 0 0 0 0

Page 303: Basic Structures: Sets, Functions, Sequences, Sums, and

Membership table

Example: Construct a membership table to show that thedistributive law holds:

A ∪ (B ∩ C) = (A ∪B) ∩ (A ∪ C)

Solution:

A B C B ∩ C A ∪ (B ∩ C) A ∪B A ∪ C (A ∪B) ∩ (A ∪ C)1 1 1 1 1 1 1 1

1 1 0 0 1 1 1 1

1 0 1 0 1 1 1 1

1 0 0 0 1 1 1 1

0 1 1 1 1 1 1 1

0 1 0 0 0 1 0 0

0 0 1 0 0 0 1 0

0 0 0 0 0 0 0 0

Page 304: Basic Structures: Sets, Functions, Sequences, Sums, and

Plan for Part I1. Sets1.1 Defining sets1.2 Venn Diagram1.3 Set Equality1.4 Subsets1.5 Venn Diagrams and Truth Sets1.6 Set Cardinality1.7 Power Sets1.8 Cartesian Products

2. Set Operations2.1 Boolean Algebra2.2 Union2.3 Intersection2.4 Complement2.5 Difference2.6 The Cardinality of the Union of Two Sets2.7 Set Identities2.8 Generalized Unions and Intersections

Page 305: Basic Structures: Sets, Functions, Sequences, Sums, and

Generalized unions and intersections

1 Let A1, A2 ,. . . , An be an indexed collection of sets.

We define:

n

⋃i=1

Ai = A1 ∪A2 ∪ ⋅ ⋅ ⋅ ∪An

n

⋂i=1

Ai = A1 ∩A2 ∩ ⋅ ⋅ ⋅ ∩An

These are well defined, since union and intersection areassociative.

2 Example: for (i = 1,2, . . . ) let Ai = {i , i + 1, i + 2, . . .}. Then,

n

⋃i=1

Ai =n

⋃i=1

{i , i + 1, i + 2, . . .} = {1,2,3, . . .}

n

⋂i=1

Ai =n

⋂i=1

{i , i + 1, i + 2, . . .} = {n,n + 1,n + 2, . . .} = An

Page 306: Basic Structures: Sets, Functions, Sequences, Sums, and

Generalized unions and intersections

1 Let A1, A2 ,. . . , An be an indexed collection of sets.

We define:n

⋃i=1

Ai = A1 ∪A2 ∪ ⋅ ⋅ ⋅ ∪An

n

⋂i=1

Ai = A1 ∩A2 ∩ ⋅ ⋅ ⋅ ∩An

These are well defined, since union and intersection areassociative.

2 Example: for (i = 1,2, . . . ) let Ai = {i , i + 1, i + 2, . . .}. Then,

n

⋃i=1

Ai =n

⋃i=1

{i , i + 1, i + 2, . . .} = {1,2,3, . . .}

n

⋂i=1

Ai =n

⋂i=1

{i , i + 1, i + 2, . . .} = {n,n + 1,n + 2, . . .} = An

Page 307: Basic Structures: Sets, Functions, Sequences, Sums, and

Generalized unions and intersections

1 Let A1, A2 ,. . . , An be an indexed collection of sets.

We define:n

⋃i=1

Ai = A1 ∪A2 ∪ ⋅ ⋅ ⋅ ∪An

n

⋂i=1

Ai = A1 ∩A2 ∩ ⋅ ⋅ ⋅ ∩An

These are well defined, since union and intersection areassociative.

2 Example: for (i = 1,2, . . . ) let Ai = {i , i + 1, i + 2, . . .}. Then,

n

⋃i=1

Ai =n

⋃i=1

{i , i + 1, i + 2, . . .} = {1,2,3, . . .}

n

⋂i=1

Ai =n

⋂i=1

{i , i + 1, i + 2, . . .} = {n,n + 1,n + 2, . . .} = An

Page 308: Basic Structures: Sets, Functions, Sequences, Sums, and

Generalized unions and intersections

1 Let A1, A2 ,. . . , An be an indexed collection of sets.

We define:n

⋃i=1

Ai = A1 ∪A2 ∪ ⋅ ⋅ ⋅ ∪An

n

⋂i=1

Ai = A1 ∩A2 ∩ ⋅ ⋅ ⋅ ∩An

These are well defined, since union and intersection areassociative.

2 Example: for (i = 1,2, . . . ) let Ai = {i , i + 1, i + 2, . . .}. Then,

n

⋃i=1

Ai =n

⋃i=1

{i , i + 1, i + 2, . . .} = {1,2,3, . . .}

n

⋂i=1

Ai =n

⋂i=1

{i , i + 1, i + 2, . . .} = {n,n + 1,n + 2, . . .} = An