0 Bewertungen0% fanden dieses Dokument nützlich (0 Abstimmungen)
354 Ansichten13 Seiten
A set is a distinct collection of objects. The objects are called elements. Sets can be visualized with circles in what is called a Venn Diagram. Some people could own both a dog and a cat.
A set is a distinct collection of objects. The objects are called elements. Sets can be visualized with circles in what is called a Venn Diagram. Some people could own both a dog and a cat.
A set is a distinct collection of objects. The objects are called elements. Sets can be visualized with circles in what is called a Venn Diagram. Some people could own both a dog and a cat.
11 th C SETS A = {1, 3, 2, 5} n(A) = | A | = 4 Sets use curly brackets The number of elements in Set A is 4 Sets are denoted by Capital letters A 3e A 7e 3 is an element of A 7 is not an element of A A set is a distinct collection of objects. The objects are called elements. {1, 2, 3, 4} = {2, 3, 1, 4} Order does not matter. If a set contains the same elements as another set, the sets are equal. {1, 3, 2, 3, 5, 2} We never repeat elements in a set. {1, 3, 2, 5} This symbol means "is a subset of" This is read "A is a subset of B". A c B A = {1, 2, 3} B = {1, 2, 3, 4, 5} {1, 2, 3, 5} In ascending order These sets can be visualized with circles in what is called a Venn Diagram. A B A B Everything that is in A or B. A B A B Everything that is in A AND B. A B 100 people were surveyed. 52 people in a survey owned a cat. 36 people owned a dog. 24 did not own a dog or cat. Draw a Venn diagram. universal set is 100 people surveyed C D Set C is the cat owners and Set D is the dog owners. The sets are NOT disjoint. Some people could own both a dog and a cat. 24 Since 24 did not own a dog or cat, there must be 76 that do. n(C D) = 76 This n means the number of elements in the set 52 + 36 = 88 so there must be 88 - 76 = 12 people that own both a dog and a cat. 12 40 24 Counting Formula: n(A B) = n(A) + n(B) - n(A B) Using the numbers 0, 1, 2, , 9 illustrate the sets: and A B 4 is in BOTH sides 4 Using the numbers 0, 1, 2, , 9 illustrate the sets: and A B 7 and 9 are only in set A 4 7 9 Using the numbers 0, 1, 2, , 9 illustrate the sets: and A B 1, 2, 3 and 5 are only in set B 4 7 9 1 2 3 5 Using the numbers 0, 1, 2, , 9 illustrate the sets: and A B 0, 6 and 8 are not in A or B 4 7 9 1 2 3 5 0 6 8 Set Equality Sets A and B are equal if and only if they contain exactly the same elements. Examples: Fall 2002 CMSC 203 - Discrete Structures 10 A = {9, 2, 7, -3}, B = {7, 9, -3, 2} : A = B A = {dog, cat, horse}, B = {cat, horse, squirrel, dog} : A =B A = {dog, cat, horse}, B = {cat, horse, dog, dog} : A = B Subsets Useful rules: A = B (A _ B) . (B _ A) (A _ B) . (B _ C) A _ C (see Venn Diagram) Fall 2002 CMSC 203 - Discrete Structures 11 U A B C The Power Set P(A) power set of A P(A) = {B | B _ A} (contains all subsets of A)
A = C P(A) = {C} Note: |A| = 0, |P(A)| = 1 Fall 2002 CMSC 203 - Discrete Structures 12 Cartesian Product The Cartesian product of two sets is defined as: AB = {(a, b) | aeA . beB} Example: A = {good, bad}, B = {student, prof}
AB = { Fall 2002 CMSC 203 - Discrete Structures 13 (good, student), (good, prof), (bad, student), (bad, prof)}