Set

A set is a collection of distinct objects. Let’s look at some examples:

  • A family. Mother, father and two children forms a simple set of objects: a set of four people. Each person differs from other persons.
  • A deck of cards. A standard deck of cards has 52 cards inside and each card differs from each other. It forms a set of 52 distinct objects.
  • A set of all natural numbers forms our first infinite set. Each number differs from other numbers.

We usually denote the set as follows: {1, 2, 3, 4}. This forms a set of four numbers. We can write down the three sets defined above as follows:

  • {mother, father, son, daughter}
  • {two of clubs, three of clubs, …, red ace}
  • {1, 2, 3, 4, 5, …}

We use the three dots to denote an interval that is quite clear.

Elements of a Set

Each set consists of elements or members. Let’s suppose we have an object x and a set S. The object x is either an element of the set S or it isn’t element of the set S. If the object x is member of the set S we denote it as x ∈ S. If the object x doesn’t belong to the set S we denote it as x ∉ S. This “being element of” membership is all we need for defining a set.

Let’s says that for our set S we have 1 ∈ S, 2 ∈ S and 3 ∈ S and that’s all. We can write down the set using the curly brackets syntax: S = {1, 2, 3}. From our definition it follows:

  • The order doesn’t matter. {1, 2, 3} is the same set as the set {2, 3, 1}.
  • The repetition doesn’t matter. {1, 2, 3} is the same set as {1, 2, 2, 3, 3, 3}. Even though the number 3 is there three times it still tells us that 3 ∈ S and nothing more. In the definition of “being element of a set” are no words about the count.
  • The set can be empty. We can have a set S = {}. Sometimes we use different symbol for the empty set: .

What is Subset of a Set

We can have two sets: A and B. We say that the set A is a subset of a set B if all elements from the set A are also included in the set B. We denote this relation as A ⊆ B. Examples:

  • The set A = {1, 2} is a subset of B = {1, 2, 3} since both the elements 1 and 2 from A are also in B. On the other hand, the set B is not a subset of A since the element 3 is not member of the set A. Thus we have A ⊆ B but we have B ⊈ A.
  • The set A = {a, b, c} is not a subset of B = {a, b, e} since the element c is not member of set B.
  • The empty set is a subset of each set. So for each set A we have ∅ ⊆ A.
  • The set A is always a subset of a set A. The set is its own subset. It is simply because the set A contains all the elements that contains the set A. Obviously.

We can express a subset of a set in a picture. Let’s suppose two sets A and B with relation A ⊆ B. Then we can express this relation as follows:

Subset of a set

We have a “bigger” set B and inside of it is a “smaller” set A. This represents the fact that the set A contains all elements from the set B and the set B can contains some additional elements.

Remark: Sometimes we use another symbol for the subset relation. Instead of we use . And sometimes the latter symbol is used for proper subset.

The set A is a proper subset of B if A ⊆ B but B ⊈ A. Basically it means that the sets must not be equal, the set B must contain some elements that the set A doesn’t contain. Examples:

  • The set A = {1, 2} is a proper subset of B = {1, 2, 3}, we can write A ⊂ B.
  • The set A = {1, 2, 3} is not a proper subset of B = {1, 2, 3} since the set A contains all the elements of B, thus A ⊄ B.

Set Equality

With the knowledge of the term subset we can easily define the set equality. Two sets A and B are equal if and only if A ⊆ B and B ⊆ A. Does it make sense?

  • If A ⊆ B then all elements from A are also in B,
  • if B ⊆ A then all elements from B are also in A.

Thus, the only conclusion is that both sets contains the exact same elements. Then we say the sets are equal and we write A = B. Examples:

  • {1, 2, 3} = {1, 2, 3} (trivially)
  • {1, 2} = {1, 1, 1, 1, 2} (because sets doesn’t allow element repetition)
  • {a, b, c} ≠ {a, b} (because the second set doesn’t contain the c element)
  • {{1}, 2} ? {1, 2} – this one is tricky. Do the sets equal? The answer is no, because the first set contains as an element the set {1} and the seconds set contains as an element the number 1. Those are not equal, the set {1} differs from the number 1 simply because any set cannot be equal to any number. A set is a set and a number is a number. Thus {{1}, 2} ≠ {1, 2}.

Power Set

The power set of a set S is a set of all subsets of S. Huh, that sounds complicated! Let’s look at the example. Suppose we have set S = {a, b}. What are all the subsets of this set S?

  • since empty set is subset of each set,
  • {a} and {b},
  • {a, b} since S is always subset of S.

Now we put all those subsets to a new set. We get:

{∅, {a}, {b}, {a, b}}

And this is exactly the power set of S. We usually denote it as P(S). Thus

P({a, b}) = {∅, {a}, {b}, {a, b}}.

Some basic properties for the power set of any set S:

  • ∅ ∈ P(S): the empty set is always included in the power set.
  • S ∈ P(S): the set S itself is always included in the power set.