§ — — Discrete Structures 1
A relation describes how elements from one set correspond to elements of another (or the same) set. A binary relation is a set of ordered pairs (a, b).
Notation: a R b means (a, b) ∈ R. The domain of a relation is the set of all first elements; the range is the set of all second elements.
Every element is related to itself: ∀a, (a, a) ∈ R.
Common reflexive relations: =, ≥, ≤; Non-reflexive: >, <
Irreflexive: No element is related to itself: ∀a, (a, a) ∉ R.
In a digraph, reflexive relations have a self-loop at every vertex.
If (a, b) ∈ R then (b, a) ∈ R for all a, b.
Asymmetric: If (a, b) ∈ R then (b, a) ∉ R.
If both (a, b) ∈ R and (b, a) ∈ R, then a = b.
If (a, b) ∈ R and (b, c) ∈ R, then (a, c) ∈ R.
A relation R on set A is a partial order if it is reflexive, antisymmetric, and transitive. A set with a partial order is called a poset.
A partial order where every pair of elements is comparable.
A function f from set A to set B maps every element of A to exactly one element of B.
Example 1: Given f(x) = 3x − 5, find f(2).
Example 2: Find g(4w) when g(x) = x² − 2x + 1.
Given functions f and g:
The composition (f ∘ g)(x) = f(g(x)) — apply g first, then feed the result into f.
In general, f ∘ g ≠ g ∘ f.
Example: Let g(x) = 2x and f(x) = x + 1.
Statement: If n + 1 or more objects are distributed into n containers, then at least one container holds two or more objects.
Example 1: In a room with more than 366 people, at least two share the same birthday.
Example 2: If a class has 14 boys and 22 girls (36 total), at minimum 15 members guarantees at least one female.
ProReviewer — locked
Drills, code labs, and full solutions.
Done with this module? Track it — your progress shows on the subject list.
Up next
Lesson 6: Basic Counting Principles→←Previous: Lesson 4: Set Concepts