Be able to recognize when a relation is an equivalence
relation
Know how to identify the equivalence classes in a
set given an equivalence relation on that set.
Know the definition of a function.
Be able to define and apply the definitions of the following
properties of functions, and prove or disprove these properties of
functions:
injective
surjective
bijective
Announcements
This week’s Wednesday office hours (tomorrow) are 1:30-2 (instead of
the usual 1-2). Extra office hours 3:30-4 tomorrow (Wednesday).
A4 due tomorrow night
Please fill out Week 4 Survey by tomorrow night
Bring review questions to class tomorrow - I’ll try to
leave time for review.
Equivalence
Relations and Equivalence Classes
Example:
Show that \(\equiv \pmod{3}\) (that
is, congruence mod 3 is an equivalence relation.
Recall: \(a \equiv b \pmod{n}\)
means \(n \mid (a-b)\).
Reflexive: is \(a \equiv a
\pmod{n}\)?
Yes:\(n \mid
(a-a)\), or \(n \mid 0\) because
\(0 = kn\) where the integer \(k = 0\).
Symmetric: \(a \equiv b \pmod{n}
\Rightarrow b \equiv a \pmod{n}\)?
Yes: By definition of modular congruence, \(n \mid (a-b)\) means \((a-b) = kn\) for some integer \(k\). Negating both sides we get \((b-a) = -kn\). Therefore \(n \mid (b-a)\), so \(b \equiv a \pmod{n}\).
Transitive: \(\left(a \equiv b \pmod{n}
\land b \equiv c \pmod{n}\right) \Rightarrow b \equiv a
\pmod{n}\)
Yes: Suppose \(a \equiv b
\pmod{n}\) and \(b \equiv c
\pmod{n}\). Then \(n \mid
(a-b)\), so \((a-b) = pn\) for
some integer \(p\), and \((n \mid b-c)\), so \((b-c) = qn\) for some integer \(q\). Add these two equations together:
\[
\begin{align*}
a - b &= pn\\
b - c &= qn
\end{align*}
\] to yield $$ \[\begin{align*}
(a - c) &= pn + qn\\
(a - c) &= n(p+q)
\end{align*}\] $$ which satisfies the definition of \(n \mid (a - c)\), and therefore \(a \equiv c \pmod{n}\).
Equivalence Classes
Example: Consider the relation on \(A = \{-1, 1, 2, 3, 4\}\) that means “has
the same sign as”:
Do Exercises Part A
Relations Between Sets
You can have a relation between two sets. In this case, \(R \subseteq A \times B\). Otherwise,
everything’s more or less the same.
In this case, if we draw a diagram it will have two groups
of points, one for \(A\) and one for
\(B\), and arrows can only go from a
member of the \(A\) group to a member
of the \(B\) group.
Functions
We’re used to seeing functions like: \(f(x) = x^2\). Here we’ll define them more
rigorously and ground them in our existing understanding of sets as the
foundation of mathematics.
Definition: Suppose \(A\) and \(B\) are sets. A function
from \(A\) to \(B\), written \(f:
A \rightarrow B\), is a relation \(f
\subseteq A \times B\) that has the property that for each \(a \in A\), the relation \(f\) contains exactly one
ordered pair of the form \((a, b)\). We
abbreviate the statement \((a, b) \in
f\) as \(f(a) = b\).
Intuition: A function is a special kind of relation
that relates all elements of \(A\) to an element of \(B\).
Example: Let \(f:
\mathbb{Z} \rightarrow \mathbb{N} = \{(n, |n| + 2) : n \in
\mathbb{Z}\}\)
Definition: If \(f : A
\rightarrow B\), then
\(A\) is the
domain (the set of possible inputs for \(f\))
\(B\) is the
codomain (the set of things \(f\) might map elements of \(A\) to)
\(\{f(a): a \in A\}\) is the
range (i.e., the set of things \(f\) actually does map elements of
\(A\) to)
Example: For \(f:
\mathbb{Z} \rightarrow \mathbb{N} = \{(n, |n| + 2) : n \in
\mathbb{Z}\}\) from above:
The domain is $.
The codomain is $
The range is \(\{n \in
\mathbb{N} : n \ge 2\}\)
Do Exercises Part B
Properties of Functions
Definition: A function \(f: A \rightarrow B\) is:
injective, or one-to-one, if for
all \(a, a' \in A\), \(a \ne a'\) implies \(f(a) \ne f(a')\).
intuition: no two elements of \(a\) map to the same element of \(b\).
surjective, or onto, if for all
\(b \in B\) there is an \(a \in A\) with \(f(a) = b\)
intuition: every element of \(b\) is mapped to by some element of \(a\)
bijective if \(f\)
is both injective and surjective
Example:\(f: \mathbb{Z}
\rightarrow \mathbb{N} = \{(n, |n| + 2) : n \in \mathbb{Z}\}\)
is:
not injective because \(f(-2) = f(2) = 4\).
not surjective because there is no \(a\) such that \(f(a) = 1\).
not bijective
Example: If \(f :
\mathbb{Z} \rightarrow \mathbb{N}\) is defined as \(f(n) = |n|+ 1\), then \(f\) is:
not injective, for the same reason as the above
example
surjective because for all \(n \in \mathbb{N}\), it is the case that
\(f(n-1) = n\)
not bijective
Here are two ways to prove that a function is
injective:
And here is an approach for proving that a function is
surjective: