# Simple Set Theory

See also: Simple Statistical AnalysisA set is a collection of objects, nothing more and nothing less.

It sounds simple, but set theory is one of the basic building blocks for higher mathematics, so it helps to understand the basics well.

This page sets out the principles of sets, and the elements within them. It also explains about operations involving sets.

## The Language of Sets: Some Definitions

Unfortunately, like several other branches of mathematics, set theory has its own language which you need to understand. Here are some useful terms and definitions:

- A
**set**is a collection of objects, with something in common. A set might be, for example, prime numbers, birds that come into your garden, or people to whom you have sent Christmas cards in the last five years. - The
**elements**of a set are the things within it, such as prime numbers, birds or people as in the examples above. They are also called the**members**of a set. - The symbol
**∈**means ‘is an element of’. For example, you might write 2 ∈ A, which would mean that 2 was an element of set A. You can also write**∉**, which means ‘is not an element of’. - You can show that something is in a set in two simple ways:
- In words, for example ‘All the species of birds I have seen in my garden’, or ‘the prime numbers between 0 and 100’; and
- By putting curly brackets around a list of the elements. For example, the set of prime numbers between 0 and 10 could be written {1, 2, 3, 5, 7}. You can also use ellipses if you would have to write too many numbers. For example, if your set were all the numbers between 1 and 20, you could write {1, 2, 3, …20}.

WARNING!

If you are going to use ellipses, make sure that the contents of your set are unambiguous. For example, if your set were every third number between 1 and 50, it would not be enough to write {1…50} because that could also be every number between 1 and 50.

- Sets are usually shown by a capital letter, to distinguish them from variables in
**algebra**, which are usually written lower case. - Sets may contain
**tangible**or**intangible**elements, provided that you define them clearly and unambiguously. - The
**cardinality**of a set is the number of elements a set contains. - Sets that contain the same elements are said to be
**equal**. You can also say that they are**equivalent**or**identical**.

Sets can still be identical even if one contains the same element twice: the equality lies in having the same constituents, **not in the quantities or the order**. So, for example, all the following sets are equal:

A = days of the week excluding weekends

B = {Monday, Tuesday, Wednesday, Thursday, Friday }

C = {Monday, Monday, Tuesday, Wednesday, Thursday, Tuesday, Friday}

- A set A whose elements are all contained within another, larger set B, with more elements, is said to be a
**subset**of B. The symbol**⊂**means ‘is a subset of’. In this case, A ⊂ B. - The
**empty set**has no elements at all. It is written**{}**or**Ø**. Because all empty sets are the same, there is only one (in other words, they are all equal). It is also a subset of every other set in the whole world! - The
**universal**set, or**U**, is everything. It is, however, specific to a particular problem, rather than being ‘everything in the whole world’. This means that you could, for example, define the universal set as ‘all numbers between 1 and 100’, or ‘all numbers between 1 and 10’, depending on your problem.

## Working with Sets

Just as numbers can be added, subtracted, multiplied and divided, there are four basic operations for sets:

Union, Intersection, Relative complement and Complement

We can look at each of these using three sets:

- A = {1, 2, 4, 7}
- B = {2, 5, 6, 8}
- C = {5, 10, 15, 20}

### Union

**Union is like adding.** The union of two sets is their combined elements, that is, all the elements that are in **either** set. The symbol for union is **∪**.

A ∪ B = {1, 2, 4, 7} ∪ {2, 5, 6, 8} = {1, 2, 4, 5, 6, 7, 8}

Remember!

When the same number appears in both sets, you only need to include it once in the union set.

The union of any set with itself is itself, A ∪ A = A.

The union of any set with the empty set is also itself, A ∪ ∅ = A

### Intersection

**The intersection between two sets is the elements that they have in common.** The symbol for intersection is **∩**.

Using the three sets above:

A ∩ B = {1, 2, 4, 7} ∩ {2, 5, 6, 8} = {2}

A ∩ C = {1, 2, 4, 7} ∩ {5, 10, 15, 20} = {}. In other words, there are no elements in common, so the intersection is the empty set.

### Relative Complement

If union is like addition, **relative complement is a bit like subtraction.** The symbol for it is the minus sign, -.

You start with the first set and take out every element that appears in the second set as well.

WARNING!

You do NOT end up with all the elements that are only in one or the other!

The reverse complement is ONLY those elements of the **first** set that are NOT also in the second set.

A – B = {1, 2, 4, 7} − {2, 5, 6, 8} = {1, 4, 7}

B – A = {2, 5, 6, 8} − {1, 2, 4, 7} = {5, 6, 8}

In each case, the only number that is in both is 2, so that is the only number that is removed from the first set.

### Complement

**The complement of a set is everything that is not in it.** This is where the universal set comes in useful, because the complement is U (the universal set) – the set you are working with.

The symbol for complement is ‘, so you would write A‘ or B‘ for the sets above.

Complement and Reverse Complement

Both complement and reverse complement are very similar to subtraction BUT

- To get the complement of a set, you subtract the set from
**the universal set**. - To get the reverse complement of a set, you subtract it from
**another defined set**.

### In conclusion…

Sets may not seem very useful on a day-to-day basis. However, they are extremely useful for higher mathematics, so bear with them. It’s good to understand the basics, so that you can come back to them later if necessary.

More Numeracy Skills You Need:

Introduction to Trigonometry

Fractions | Decimals | Positive and Negative Numbers

Percentages | BODMAS | Averages (Mean, Median and Mode)