Be able to apply the definitions of the following properties of
relations:
Reflexive
Symmetric
Transitive
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.
Announcements
Please fill out Week 4 survey by tonight!
Midterm Exam is one week from today!
Covers material through Wednesday (through BoP
Chapter 12; up to and including functions).
You can bring one double-sided 8.5x11” sheet of hand-written
notes.
Resources:
I have made a study
guide of sorts, which lists of the Goals for each lecture; my goal
is for the exam to be a fair assessment of the extent to which you’ve
achieved these outcomes.
I have provided some Racket
practice problems. You can expect the Racket questions on the exam
to resemble these.
There are two (self-)quizzes:
Quiz 1 covering lectures 2–4
Quiz 2 covering lectures 5–6
It’s harder to write a quiz on proofs! Make sure you know the
different proof approaches, especially how to set up a proof by \(x\) for various \(x\).
Study guide and racket practcie are also linked from the Midterm day
on the Schedule; Quizzes are linked in the Readings column.
Tentative notes/exercises for the rest of this week are posted.
Today: relations 1
Tomorrow: relations 2, functions 1
Wednesday: functions 2
Friday: review!
Relations
Example:
Let \(A = \{1, 2, 3\}\). The
relation \(R\) meaning “greater than
equal to” is a subset of \(A \times
A\): \[
R = \{(1, 1), (2, 1), (2, 2), (3, 3), (3, 2), (3, 1)\} \subseteq A
\times A
\] We can also draw a diagram representing this relation:
where each element of \(A\) is a
dot, and each ordered pair in the relation is drawn as an arrow from its
first element to its second element.
Do Exercises Part A
Properties of Relations
Consider \(R\) from above. Is
it:
Reflexive? Yes! \(a \ge a\) for all
\(a \in \{1, 2, 3\}\).
Symmetric? No! \(1 \ge 3\) but
\(3 \not\ge 1\).
Transitive? Yes! This is trickier to check:
\(3 \ge 2\) and \(2 \ge 1\), but \(3 \ge 1\)
\(3 \ge 3\) and \(3 \ge 2\), but \(3 \ge 2\)
…and so on
Do Exercises Part B
equivdef
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}\).