Unit 3 - Relations and Functions Flashcards
The cartesian product of A and B is denoted with and is the set defined as
A × B
{ (x, y) | x ∈ A ∧ y ∈ B}
the cartesian product of A and B is the set containing all
ordered pairs where an element of A comes first, and an element of B comes second.
Consider the sets:
- Foods = {Fries, Broccoli}
- Nutrients = {Carbs, Vitamins, Fats}
What are the following cartesian products:
Foods×Nutrients = {
(Fries,Carbs), (Fries, Vitamins), (Fries, Fats),
(Broccoli,Carbs), (Broccoli, Vitamins), (Broccoli, Fats)}
Nutrients×Foods = {
(Carbs, Fries), (Fats, Fries), (Vitamins, Fries),
(Carbs, Broccoli), (Vitamins, Broccoli), (Fats, Broccoli) }
Foods^2 = {(Fries, Fries), (Fries, Broccoli), (Broccoli, Fries), (Broccoli, Broccoli)}
Let A = {1, 2, 3}. We have:
A x A
A x ∅
- A × A = { (1, 1), (1, 2), (1, 3), (2, 1), (2, 2), (2, 3), (3, 1), (3, 2), (3, 3) }
- A × ∅ = ∅, and also ∅ × A = ∅
A relation among A and B is left-total if it
relates each element of A with at least one element of B;
A relation among A and B is right-total
relates each element of B with at least one element of A;
A relation among A and B is right unique if it
relates each element of A with at most one element of B;
A relation among A and B is left-unique if it
relates each element of B with at most one element of A.
Let A be a set, and let R be a relation in A^2.
We say that R is reflexive if and only if:
R relates each element of A to itself
(∀x ∈ A) x R x
Let A be a set, and let R be a relation in A2.
We say that R is symmetric if and only if:
R relates x to y if and only if it also relates y to x
(∀x ∈ A) (∀y ∈ A)(x R y ⇐⇒ y R x)
Let A be a set, and let R be a relation in A2.
We say that R is transitive if and only if:
if R relates x to y, and y to z, then it also relates x to z
(∀x ∈ A) (∀y ∈ A) (∀z ∈ A)((x R y ∧ y R z) ⇒ x R z)