Introduction To Sets

In this article, I will introduce you to sets and its notations. There are many definitions for sets. But no one single definition is acceptable. So, I will start with a simple informal definition of a set.

“A set is group of objects with some properties and sometimes the object from same group does not share same properties”.

Figure 1 - Set A is a set of students from a school.
Figure 1 – Set A is a set of students from a school.

Suppose A is a set of students from a school. Students in school are a in a set, but all students do not study same course. Some study math and other study programming and so on. In other words, they have different properties.

Figure 2 - Set of fruits with different tastes and colors
Figure 2 – Set of fruits with different tastes and colors

Let B be a set of fruits: it has {apple, oranges, banana} and all fruits have different taste and color.

What is the definition of set?

The formal definition of a set is:

A set is an unordered collection of objects called its members or elements. A set contains elements or members.

Here unordered is important and we will come back to it later. If an element belongs to a set, then we write a \in A which means element ‘a’ is in set A.

Figure 3 - Element a is in set A is shown with the "in" operator.
Figure 3 – Element a is in set A is shown with the “in” operator.

If an element does not belong to a set, we write a \notin A which means that element ‘a’ is not in set A.

Figure 4 - Symbol to indicate that element a is not in set A.
Figure 4 – Symbol to indicate that element a is not in set A.

Set Notations

There are two ways to describe a set.

  • Roster notation
  • Set builder notation.

Roster notation

In roster method, you simply list all the elements of a set within braces. If A is a set of soft drinks, then list all the elements inside curly braces, separated with a comma. You have already seen an example above.

Figure 5- Roster notation for sets
Figure 5- Roster notation for sets

The roster method works when you have limited elements in a set. In other words you can count the number of elements in a set.

Set Builder Notation

When the size of set is too large, and you are not able to list the element, use the set builder notation. You are simple creating a rule for the elements of a set.

For example:

Suppose N is set of all numbers less than 100, then you write this in set builder notation within curly braces like this.

A = {x \in N \mid x < 100}
Figure 6 - Set builder notation
Figure 6 – Set builder notation

Note that we wrote N as a set, not A because N is set of natural numbers from which we got elements of A. Sometimes elements of a set come from a bigger group called its Universe.

Rate this post