Set Theory Fundamentals

Set theory is the mathematical study of collections of objects. A set is any well-defined collection of distinct things; from this single idea, all of modern mathematics — numbers, functions, relations, infinity — can be constructed. Founded by Georg Cantor in the 1870s, it is the universal language underlying virtually every branch of mathematics.

A set is a collection of distinct objects, called its elements or members, considered as a single whole. The defining feature of a set is membership: for any object and any set, either the object belongs to the set or it does not. Set theory matters because it provides a common foundation — points, lines, numbers, and functions can all be encoded as sets, letting mathematicians build everything from one starting concept. The surprising fact, proved by Cantor, is that not all infinities are equal: the set of real numbers is "larger" than the set of natural numbers, even though both are infinite.

The Core Insight

A set is determined entirely by its members — nothing else. Two sets are equal precisely when they contain exactly the same elements (the Axiom of Extensionality). Order does not matter, and repetition does not matter: , , and are all the same set. This stripped-down notion of "collection" is so general that it can model nearly any mathematical object.

Formal Statement

Set, Element, and Membership

A set is a well-defined collection of distinct objects. If an object is a member of a set , we write:

1
⟳This is primitive notation — is read "is an element of" and is not defined in terms of anything simpler; it is the fundamental relation of set theory.

If is not a member of , we write . The symbols mean:

  • — an object (which may itself be a set)
  • — a set
  • — the membership relation

Set-Builder and Roster Notation

Sets are written in two main ways. Roster (list) notation lists members between braces:

2
⟳The braces denote "the set whose elements are exactly these"; order and repetition are irrelevant by extensionality.
Set-builder notation specifies a defining property :
3
⟳Read "" as "such that"; is the set of all for which the statement is true. E.g. .

The Empty Set

The empty set, written or , is the unique set with no elements:

4
⟳Since nothing satisfies , this collection has no members. Uniqueness follows from extensionality — any two empty sets contain "exactly the same elements" (namely none).

Subset and Equality

A set is a subset of (written ) if every element of is also in :

5
⟳ means "for all"; the arrow means "implies." This says membership in guarantees membership in .

Two sets are equal exactly when each is a subset of the other:

6
⟳This is the Axiom of Extensionality in operational form — sets with mutual containment have identical members. means "and."

A proper subset () means but .

Set Operations

For sets and inside a universal set :

7
⟳The
union collects everything in either set; means "or" (inclusive).
8
⟳The
intersection collects only what is in both sets simultaneously.
9
⟳The
difference ("relative complement") keeps elements of that are absent from .
10
⟳The
complement is everything in the universe that lies outside .

Power Set and Its Size

The power set is the set of all subsets of . If has elements (is finite of cardinality ), then:

11
⟳Each subset is formed by deciding, independently, "in or out" for each of the elements — giving choices.

Cantor's Theorem

For any set (finite or infinite), its power set is strictly larger:

12
⟳There can be no surjection from onto ; the proof builds a "diagonal" subset that no element of can be mapped to. This shows infinities come in different sizes.

Why It Holds / Derivation

De Morgan's Laws

We prove the first De Morgan law, , by showing mutual subset inclusion (equation [6]).

Step 1. Take any . By definition of complement [10], . Step 2. By definition of union [7], means it is false that ( or ). By logic, this is equivalent to ( and ). Step 3. Thus and , so by definition of intersection [8], . This proves . Step 4. Now take any . Then and , so is in neither set, hence , hence . This proves the reverse inclusion. Step 5. Both inclusions hold, so by [6] the sets are equal.

Cantor's Theorem by Diagonalization

We show no function can be surjective (hit every subset).

Step 1. Suppose, for contradiction, that is a surjection. For each , is a subset of . Step 2. Define the "diagonal" set:
This is a subset of , so . Step 3. Since is assumed surjective, there exists some with . Step 4. Ask: is ? By the definition of , . So if and only if — a contradiction. Step 5. The assumption fails: no surjection exists. Hence .

Georg Cantor | 1845–1918

Georg Cantor, a German mathematician born in St. Petersburg, single-handedly created set theory in the 1870s–1880s. He proved that the rational numbers are countable but the real numbers are not, establishing that infinity comes in different sizes. His introduction of cardinal and ordinal numbers and the "diagonal argument" revolutionized mathematics. His ideas met fierce resistance — Leopold Kronecker called them dangerous — and Cantor suffered repeated depressive episodes. Today his work is foundational to nearly all of modern mathematics.

Building Intuition

Think of a set as a box with no order and no duplicates — only the question "is this thing in the box?" matters. A subset is a box whose contents are entirely contained in a bigger box. Union is dumping two boxes together (throwing away duplicates); intersection is keeping only what both boxes share. The power set is the box containing every possible smaller box you could form — and Cantor's theorem says this "box of boxes" is always strictly bigger than the original, even when the original is infinite. The empty set is the box with nothing in it — and crucially, the empty box is still a box, which is why is a perfectly good set.

Venn diagram of two sets showing union, intersection, and complement within a universal set U

