A topic in the Open Knowledge Graph — a free, open map of 15,290 topics and the order to learn them in.

Relations as Subsets of Cartesian Products

College Depth 60 in the knowledge graph ☐ I know this ☆ Set as goal
1,861topics build on this
282prerequisites beneath it
See this on the map →
Cartesian Product and Ordered Pairs→→Categories and MorphismsFirst-Order Logic Syntax+2 more
relations binary-relations formal-definition

Core Idea

A relation R from A to B is any subset of the Cartesian product A × B. This formalization treats all relational structures—ordering relations, equivalence relations, correspondence—as mathematical objects. Key properties include reflexivity, symmetry, transitivity, and totality, which characterize important relation types.

Explainer

You already know that the Cartesian product A × B is the set of all ordered pairs (a, b) where a ∈ A and b ∈ B. A relation is simply a selection from that pool — a subset R ⊆ A × B that picks exactly the pairs you want to declare "related." Writing (a, b) ∈ R is equivalent to saying "a is related to b under R," often written aRb. The key insight is that this definition requires nothing more than set membership: a relation is not a rule or a formula, just a collection of ordered pairs.

Consider the "less than" relation on the integers. Instead of defining it as a rule, we can think of it as the infinite set {(1,2), (1,3), (2,3), (1,4), (2,4), ...} — every pair (m, n) where m is less than n. Similarly, a family tree "is a parent of" relation is the set of ordered pairs (person, child) for every parent-child connection in the family. By reducing relations to sets of pairs, we can reason about them using the tools of set theory: union, intersection, complement, and composition.

Properties of relations are properties of these subsets relative to the underlying sets. Reflexivity means (a, a) ∈ R for every a in the domain — the relation includes all "self-pairs." Symmetry means if (a, b) ∈ R then (b, a) ∈ R — the relation looks the same in both directions. Transitivity means if (a, b) ∈ R and (b, c) ∈ R then (a, c) ∈ R — the relation chains through intermediate elements. An equivalence relation satisfies all three; it carves the set into disjoint classes of mutually related elements (called equivalence classes). A partial order is reflexive, antisymmetric, and transitive — it captures the structure of "no larger than" without requiring every pair to be comparable.

The payoff of this formalism is uniformity: functions, orderings, equivalences, and graphs are all special cases of the same structure. A function from A to B is a relation where every element of A appears as a left coordinate exactly once — adding a uniqueness constraint to the general relation definition. This builds directly toward the formal treatment of functions you will encounter next. Seeing functions as a subtype of relations, rather than a separate concept, lets you apply everything you know about sets to understand when functions exist, when they can be inverted, and how composition of relations generalizes function composition.

Mastering this definition means training yourself to think set-theoretically about structure. Whenever you encounter a relationship between objects — "divides," "is a subset of," "has the same remainder as" — the formal move is to ask: what are the two sets involved, what is A × B, and which ordered pairs belong to the relation? That translation from intuitive relationship to explicit subset is the foundation of all subsequent work in logic, algebra, and theoretical computer science.

Practice Questions 5 questions

Prerequisite Chain

Understanding Zero → The Number Zero → Counting to Five → Counting to 10 → Counting to 20 → Counting a Set of Objects Up to 20 → Cardinality: The Last Number Counted → Matching Numerals to Quantities → Subitizing Small Quantities → Addition Within 10 → Making 10 as an Addition Strategy → Addition Within 20 → Doubles and Near Doubles → Doubles Facts Within 10 → Near Doubles Facts Within 20 → Mental Math Strategies for Addition → Mental Math: Adding and Subtracting Tens → Addition Within 100 → Repeated Addition as Multiplication → Multiplication as Equal Groups → Multiplication: Arrays → Basic Multiplication Facts Through 10 → Multiplication Facts Within 100 → Division as Equal Sharing → Division as Grouping (Measurement Division) → Division: Grouping (Repeated Subtraction) Model → Division: Fair Sharing Model → Division as Equal Sharing → Division as Grouping → Basic Division Facts → Division Facts Within 100 → Multiplication and Division Fact Families → Relationship Between Multiplication and Division → Division Facts as Inverse of Multiplication → Remainders and Quotients in Division → Division Word Problems → Multi-Step Word Problems → Solving Multi-Step Word Problems → Multiplication Word Problems → Division Word Problems → Introduction to Long Division → Factors and Multiples → Prime and Composite Numbers → Equivalent Fractions → Relating Fractions and Decimals → Decimal Place Value → Integers and the Number Line → Opposites and Additive Inverses → Absolute Value → Adding Integers → Subtracting Integers → Multiplying Integers → Introduction to Exponents → Order of Operations → Integer Order of Operations → Variable Expressions → Variables in Logic → Set Notation Basics → Set Membership and Notation → Cartesian Product and Ordered Pairs → Relations as Subsets of Cartesian Products

Longest path: 61 steps · 282 total prerequisite topics

Prerequisites (1)

Leads To (4)