Chapter II - Sets
Chapter II - Sets
Chapter II - Sets
Sets
NGUYEN CANH Nam1
1 Faculty of Applied Mathematics Department of Applied Mathematics and Informatics Hanoi University of Technologies [email protected]
HUT - 2010
Mathematics I - Chapter 2
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Sets
Denition A collection or assembly of objects is called a set. Each object is called a element of set. The relation "is an element of", also called set membership, is denoted by . Writing x A, means that "x is an element of A". The negation of set membership is denoted by . If x is not an element of A we said "x doesnt belong to A" and write x A.
NGUYEN CANH Nam Mathematics I - Chapter 2
Sets
Examples
The students of the class ICT-K54 The rst ten natural numbers
Mathematics I - Chapter 2
Sets
Venn diagram
Venn diagrams or set diagrams are diagrams that show all hypothetically possible logical relations between a nite collection of sets. A set is simple closed curve drawn in the plane and a point inside that curve is an element of set.
Mathematics I - Chapter 2
Sets
Cardinality
The cardinality of a set S, denoted by |S|, is "the number of members of S". For example, B is the set of colors of the French ag, we have |B| = 3. There is a unique set with no members and zero cardinality, which is called the empty set (or the null set) and is denoted by the symbol . For example, the set of all real solutions of the equation x 2 + 1 = 0 has zero members and thus is the empty set. Some sets have innite cardinality. The set of natural numbers, for instance, is innite.
NGUYEN CANH Nam Mathematics I - Chapter 2
Sets
Special sets
IP, denoting the set of all primes: IP = {2, 3, 5, 7, 11, 13, 17, ...}. IN, denoting the set of all natural numbers: IN = {0, 1, 2, ...}. Z denoting the set of all integers : Z, Z = {..., 2, 1, 0, 1, 2, ...}. Z O , denoting the set of all rational numbers : Q O = {a/b : a, b Z b = 0}. For example, 1/4 O and Q Z, Q 11/6 O . All integers are in this set since every integer a Q can be expressed as the fraction a/1. IR, denoting the set of all real numbers. This set includes all rational numbers, together with all irrational numbers (that is, numbers which cannot be rewritten as fractions, such as , e, and 2.
NGUYEN CANH Nam Mathematics I - Chapter 2
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Specifying
Specifying the members of a set by pointing out the characteristic properties of elements of the set. Example A is the set whose members are the rst four positive integers. B is the set of colors of the French ag. The set F of the twenty smallest integers that are four less than perfect squares: F = {n2 4 : n is an integer; and 0 n 19}, the colon (":") means "such that". Sometimes the vertical bar ("|") is used instead of the colon.
NGUYEN CANH Nam Mathematics I - Chapter 2
Enumeration
Listing each member of the set. An extensional denition is denoted by enclosing the list of members in brackets. Example A = {4, 2, 1, 3} B = {blue, white, red} For sets with many elements, the enumeration of members can be abbreviated. For instance, the set of the rst thousand positive integers {1, 2, 3, ..., 1000} (the ellipsis ("...") indicates that the list continues in the obvious way) Ellipses may also be used where sets have innitely many members, the set of positive even numbers {2, 4, 6, 8, ...}.
NGUYEN CANH Nam Mathematics I - Chapter 2
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Subsets
Denition If every member of set A is also a member of set B, then A is said to be a subset of B, written A B (also pronounced "A is contained in or equal to B"). Equivalently, we can write B A, read as B is a superset of A, B includes A, or B contains A. The relationship between sets established by is called inclusion or containment. If A is a subset of, but not equal to, B, then A is called a proper subset of B, written A B (A is a proper subset of B) or B A (B is proper superset of A).
Mathematics I - Chapter 2
Subsets
Examples
Example The set of all men is a proper subset of the set of all people. {1, 2, 3, 4} {1, 2, 3, 4}.
The empty set is a subset of every set and every set is a subset of itself: A. A A.
NGUYEN CANH Nam Mathematics I - Chapter 2
Subsets
Equality
Two seemingly different sets are equal A = B if and only if A B and B A. If A and B are not equal we write A=B Example Let A = {x | x 2 = 1} and B = {1, 1}. Although A and B are described in different ways they have the same elements and so A = B.
NGUYEN CANH Nam Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Intersection
Denition The intersection of A and B, denoted by A B, is the set of all things which are members of both A and B (x (A B)) (x A and x B) If A B = , then A and B are said to be disjoint. Venn diagram
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Intersection
Example
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Intersection
Properties
A B = B A. A B A. A A = A. A = .
A (B C) = (A B) C.
A B if and only if A B = A.
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Union
Denition The union of A and B, denoted by A B, is the set of all things which are members of either A or B (x (A B)) (x A or x B) Venn diagram
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Union
Example
{1, 2} {red, white} = {1, 2, red, white}. {1, 2} {1, 2} = {1, 2}.
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Union
Properties
A B = B A. A (A B). A A = A. A = A.
A (B C) = (A B) C.
A B if and only if A B = B.
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Difference of sets
Denition The difference of A and B, denoted by A \ B, (or A B) is the set of all elements which are members of A but not members of B (x (A \ B)) (x A and x B) Venn diagram
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Difference of sets
Example
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Compliment of a subset
Denition Let U be a set and A is a subset of U. The difference U \ A is called complement of A in U and denoted by A Venn diagram
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Compliment of a subset
Example
U is the set of integers, E is the set of even integers, and O is the set of odd integers, then E = O.
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
A \ B = B \ A. A A = U. A A = . (A) = A. A \ A = .
U = and = U. A \ B = A B.
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Laws
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Laws
continue...
Denote
i=1
Ai = A1 . . . An and
n
have
i=1 n
Ai = A1 . . . An we then
Ai =
i=1 n i=1 n
Ai
Ai =
i=1 i=1
Ai
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Theorem
X\ X\
Ai =
i=1 n n
i=1
(X \ Ai )
Ai =
i=1
i=1
(X \ Ai )
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Agenda
1
Sets and elements Some denitions and notations The ways to determine a set Subsets Set operations Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets Some properties of nite sets
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Denition The Cartesian product of two sets X (for example the points on an xaxis) and Y (for example the points on an y-axis), denoted X Y , is the set of all possible ordered pairs whose rst component is a member of X and whose second component is a member of Y (e.g., the whole of the xy plane): X Y = {(x, y)|x X and y Y }.
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
{1, 2} {red, white} = {(1, red), (1, white), (2, red), (2, white)}. Let A represent the set of all students at a university, and let B represent the set of all courses offered at the university. The Cartesian product A B can be used to represent all possible enrollments of students in courses at the university
Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
The Cartesian Product acts nicely with respect to intersections. (A B) (C D) = (A C) (B D) Notice that in most cases the above statement is not true if we replace intersection with union. (A B) (C D) = (A C) (B D) However, for intersection and union it holds for: A (B C) = (A B) (A C) and, A (B C) = (A B) (A C).
NGUYEN CANH Nam Mathematics I - Chapter 2
Intersection and union of sets Difference of sets, compliment of a subset Theorems The Cartesian product of sets
Cardinality
Assume that the number of elements of a set X is nite. Denote by N(X ) the cardinality of X. Theorem Let A and B be nite sets . Then we have N(A B) = N(A).N(B) Theorem a) For two disjoint sets A, B we have N(A B) = N(A) + N(B) b) For A, B are arbitrary , we have N(A B) = N(A) + N(B) N(A B)
NGUYEN CANH Nam Mathematics I - Chapter 2
Theorem For arbitrary nite sets A1 , A2 , . . . , Am , the number of elements of their union is counted by the formula N(A1 . . . Am ) = N1 N2 + N3 + . . . + (1)m Nm where N1 =
i=1 n
N(Ai ), . . . , Nk =
1i1 <i2 <...<ik m
Example N(A1 A2 A3 ) = N1 N2 + N3 where N1 = N(A1 ) + N(A2 ) + N(A3 ) N2 = N(A1 A2 ) + N(A2 A3 ) + N(A3 A1 ) N3 = N(A1 A2 A3 )
NGUYEN CANH Nam Mathematics I - Chapter 2
Exercises
Mathematics I - Chapter 2
Exercises
Mathematics I - Chapter 2
Exercises
Mathematics I - Chapter 2
Exercises
Exercise 4: Suppose we survey 200 students to see whether they are taking courses in computer science, mathematics, or physics. The results show that 90 students take computer science, 110 take mathematics, and 60 take physics. Further, 20 students take computer science and mathematics, 20 take computer science and physics, and 30 take mathematics and physics. We are interested in those students that take courses in all these areas. What could we say about the number of those students?
Mathematics I - Chapter 2
Exercises
Mathematics I - Chapter 2