Set Notation
What is a set?
- A set is a collection of elements
- Elements could be anything
- Numbers, letters, coordinates, ...
- Elements could be anything
- You could describe a set by writing its elements inside curly brackets {}
- {1, 2, 3, 6} is the set of factors of 6
- If the set of elements follow a rule then you can write this using a colon inside the curly brackets {... : ...}
- The bit before the colon is the type of element
- The bit after the colon is the rule
- {x is a positive integer : x2 < 30} is the set of positive integers which, when squared, are less than 30
- This is equal to {1, 2, 3, 4, 5}
- The colon is often read as 'such that'
- If no type is specified, x can take any value (fractions, decimals, irrationals, ...)
- {x: x2 < 30} means any value whose square is less than 30
What do I need to know about set notation?
- is the universal set (the set of everything)
- For example, if we are only interested in factors of 24 then = {1, 2, 3, 4, 6, 8, 12, 24}
- You may see alternative notations used for
- U is a common alternative
- S or the Greek letter ξ (xi) may also be seen
- We use upper case letters to represent sets (A, B, C, ...) and lower case letters to represent elements (a, b, c, ...)
- n(A) is the number of elements in set A
- For example, if = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, A = {1, 4, 9}, B = {1, 2, 3, 4, 5, 6}
n(A) = 3, n(B) = 6
- For example, if = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}, A = {1, 4, 9}, B = {1, 2, 3, 4, 5, 6}
- ∈ means "is an element of"
- e.g. 3 ∈ {1, 2, 3, 6} because 3 is an element of the set {1, 2, 3, 6}
- A ∩ B means the intersection of A and B (the overlap of A and B)
- This is the set of elements that are in both set A and set B
A ∩ B = {1, 4}
- This is the set of elements that are in both set A and set B
- A U B means the union of A and B (everything in A or B or both)
- This is the set of elements that are in at least one of the sets
- This includes elements in both sets (in the intersection)
A U B = {1, 2, 3, 4, 5, 6, 9}
- A' means the complement of A
- It is the set of all elements in the universal set that are not in A
A' = {7, 8, 9, 10}
- It is the set of all elements in the universal set that are not in A