U (universe) A B A∩B A∪B = both circles Aᶜ = outside A

Worked Examples

Power Set of a 3-Element Set

Given: . Find and verify equation [11]. Step 1. By [11], the number of subsets is . Step 2. List all subsets by size:
  • Size 0:
  • Size 1:
  • Size 2:
  • Size 3:
Step 3. Count: . ✓ (These are the binomial coefficients .)

Set Operations with Numbers

Given: Universe , , . Step 1. Union [7]: combine all elements (no repeats):
Step 2. Intersection [8]: keep shared elements:
Step 3. Difference [9]: minus what is in :
Step 4. Complement [10]: minus :
Step 5. Verify De Morgan [proof above]: . Also . ✓

Common Misconceptions

Element vs. Subset

The two most confused relations are membership () and subset (). For :

  • ✓ (1 is an element)
  • ✗ (1 is not even a set; this is meaningless/false)
  • ✓ (the set containing 1 is a subset)
  • ✗ (the set is not listed as an element)
  • ✓ (the set is a listed element)

Also note: for every set (vacuously true), but only if is explicitly an element.

Naïve Comprehension Fails — Russell's Paradox

One might think any property defines a set . This is false. Consider:

Ask: is ? If , then by its defining property . If , then it satisfies the property, so . Both cases contradict — so cannot exist as a set. This 1901 paradox showed naïve set theory is inconsistent, forcing the development of axiomatic set theory (ZFC), which restricts which collections count as sets.

Connections

Set theory is the connective tissue of mathematics. Functions and Relations are defined as sets of ordered pairs. The number systems of Natural Numbers are constructed set-theoretically (e.g., , , ). Mathematical Logic supplies the symbols that set-builder notation relies on. Cardinality and Infinity extends counting to infinite sets via Cantor's theorem [12]. And Probability Theory defines events as subsets of a sample space, with union and intersection encoding "or" and "and."

Real-World Applications

  1. Databases (SQL): Queries use UNION, INTERSECT, and EXCEPT — direct implementations of equations [7]–[9] on sets of records.
  2. Search engines: Boolean searches ("cats AND dogs NOT mice") compute intersections, unions, and differences of document sets.
  3. Digital logic & circuit design: Bit operations AND/OR/NOT correspond exactly to , , and complement, formalized via Boolean algebra.
  4. Probability & statistics: Sample spaces, events, and the inclusion–exclusion principle all rest on set operations.
  5. Computer science type systems: A data type is essentially the set of values it can hold; subtyping is a subset relation [5].
  6. Classification & taxonomy: Biological hierarchies (species ⊆ genus ⊆ family) are nested subsets.
  7. Voting & social choice: Coalitions are subsets of voters; power-set analysis [11] counts possible alliances.

Historical Development

  • 1874 — Georg Cantor publishes his first paper proving the algebraic numbers are countable and the reals are not, launching set theory.
  • 1878 — Cantor formulates the Continuum Hypothesis: there is no infinity strictly between and .
  • 1883 — Cantor introduces transfinite ordinal and cardinal numbers.
  • 1891 — Cantor publishes the diagonal argument, the cleanest proof of (equation [12]).
  • 1901 — Bertrand Russell discovers Russell's Paradox, exposing the inconsistency of naïve comprehension.
  • 1908 — Ernst Zermelo proposes the first axiomatization of set theory to avoid paradoxes.
  • 1922 — Abraham Fraenkel and Thoralf Skolem refine it into Zermelo–Fraenkel set theory (ZF); adding the Axiom of Choice gives ZFC, the modern standard.
  • 1931 — Kurt Gödel's incompleteness theorems show no axiom system (including ZFC) can prove its own consistency.
  • 1963 — Paul Cohen invents forcing and proves the Continuum Hypothesis is independent of ZFC — it can be neither proved nor disproved.

Subtleties & Limits

The Continuum Hypothesis (CH) asks whether any infinite set of real numbers must be either countable (size ) or as large as all reals (size ) — with nothing in between. Gödel (1940) showed CH cannot be disproved from ZFC; Cohen (1963) showed it cannot be proved either. CH is therefore independent of the standard axioms: it is genuinely undecidable within them. This raises a deep philosophical question — is CH "really" true or false, or is mathematical truth itself relative to a chosen axiom system? Mathematicians still debate whether new, well-motivated axioms (e.g., large-cardinal axioms) should be adopted to settle it.

See Also

Cardinality and Infinity · Functions and Relations · Mathematical Logic · Axiomatic Set Theory (ZFC) · Boolean Algebra · Probability Theory · Russell's Paradox

Before this

  • Mathematical Logic — supplies the quantifiers and connectives ($\forall, \exists, \wedge, \vee, \implies$) used to define sets.
  • Natural Numbers — needed to discuss finite cardinalities $|A| = n$.
  • Basic Proof Techniques — direct proof and proof by contradiction are used throughout (see Cantor's theorem).
  • Functions and Mappings — surjections and injections underlie comparisons of set size.

Where this leads