Definition of a Relation
What You'll Learn
You'll learn how to define relations mathematically as subsets of Cartesian products, and how ordered pairs capture relationships between elements of sets.
The Core Idea
A relation from set A to set B is simply any subset of the Cartesian product A × B. That's it—mathematically, a relation is just a collection of ordered pairs.
Think of it this way: whenever you want to express that some element a from set A is related to some element b from set B, you include the ordered pair (a, b) in your relation. The relation itself is the set of all such pairs that share this relationship.
Notation and Definition
If R is a relation from A to B, then:
- R ⊆ A × B (R is a subset of the Cartesian product)
- We write
(a, b) ∈ Ror sometimesa R bto mean "a is related to b"
Concrete Example
Let A = {1, 2, 3} and B = {x, y}.
The Cartesian product A × B = {(1,x), (1,y), (2,x), (2,y), (3,x), (3,y)}.
Here are three different relations from A to B:
- R₁ = {(1,x), (2,y)} — only these two pairs are related
- R₂ = {(1,x), (1,y), (2,x), (2,y), (3,x), (3,y)} — the entire Cartesian product
- R₃ = ∅ — the empty relation (nothing is related)
Each relation tells a different "story" about how elements of A connect to elements of B.
Why Ordered Pairs?
Ordered pairs preserve direction: (1,x) says "1 relates to x," which may differ from "x relates to 1." This directional quality is essential for representing asymmetric relationships.
Key Takeaway: A relation is formally defined as any subset of a Cartesian product; each ordered pair in the relation represents a specific connection between elements of the two sets.