## What is a Cardinality?

In mathematics, the cardinality of a set is a measure of the “number of elements” of the set. For example, the set A = {1, 2, 3} has a cardinality of 3. There are two approaches to cardinality – one which compares sets directly using bijections and another which uses cardinal numbers.

When comparing sets directly, we say that two sets have the same cardinality if there exists a bijection between them. In other words, if we can put the elements of one set into one-to-one correspondence with the elements of the other set. For example, the sets A = {1, 2, 3} and B = {x, y, z} have the same cardinality since we can define a bijection between them such as:

A = {1, 2, 3}

B = {x, y, z}

1 ↦ x

2 ↦ y

3 ↦ z

In this case, there are no leftover elements in either set – each element in A corresponds to exactly one element in B and vice versa. We say that two sets have different cardinalities if there does not exist such a bijection.

Another approach to cardinality is to assign a cardinal number to each set. In this case, we simply say that two sets have the same cardinality if they have been assigned the same number. So for our previous example:

A = {1, 2 ,3} has been assigned the number 3 since it contains three elements.

B = {x ,y ,z} has also been assigned the number 3 since it also contains three elements.

This approach has its advantages – it allows us to compare infinite sets using finite numbers – but it can be difficult to compute these numbers for some sets.

## Cardinality of a Set

The cardinality of a set is a measure of the number of elements in the set. It is usually denoted by |S|. For example, if S = {a, b, c}, then |S| = 3.

## Subsets and Supersets

There are two types of constraints that can be placed on the cardinality of a set: subsets and supersets. A subset is a constraint that allows for a smaller number of elements in the set, while a superset is a constraint that allows for a larger number of elements. For example, if we were to constrained the cardinality of a set to be 10, we would say that it is a subset of 20. Similarly, if we were to constrained the cardinality of a set to be 20, we would say that it is a superset of 10.

## Infinite Sets

An infinite set is a set that has an infinite number of elements. Examples of infinite sets include the set of all integers, the set of all real numbers, and the set of all complex numbers.