Complement (set theory)

A circle filled with red inside a square. The area outside the circle is unfilled. The borders of both the circle and the square are black.
If A is the area colored red in this image…
An unfilled circle inside a square. The area inside the square not covered by the circle is filled with red. The borders of both the circle and the square are black.
… then the complement of A is everything else.

In set theory, the complement of a set A, often denoted by (or A′), is the set of elements not in A.

When all elements in the universe, i.e. all elements under consideration, are considered to be members of a given set U, the absolute complement of A is the set of elements in U that are not in A.

The relative complement of A with respect to a set B, also termed the set difference of B and A, written is the set of elements in B that are not in A.