diff --git a/Bookshelf/Apostol.tex b/Bookshelf/Apostol.tex index de22435..61c245e 100644 --- a/Bookshelf/Apostol.tex +++ b/Bookshelf/Apostol.tex @@ -25,203 +25,181 @@ \section{\defined{Characteristic Function}}% \hyperlabel{ref:characteristic-function} -Let $S$ be a set of points on the real line. -The \textbf{characteristic function} of $S$ is the function $\mathcal{X}_S$ such - that $\mathcal{X}_S(x) = 1$ for every $x$ in $S$, and $\mathcal{X}_S(x) = 0$ - for those $x$ not in $S$. - -\begin{definition} + Let $S$ be a set of points on the real line. + The \textbf{characteristic function} of $S$ is the function $\mathcal{X}_S$ + such that $\mathcal{X}_S(x) = 1$ for every $x$ in $S$, and + $\mathcal{X}_S(x) = 0$ for those $x$ not in $S$. \code*{Common/Set/Basic}{Set.characteristic} -\end{definition} - \section{\defined{Completeness Axiom}}% \hyperlabel{ref:completeness-axiom} -Every nonempty set $S$ of real numbers which is bounded above has a supremum; - that is, there is a real number $B$ such that $B = \sup{S}$. - -\begin{axiom} + Every nonempty set $S$ of real numbers which is bounded above has a supremum; + that is, there is a real number $B$ such that $B = \sup{S}$. \lean*{Mathlib/Data/Real/Basic}{Real.exists\_isLUB} -\end{axiom} - \section{\defined{Infimum}}% \hyperlabel{ref:infimum} -A number $B$ is called an \textbf{infimum} of a nonempty set $S$ if $B$ has - the following two properties: - \begin{enumerate}[(a)] - \item $B$ is a lower bound for $S$. - \item No number greater than $B$ is a lower bound for $S$. - \end{enumerate} -Such a number $B$ is also known as the \textbf{greatest lower bound}. - -\begin{definition} + A number $B$ is called an \textbf{infimum} of a nonempty set $S$ if $B$ has + the following two properties: + \begin{enumerate}[(a)] + \item $B$ is a lower bound for $S$. + \item No number greater than $B$ is a lower bound for $S$. + \end{enumerate} + Such a number $B$ is also known as the \textbf{greatest lower bound}. \lean*{Mathlib/Order/Bounds/Basic}{IsGLB} -\end{definition} - \section{\defined{Integrable}}% \hyperlabel{ref:integrable} -Let $f$ be a function defined and bounded on $[a, b]$. -$f$ is said to be \textbf{integrable} if there exists one and only one number - $I$ such that \eqref{ref:integral-bounded-function-eq2} holds. -If $f$ is integrable on $[a, b]$, we say that the integral - $\int_a^b f(x) \mathop{dx}$ \textbf{exists}. + Let $f$ be a function defined and bounded on $[a, b]$. + $f$ is said to be \textbf{integrable} if there exists one and only one number + $I$ such that \eqref{ref:integral-bounded-function-eq2} holds. + If $f$ is integrable on $[a, b]$, we say that the integral + $\int_a^b f(x) \mathop{dx}$ \textbf{exists}. \section{\defined{Integral of a Bounded Function}}% \hyperlabel{ref:integral-bounded-function} -Let $f$ be a function defined and bounded on $[a, b]$. -Let $s$ and $t$ denote arbitrary step functions defined on $[a, b]$ such that - \begin{equation} - \hyperlabel{ref:integral-bounded-function-eq1} - s(x) \leq f(x) \leq t(x) - \end{equation} - for every $x$ in $[a, b]$. -If there is one and only one number $I$ such that - \begin{equation} - \hyperlabel{ref:integral-bounded-function-eq2} - \int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx} - \end{equation} - for every pair of step functions $s$ and $t$ satisfying - \eqref{ref:integral-bounded-function-eq1}, then this number $I$ is called - the \textbf{integral of $f$ from $a$ to $b$}, and is denoted by the symbol - $\int_a^b f(x) \mathop{dx}$ or by $\int_a^b f$. + Let $f$ be a function defined and bounded on $[a, b]$. + Let $s$ and $t$ denote arbitrary step functions defined on $[a, b]$ such that + \begin{equation} + \hyperlabel{ref:integral-bounded-function-eq1} + s(x) \leq f(x) \leq t(x) + \end{equation} + for every $x$ in $[a, b]$. + If there is one and only one number $I$ such that + \begin{equation} + \hyperlabel{ref:integral-bounded-function-eq2} + \int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx} + \end{equation} + for every pair of step functions $s$ and $t$ satisfying + \eqref{ref:integral-bounded-function-eq1}, then this number $I$ is called + the \textbf{integral of $f$ from $a$ to $b$}, and is denoted by the symbol + $\int_a^b f(x) \mathop{dx}$ or by $\int_a^b f$. -If $a < b$, we define $\int_b^a f(x) \mathop{dx} = -\int_a^b f(x) \mathop{dx}$, - provided $f$ is \nameref{ref:integrable} on $[a, b]$. -We also define $\int_a^a f(x) \mathop{dx} = 0$. + If $a < b$, we define + $\int_b^a f(x) \mathop{dx} = -\int_a^b f(x) \mathop{dx}$, + provided $f$ is \nameref{ref:integrable} on $[a, b]$. + We also define $\int_a^a f(x) \mathop{dx} = 0$. -The function $f$ is called the \textbf{integrand}, the numbers $a$ and $b$ are - called the \textbf{limits of integration}, and the interval $[a, b]$ the - \textbf{interval of integration}. + The function $f$ is called the \textbf{integrand}, the numbers $a$ and $b$ are + called the \textbf{limits of integration}, and the interval $[a, b]$ the + \textbf{interval of integration}. \section{\defined{Integral of a Step Function}}% \hyperlabel{ref:integral-step-function} -Let $s$ be a \nameref{ref:step-function} defined on $[a, b]$, and let - $P = \{x_0, x_1, \ldots, x_n\}$ be a \nameref{ref:partition} of $[a, b]$ - such that $s$ is constant on the open subintervals of $P$. -Denote by $s_k$ the constant value that $s$ takes in the $k$th open subinterval - of $P$, so that - $$s(x) = s_k \quad\text{if}\quad x_{k-1} < x < x_k, \quad k - = 1, 2, \ldots, n.$$ -The \textbf{integral of $s$ from $a$ to $b$}, denoted by the symbol - $\int_a^b s(x)\mathop{dx}$, is defined by the following formula: - $$\int_a^b s(x) \mathop{dx} = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}).$$ -If $a < b$, we define $\int_b^a s(x) \mathop{dx} = -\int_a^b s(x) \mathop{dx}$. -We also define $\int_a^a s(x) \mathop{dx} = 0$. + Let $s$ be a \nameref{ref:step-function} defined on $[a, b]$, and let + $P = \{x_0, x_1, \ldots, x_n\}$ be a \nameref{ref:partition} of $[a, b]$ + such that $s$ is constant on the open subintervals of $P$. + Denote by $s_k$ the constant value that $s$ takes in the $k$th open + subinterval of $P$, so that + $$s(x) = s_k \quad\text{if}\quad x_{k-1} < x < x_k, \quad k + = 1, 2, \ldots, n.$$ + The \textbf{integral of $s$ from $a$ to $b$}, denoted by the symbol + $\int_a^b s(x)\mathop{dx}$, is defined by the following formula: + $$\int_a^b s(x) \mathop{dx} = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}).$$ + If $a < b$, we define + $\int_b^a s(x) \mathop{dx} = -\int_a^b s(x) \mathop{dx}$. + We also define $\int_a^a s(x) \mathop{dx} = 0$. \section{\defined{Lower Integral}}% \hyperlabel{ref:lower-integral} -Let $f$ be a function bounded on $[a, b]$ and $S$ denote the set of numbers - $\int_a^b s(x) \mathop{dx}$ obtained as $s$ runs through all - \nameref{ref:step-function}s below $f$. -That is, let $$S = \left\{ \int_a^b s(x) \mathop{dx} : s \leq f \right\}.$$ -The number $\sup{S}$ is called the \textbf{lower integral of $f$}. -It is denoted as $\ubar{I}(f)$. + Let $f$ be a function bounded on $[a, b]$ and $S$ denote the set of numbers + $\int_a^b s(x) \mathop{dx}$ obtained as $s$ runs through all + \nameref{ref:step-function}s below $f$. + That is, let $$S = \left\{ \int_a^b s(x) \mathop{dx} : s \leq f \right\}.$$ + The number $\sup{S}$ is called the \textbf{lower integral of $f$}. + It is denoted as $\ubar{I}(f)$. \section{\defined{Monotonic}}% \hyperlabel{ref:monotonic} -A function $f$ is called \textbf{monotonic} on set $S$ if it is increasing on - $S$ or if it is decreasing on $S$. -$f$ is said to be \textbf{strictly monotonic} if it is strictly increasing on - $S$ or strictly decreasing on $S$. + A function $f$ is called \textbf{monotonic} on set $S$ if it is increasing on + $S$ or if it is decreasing on $S$. + $f$ is said to be \textbf{strictly monotonic} if it is strictly increasing on + $S$ or strictly decreasing on $S$. -A function $f$ is said to be \textbf{piecewise monotonic} on an interval if its - graph consists of a finite number of monotonic pieces. -In other words, $f$ is piecewise monotonic on $[a, b]$ if there is a - \nameref{ref:partition} of $[a, b]$ such that $f$ is monotonic on each of - the open subintervals of $P$. + A function $f$ is said to be \textbf{piecewise monotonic} on an interval if + its graph consists of a finite number of monotonic pieces. + In other words, $f$ is piecewise monotonic on $[a, b]$ if there is a + \nameref{ref:partition} of $[a, b]$ such that $f$ is monotonic on each of + the open subintervals of $P$. \section{\defined{Partition}}% \hyperlabel{ref:partition} -Let $[a, b]$ be a closed interval decomposed into $n$ subintervals by inserting - $n - 1$ points of subdivision, say $x_1$, $x_2$, $\ldots$, $x_{n-1}$, subject - only to the restriction - \begin{equation} - \hyperlabel{sec:partition-eq1} - a < x_1 < x_2 < \cdots < x_{n-1} < b. - \end{equation} -It is convenient to denote the point $a$ itself by $x_0$ and the point $b$ by - $x_n$. -A collection of points satisfying \eqref{sec:partition-eq1} is called a - \textbf{partition} $P$ of $[a, b]$, and we use the symbol - $$P = \{x_0, x_1, \ldots, x_n\}$$ to designate this partition. - -\begin{definition} + Let $[a, b]$ be a closed interval decomposed into $n$ subintervals by + inserting $n - 1$ points of subdivision, say $x_1$, $x_2$, $\ldots$, + $x_{n-1}$, subject only to the restriction + \begin{equation} + \hyperlabel{sec:partition-eq1} + a < x_1 < x_2 < \cdots < x_{n-1} < b. + \end{equation} + It is convenient to denote the point $a$ itself by $x_0$ and the point $b$ by + $x_n$. + A collection of points satisfying \eqref{sec:partition-eq1} is called a + \textbf{partition} $P$ of $[a, b]$, and we use the symbol + $$P = \{x_0, x_1, \ldots, x_n\}$$ to designate this partition. \code*{Common/Set/Partition}{Set.Partition} -\end{definition} - \section{\defined{Refinement}}% \hyperlabel{ref:refinement} -Let $P$ be a \nameref{ref:partition} of closed interval $[a, b]$. -A \textbf{refinement} $P'$ of $P$ is a partition formed by adjoining more - subdivision points to those already in $P$. + Let $P$ be a \nameref{ref:partition} of closed interval $[a, b]$. + A \textbf{refinement} $P'$ of $P$ is a partition formed by adjoining more + subdivision points to those already in $P$. -$P'$ is said to be \textbf{finer than} $P$. The union of two partitions $P_1$ - and $P_2$ is called the \textbf{common refinement} of $P_1$ and $P_2$. + $P'$ is said to be \textbf{finer than} $P$. The union of two partitions $P_1$ + and $P_2$ is called the \textbf{common refinement} of $P_1$ and $P_2$. \section{\defined{Step Function}}% \hyperlabel{ref:step-function} -A function $s$, whose domain is a closed interval $[a, b]$, is called a - \textbf{step function} if there is a \nameref{ref:partition} - $P = \{x_0, x_1, \ldots, x_n\}$ of $[a, b]$ such that $s$ is constant on each - open subinterval of $P$. -That is to say, for each $k = 1, 2, \ldots, n$, there is a real number $s_k$ - such that $$s(x) = s_k \quad\text{if}\quad x_{k-1} < x < x_k.$$ - Step functions are sometimes called \textbf{piecewise constant functions}. + A function $s$, whose domain is a closed interval $[a, b]$, is called a + \textbf{step function} if there is a \nameref{ref:partition} + $P = \{x_0, x_1, \ldots, x_n\}$ of $[a, b]$ such that $s$ is constant on each + open subinterval of $P$. + That is to say, for each $k = 1, 2, \ldots, n$, there is a real number $s_k$ + such that $$s(x) = s_k \quad\text{if}\quad x_{k-1} < x < x_k.$$ + Step functions are sometimes called \textbf{piecewise constant functions}. -\begin{note} - At each of the endpoints $x_{k-1}$ and $x_k$ the function must have some - well-defined value, but this need not be the same as $s_k$. -\end{note} + \begin{note} + At each of the endpoints $x_{k-1}$ and $x_k$ the function must have some + well-defined value, but this need not be the same as $s_k$. + \end{note} -\begin{definition} - - \code*{Common/Geometry/StepFunction}{Geometry.StepFunction} - -\end{definition} + \code{Common/Geometry/StepFunction}{Geometry.StepFunction} \section{\defined{Supremum}}% \hyperlabel{ref:supremum} -A number $B$ is called a \textbf{supremum} of a nonempty set $S$ if $B$ has - the following two properties: - \begin{enumerate}[(a)] - \item $B$ is an upper bound for $S$. - \item No number less than $B$ is an upper bound for $S$. - \end{enumerate} -Such a number $B$ is also known as the \textbf{least upper bound}. - -\begin{definition} + A number $B$ is called a \textbf{supremum} of a nonempty set $S$ if $B$ has + the following two properties: + \begin{enumerate}[(a)] + \item $B$ is an upper bound for $S$. + \item No number less than $B$ is an upper bound for $S$. + \end{enumerate} + Such a number $B$ is also known as the \textbf{least upper bound}. \lean*{Mathlib/Order/Bounds/Basic}{IsLUB} -\end{definition} - \section{\defined{Upper Integral}}% \hyperlabel{ref:upper-integral} -Let $f$ be a function bounded on $[a, b]$ and $T$ denote the set of numbers - $\int_a^b t(x) \mathop{dx}$ obtained as $t$ runs through all - \nameref{ref:step-function}s above $f$. -That is, let $$T = \left\{ \int_a^b t(x) \mathop{dx} : f \leq t \right\}.$$ -The number $\inf{T}$ is called the \textbf{upper integral of $f$}. -It is denoted as $\bar{I}(f)$. + Let $f$ be a function bounded on $[a, b]$ and $T$ denote the set of numbers + $\int_a^b t(x) \mathop{dx}$ obtained as $t$ runs through all + \nameref{ref:step-function}s above $f$. + That is, let $$T = \left\{ \int_a^b t(x) \mathop{dx} : f \leq t \right\}.$$ + The number $\inf{T}$ is called the \textbf{upper integral of $f$}. + It is denoted as $\bar{I}(f)$. \endgroup @@ -231,435 +209,401 @@ It is denoted as $\bar{I}(f)$. \section{\verified{Lemma 1}}% \hyperlabel{sec:lemma-1} -\begin{lemma}[1] - - Nonempty set $S$ has supremum $L$ if and only if set $-S$ has infimum $-L$. - -\end{lemma} - -\begin{proof} + \begin{lemma}[1] + Nonempty set $S$ has supremum $L$ if and only if set $-S$ has infimum $-L$. + \end{lemma} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.is\_lub\_neg\_set\_iff\_is\_glb\_set\_neg} - Suppose $L = \sup{S}$ and fix $x \in S$. - By definition of the \nameref{ref:supremum}, $x \leq L$ and $L$ is the - smallest value satisfying this inequality. - Negating both sides of the inequality yields $-x \geq -L$. - Furthermore, $-L$ must be the largest value satisfying this inequality. - Therefore $-L = \inf{-S}$. - -\end{proof} + \begin{proof} + Suppose $L = \sup{S}$ and fix $x \in S$. + By definition of the \nameref{ref:supremum}, $x \leq L$ and $L$ is the + smallest value satisfying this inequality. + Negating both sides of the inequality yields $-x \geq -L$. + Furthermore, $-L$ must be the largest value satisfying this inequality. + Therefore $-L = \inf{-S}$. + \end{proof} \section{\verified{Existence of a Greatest Lower Bound}} \hyperlabel{sec:existence-greatest-lower-bound} \hyperlabel{sec:theorem-i.27} -\begin{theorem}[I.27] - - Every nonempty set $S$ that is bounded below has a greatest lower bound; that - is, there is a real number $L$ such that $L = \inf{S}$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.27] + Every nonempty set $S$ that is bounded below has a greatest lower bound; + that is, there is a real number $L$ such that $L = \inf{S}$. + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.exists\_isGLB} - Let $S$ be a nonempty set bounded below by $x$. - Then $-S$ is nonempty and bounded above by $x$. - By the \nameref{ref:completeness-axiom}, there exists a - \nameref{ref:supremum} $L$ of $-S$. - By \nameref{sec:lemma-1}, $L$ is a supremum of $-S$ if and only if $-L$ is an - infimum of $S$. - -\end{proof} + \begin{proof} + Let $S$ be a nonempty set bounded below by $x$. + Then $-S$ is nonempty and bounded above by $x$. + By the \nameref{ref:completeness-axiom}, there exists a + \nameref{ref:supremum} $L$ of $-S$. + By \nameref{sec:lemma-1}, $L$ is a supremum of $-S$ if and only if $-L$ is + an infimum of $S$. + \end{proof} \section{\verified{Positive Integers Unbounded Above}}% \hyperlabel{sec:positive-integers-unbounded-above} \hyperlabel{sec:theorem-i.29} -\begin{theorem}[I.29] - - For every real $x$ there exists a positive integer $n$ such that $n > x$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.29] + For every real $x$ there exists a positive integer $n$ such that $n > x$. + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.exists\_pnat\_geq\_self} - Let $n = \abs{\ceil{x}} + 1$. - It is trivial to see $n$ is a positive integer satisfying $n \geq 1$. - Thus all that remains to be shown is that $n > x$. - If $x$ is nonpositive, $n > x$ immediately follows from $n \geq 1$. - If $x$ is positive, - $$x = \abs{x} \leq \abs{\ceil{x}} < \abs{\ceil{x}} + 1 = n.$$ - -\end{proof} + \begin{proof} + Let $n = \abs{\ceil{x}} + 1$. + It is trivial to see $n$ is a positive integer satisfying $n \geq 1$. + Thus all that remains to be shown is that $n > x$. + If $x$ is nonpositive, $n > x$ immediately follows from $n \geq 1$. + If $x$ is positive, + $$x = \abs{x} \leq \abs{\ceil{x}} < \abs{\ceil{x}} + 1 = n.$$ + \end{proof} \section{\verified{Archimedean Property of the Reals}}% \hyperlabel{sec:archimedean-property-reals} \hyperlabel{sec:theorem-i.30} -\begin{theorem}[I.30] - - If $x > 0$ and if $y$ is an arbitrary real number, there exists a positive - integer $n$ such that $nx > y$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.30] + If $x > 0$ and if $y$ is an arbitrary real number, there exists a positive + integer $n$ such that $nx > y$. + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.exists\_pnat\_mul\_self\_geq\_of\_pos} - Let $x > 0$ and $y$ be an arbitrary real number. - By \nameref{sec:theorem-i.29}, there exists a positive integer $n$ such that - $n > y / x$. - Multiplying both sides of the inequality yields $nx > y$ as expected. - -\end{proof} + \begin{proof} + Let $x > 0$ and $y$ be an arbitrary real number. + By \nameref{sec:theorem-i.29}, there exists a positive integer $n$ such that + $n > y / x$. + Multiplying both sides of the inequality yields $nx > y$ as expected. + \end{proof} \section{\verified{Theorem I.31}}% \hyperlabel{sec:theorem-i.31} -\begin{theorem}[I.31] - - If three real numbers $a$, $x$, and $y$ satisfy the inequalities - $$a \leq x \leq a + \frac{y}{n}$$ for every integer $n \geq 1$, then - $x = a$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.31] + If three real numbers $a$, $x$, and $y$ satisfy the inequalities + $$a \leq x \leq a + \frac{y}{n}$$ for every integer $n \geq 1$, then + $x = a$. + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.forall\_pnat\_leq\_self\_leq\_frac\_imp\_eq} - By the trichotomy of the reals, there are three cases to consider: + \begin{proof} - \paragraph{Case 1}% + By the trichotomy of the reals, there are three cases to consider: - Suppose $x = a$. - Then we are immediately finished. + \paragraph{Case 1}% - \paragraph{Case 2}% + Suppose $x = a$. + Then we are immediately finished. - Suppose $x < a$. - But by hypothesis, $a \leq x$. - Thus $a < a$, a contradiction. + \paragraph{Case 2}% - \paragraph{Case 3}% + Suppose $x < a$. + But by hypothesis, $a \leq x$. + Thus $a < a$, a contradiction. - Suppose $x > a$. - Then there exists some $c > 0$ such that $a + c = x$. - By \nameref{sec:archimedean-property-reals}, there exists an integer $n > 0$ - such that $nc > y$. - Rearranging terms, we see $y / n < c$. - Therefore $a + y / n < a + c = x$. - But by hypothesis, $x \leq a + y / n$. - Thus $a + y / n < a + y / n$, a contradiction. + \paragraph{Case 3}% - \paragraph{Conclusion}% + Suppose $x > a$. + Then there exists some $c > 0$ such that $a + c = x$. + By \nameref{sec:archimedean-property-reals}, there exists an integer + $n > 0$ such that $nc > y$. + Rearranging terms, we see $y / n < c$. + Therefore $a + y / n < a + c = x$. + But by hypothesis, $x \leq a + y / n$. + Thus $a + y / n < a + y / n$, a contradiction. - Since these cases are exhaustive and both case 2 and 3 lead to - contradictions, $x = a$ is the only possibility. + \paragraph{Conclusion}% -\end{proof} + Since these cases are exhaustive and both case 2 and 3 lead to + contradictions, $x = a$ is the only possibility. + + \end{proof} \section{\verified{Lemma 2}}% \hyperlabel{sec:lemma-2} -\begin{lemma}[2] - - If three real numbers $a$, $x$, and $y$ satisfy the inequalities - $$a - y / n \leq x \leq a$$ for every integer $n \geq 1$, then $x = a$. - -\end{lemma} - -\begin{proof} + \begin{lemma}[2] + If three real numbers $a$, $x$, and $y$ satisfy the inequalities + $$a - y / n \leq x \leq a$$ for every integer $n \geq 1$, then $x = a$. + \end{lemma} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.forall\_pnat\_frac\_leq\_self\_leq\_imp\_eq} - By the trichotomy of the reals, there are three cases to consider: + \begin{proof} - \paragraph{Case 1}% + By the trichotomy of the reals, there are three cases to consider: - Suppose $x = a$. - Then we are immediately finished. + \paragraph{Case 1}% - \paragraph{Case 2}% + Suppose $x = a$. + Then we are immediately finished. - Suppose $x < a$. - Then there exists some $c > 0$ such that $x = a - c$. - By \nameref{sec:archimedean-property-reals}, there exists an integer $n > 0$ - such that $nc > y$. - Rearranging terms, we see that $y / n < c$. - Therefore $a - y / n > a - c = x$. - But by hypothesis, $x \geq a - y / n$. - Thus $a - y / n < a - y / n$, a contradiction. + \paragraph{Case 2}% - \paragraph{Case 3}% + Suppose $x < a$. + Then there exists some $c > 0$ such that $x = a - c$. + By \nameref{sec:archimedean-property-reals}, there exists an integer + $n > 0$ such that $nc > y$. + Rearranging terms, we see that $y / n < c$. + Therefore $a - y / n > a - c = x$. + But by hypothesis, $x \geq a - y / n$. + Thus $a - y / n < a - y / n$, a contradiction. - Suppose $x > a$. - But by hypothesis $x \leq a$. - Thus $a < a$, a contradiction. + \paragraph{Case 3}% - \paragraph{Conclusion}% + Suppose $x > a$. + But by hypothesis $x \leq a$. + Thus $a < a$, a contradiction. - Since these cases are exhaustive and both case 2 and 3 lead to - contradictions, $x = a$ is the only possibility. + \paragraph{Conclusion}% -\end{proof} + Since these cases are exhaustive and both case 2 and 3 lead to + contradictions, $x = a$ is the only possibility. + + \end{proof} \section{\verified{Theorem I.32}}% \hyperlabel{sec:theorem-i.32} -Let $h$ be a given positive number and let $S$ be a set of real numbers. + Let $h$ be a given positive number and let $S$ be a set of real numbers. \subsection{\verified{Theorem I.32a}}% \hyperlabel{sub:theorem-i.32a} -\begin{theorem}[I.32a] - - If $S$ has a supremum, then for some $x$ in $S$ we have $x > \sup{S} - h$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.32a] + If $S$ has a supremum, then for some $x$ in $S$ we have $x > \sup{S} - h$. + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.sup\_imp\_exists\_gt\_sup\_sub\_delta} - By definition of a \nameref{ref:supremum}, $\sup{S}$ is the least upper - bound of $S$. - For the sake of contradiction, suppose for all $x \in S$, - $x \leq \sup{S} - h$. - This immediately implies $\sup{S} - h$ is an upper bound of $S$. - But $\sup{S} - h < \sup{S}$, contradicting $\sup{S}$ being the \textit{least} - upper bound. - Therefore our original hypothesis was wrong. - That is, there exists some $x \in S$ such that $x > \sup{S} - h$. - -\end{proof} + \begin{proof} + By definition of a \nameref{ref:supremum}, $\sup{S}$ is the least upper + bound of $S$. + For the sake of contradiction, suppose for all $x \in S$, + $x \leq \sup{S} - h$. + This immediately implies $\sup{S} - h$ is an upper bound of $S$. + But $\sup{S} - h < \sup{S}$, contradicting $\sup{S}$ being the + \textit{least} upper bound. + Therefore our original hypothesis was wrong. + That is, there exists some $x \in S$ such that $x > \sup{S} - h$. + \end{proof} \subsection{\verified{Theorem I.32b}}% \hyperlabel{sub:theorem-i.32b} -\begin{theorem}[I.32b] - - If $S$ has an infimum, then for some $x$ in $S$ we have $x < \inf{S} + h$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.32b] + If $S$ has an infimum, then for some $x$ in $S$ we have $x < \inf{S} + h$. + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.inf\_imp\_exists\_lt\_inf\_add\_delta} - By definition of an \nameref{ref:infimum}, $\inf{S}$ is the greatest lower - bound of $S$. - For the sake of contradiction, suppose for all $x \in S$, - $x \geq \inf{S} + h$. - This immediately implies $\inf{S} + h$ is a lower bound of $S$. - But $\inf{S} + h > \inf{S}$, contradicting $\inf{S}$ being the - \textit{greatest} lower bound. - Therefore our original hypothesis was wrong. - That is, there exists some $x \in S$ such that $x < \inf{S} + h$. - -\end{proof} + \begin{proof} + By definition of an \nameref{ref:infimum}, $\inf{S}$ is the greatest lower + bound of $S$. + For the sake of contradiction, suppose for all $x \in S$, + $x \geq \inf{S} + h$. + This immediately implies $\inf{S} + h$ is a lower bound of $S$. + But $\inf{S} + h > \inf{S}$, contradicting $\inf{S}$ being the + \textit{greatest} lower bound. + Therefore our original hypothesis was wrong. + That is, there exists some $x \in S$ such that $x < \inf{S} + h$. + \end{proof} \section{\verified{Additive Property of Supremums and Infimums}}% \hyperlabel{sec:additive-property-supremums-infimums} \hyperlabel{sec:theorem-i.33} -Given nonempty subsets $A$ and $B$ of $\mathbb{R}$, let $C$ denote the set - $$C = \{a + b : a \in A, b \in B\}.$$ + Given nonempty subsets $A$ and $B$ of $\mathbb{R}$, let $C$ denote the set + $$C = \{a + b : a \in A, b \in B\}.$$ -\begin{note} - This is known as the "Additive Property." -\end{note} + \begin{note} + This is known as the "Additive Property." + \end{note} \subsection{\verified{Theorem I.33a}}% \hyperlabel{sub:theorem-i.33a} -\begin{theorem}[I.33a] - - If each of $A$ and $B$ has a supremum, then $C$ has a supremum, and - $$\sup{C} = \sup{A} + \sup{B}.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.33a] + If each of $A$ and $B$ has a supremum, then $C$ has a supremum, and + $$\sup{C} = \sup{A} + \sup{B}.$$ + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.sup\_minkowski\_sum\_eq\_sup\_add\_sup} - We prove (i) $\sup{A} + \sup{B}$ is an upper bound of $C$ and (ii) - $\sup{A} + \sup{B}$ is the \textit{least} upper bound of $C$. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-i.33a-i} + We prove (i) $\sup{A} + \sup{B}$ is an upper bound of $C$ and (ii) + $\sup{A} + \sup{B}$ is the \textit{least} upper bound of $C$. - Let $x \in C$. - By definition of $C$, there exist elements $a' \in A$ and $b' \in B$ such - that $x = a' + b'$. - By definition of a \nameref{ref:supremum}, $a' \leq \sup{A}$. - Likewise, $b' \leq \sup{B}$. - Therefore $a' + b' \leq \sup{A} + \sup{B}$. - Since $x = a' + b'$ was arbitrarily chosen, it follows $\sup{A} + \sup{B}$ - is an upper bound of $C$. + \paragraph{(i)}% + \hyperlabel{par:theorem-i.33a-i} - \paragraph{(ii)}% + Let $x \in C$. + By definition of $C$, there exist elements $a' \in A$ and $b' \in B$ such + that $x = a' + b'$. + By definition of a \nameref{ref:supremum}, $a' \leq \sup{A}$. + Likewise, $b' \leq \sup{B}$. + Therefore $a' + b' \leq \sup{A} + \sup{B}$. + Since $x = a' + b'$ was arbitrarily chosen, it follows $\sup{A} + \sup{B}$ + is an upper bound of $C$. - Since $A$ and $B$ have supremums, $C$ is nonempty. - By \nameref{par:theorem-i.33a-i}, $C$ is bounded above. - Therefore the completeness axiom tells us $C$ has a supremum. - Let $n > 0$ be an integer. - We now prove that - \begin{equation} - \hyperlabel{par:theorem-i.33a-ii-eq1} - \sup{C} \leq \sup{A} + \sup{B} \leq \sup{C} + 1 / n. - \end{equation} + \paragraph{(ii)}% - \subparagraph{Left-Hand Side}% + Since $A$ and $B$ have supremums, $C$ is nonempty. + By \nameref{par:theorem-i.33a-i}, $C$ is bounded above. + Therefore the completeness axiom tells us $C$ has a supremum. + Let $n > 0$ be an integer. + We now prove that + \begin{equation} + \hyperlabel{par:theorem-i.33a-ii-eq1} + \sup{C} \leq \sup{A} + \sup{B} \leq \sup{C} + 1 / n. + \end{equation} - First consider the left-hand side of \eqref{par:theorem-i.33a-ii-eq1}. - By \nameref{par:theorem-i.33a-i}, $\sup{A} + \sup{B}$ is an upper bound of - $C$. - Since $\sup{C}$ is the \textit{least} upper bound of $C$, it follows - $\sup{C} \leq \sup{A} + \sup{B}$. + \subparagraph{Left-Hand Side}% - \subparagraph{Right-Hand Side}% + First consider the left-hand side of \eqref{par:theorem-i.33a-ii-eq1}. + By \nameref{par:theorem-i.33a-i}, $\sup{A} + \sup{B}$ is an upper bound + of $C$. + Since $\sup{C}$ is the \textit{least} upper bound of $C$, it follows + $\sup{C} \leq \sup{A} + \sup{B}$. - Next consider the right-hand side of \eqref{par:theorem-i.33a-ii-eq1}. - By \nameref{sub:theorem-i.32a}, there exists some $a' \in A$ such that - $\sup{A} < a' + 1 / (2n)$. - Likewise, there exists some $b' \in B$ such that - $\sup{B} < b' + 1 / (2n)$. - Adding these two inequalities together shows - \begin{align*} - \sup{A} + \sup{B} - & < a' + b' + 1 / n \\ - & \leq \sup{C} + 1 / n. - \end{align*} + \subparagraph{Right-Hand Side}% - \subparagraph{Conclusion}% + Next consider the right-hand side of \eqref{par:theorem-i.33a-ii-eq1}. + By \nameref{sub:theorem-i.32a}, there exists some $a' \in A$ such that + $\sup{A} < a' + 1 / (2n)$. + Likewise, there exists some $b' \in B$ such that + $\sup{B} < b' + 1 / (2n)$. + Adding these two inequalities together shows + \begin{align*} + \sup{A} + \sup{B} + & < a' + b' + 1 / n \\ + & \leq \sup{C} + 1 / n. + \end{align*} - Applying \nameref{sec:theorem-i.31} to \eqref{par:theorem-i.33a-ii-eq1} - proves $\sup{C} = \sup{A} + \sup{B}$ as expected. + \subparagraph{Conclusion}% -\end{proof} + Applying \nameref{sec:theorem-i.31} to \eqref{par:theorem-i.33a-ii-eq1} + proves $\sup{C} = \sup{A} + \sup{B}$ as expected. + + \end{proof} \subsection{\verified{Theorem I.33b}}% \hyperlabel{sub:theorem-i.33b} -\begin{theorem}[I.33b] - - If each of $A$ and $B$ has an infimum, then $C$ has an infimum, and - $$\inf{C} = \inf{A} + \inf{B}.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.33b] + If each of $A$ and $B$ has an infimum, then $C$ has an infimum, and + $$\inf{C} = \inf{A} + \inf{B}.$$ + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.inf\_minkowski\_sum\_eq\_inf\_add\_inf} - We prove (i) $\inf{A} + \inf{B}$ is a lower bound of $C$ and (ii) - $\inf{A} + \inf{B}$ is the \textit{greatest} lower bound of $C$. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-i.33b-i} + We prove (i) $\inf{A} + \inf{B}$ is a lower bound of $C$ and (ii) + $\inf{A} + \inf{B}$ is the \textit{greatest} lower bound of $C$. - Let $x \in C$. - By definition of $C$, there exist elements $a' \in A$ and $b' \in B$ such - that $x = a' + b'$. - By definition of an \nameref{ref:infimum}, $a' \geq \inf{A}$. - Likewise, $b' \geq \inf{B}$. - Therefore $a' + b' \geq \inf{A} + \inf{B}$. - Since $x = a' + b'$ was arbitrarily chosen, it follows $\inf{A} + \inf{B}$ - is a lower bound of $C$. + \paragraph{(i)}% + \hyperlabel{par:theorem-i.33b-i} - \paragraph{(ii)}% + Let $x \in C$. + By definition of $C$, there exist elements $a' \in A$ and $b' \in B$ such + that $x = a' + b'$. + By definition of an \nameref{ref:infimum}, $a' \geq \inf{A}$. + Likewise, $b' \geq \inf{B}$. + Therefore $a' + b' \geq \inf{A} + \inf{B}$. + Since $x = a' + b'$ was arbitrarily chosen, it follows $\inf{A} + \inf{B}$ + is a lower bound of $C$. - Since $A$ and $B$ have infimums, $C$ is nonempty. - By \nameref{par:theorem-i.33b-i}, $C$ is bounded below. - Therefore \nameref{sec:theorem-i.27} tells us $C$ has an infimum. - Let $n > 0$ be an integer. - We now prove that - \begin{equation} - \hyperlabel{par:theorem-i.33b-ii-eq1} - \inf{C} - 1 / n \leq \inf{A} + \inf{B} \leq \inf{C}. - \end{equation} + \paragraph{(ii)}% - \subparagraph{Right-Hand Side}% + Since $A$ and $B$ have infimums, $C$ is nonempty. + By \nameref{par:theorem-i.33b-i}, $C$ is bounded below. + Therefore \nameref{sec:theorem-i.27} tells us $C$ has an infimum. + Let $n > 0$ be an integer. + We now prove that + \begin{equation} + \hyperlabel{par:theorem-i.33b-ii-eq1} + \inf{C} - 1 / n \leq \inf{A} + \inf{B} \leq \inf{C}. + \end{equation} - First consider the right-hand side of \eqref{par:theorem-i.33b-ii-eq1}. - By \nameref{par:theorem-i.33b-i}, $\inf{A} + \inf{B}$ is a lower bound of - $C$. - Since $\inf{C}$ is the \textit{greatest} upper bound of $C$, it follows - $\inf{C} \geq \inf{A} + \inf{B}$. + \subparagraph{Right-Hand Side}% - \subparagraph{Left-Hand Side}% + First consider the right-hand side of \eqref{par:theorem-i.33b-ii-eq1}. + By \nameref{par:theorem-i.33b-i}, $\inf{A} + \inf{B}$ is a lower bound + of $C$. + Since $\inf{C}$ is the \textit{greatest} upper bound of $C$, it follows + $\inf{C} \geq \inf{A} + \inf{B}$. - Next consider the left-hand side of \eqref{par:theorem-i.33b-ii-eq1}. - By \nameref{sub:theorem-i.32b}, there exists some $a' \in A$ such that - $\inf{A} > a' - 1 / (2n)$. - Likewise, there exists some $b' \in B$ such that - $\inf{B} > b' - 1 / (2n)$. - Adding these two inequalities together shows - \begin{align*} - \inf{A} + \inf{B} - & > a' + b' - 1 / n \\ - & \geq \inf{C} - 1 / n. - \end{align*} + \subparagraph{Left-Hand Side}% - \subparagraph{Conclusion}% + Next consider the left-hand side of \eqref{par:theorem-i.33b-ii-eq1}. + By \nameref{sub:theorem-i.32b}, there exists some $a' \in A$ such that + $\inf{A} > a' - 1 / (2n)$. + Likewise, there exists some $b' \in B$ such that + $\inf{B} > b' - 1 / (2n)$. + Adding these two inequalities together shows + \begin{align*} + \inf{A} + \inf{B} + & > a' + b' - 1 / n \\ + & \geq \inf{C} - 1 / n. + \end{align*} - Applying \nameref{sec:lemma-2} to \eqref{par:theorem-i.33b-ii-eq1} - proves $\inf{C} = \inf{A} + \inf{B}$ as expected. + \subparagraph{Conclusion}% -\end{proof} + Applying \nameref{sec:lemma-2} to \eqref{par:theorem-i.33b-ii-eq1} + proves $\inf{C} = \inf{A} + \inf{B}$ as expected. + + \end{proof} \section{\verified{Theorem I.34}}% \hyperlabel{sec:theorem-i.34} -\begin{theorem}[I.34] - - Given two nonempty subsets $S$ and $T$ of $\mathbb{R}$ such that $$s \leq t$$ - for every $s$ in $S$ and every $t$ in $T$. Then $S$ has a supremum, and $T$ - has an infimum, and they satisfy the inequality $$\sup{S} \leq \inf{T}.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[I.34] + Given two nonempty subsets $S$ and $T$ of $\mathbb{R}$ such that + $$s \leq t$$ for every $s$ in $S$ and every $t$ in $T$. Then $S$ has a + supremum, and $T$ has an infimum, and they satisfy the inequality + $$\sup{S} \leq \inf{T}.$$ + \end{theorem} \code{Bookshelf/Apostol/Chapter\_I\_03} {Apostol.Chapter\_I\_03.forall\_mem\_le\_forall\_mem\_imp\_sup\_le\_inf} - By hypothesis, $S$ and $T$ are nonempty sets. - Let $s \in S$ and $t \in T$. - Then $t$ is an upper bound of $S$ and $s$ is a lower bound of $T$. - By the completeness axiom, $S$ has a supremum. - By \nameref{sec:theorem-i.27}, $T$ has an infimum. - All that remains is showing $\sup{S} \leq \inf{T}$. + \begin{proof} + By hypothesis, $S$ and $T$ are nonempty sets. + Let $s \in S$ and $t \in T$. + Then $t$ is an upper bound of $S$ and $s$ is a lower bound of $T$. + By the completeness axiom, $S$ has a supremum. + By \nameref{sec:theorem-i.27}, $T$ has an infimum. + All that remains is showing $\sup{S} \leq \inf{T}$. - For the sake of contradiction, suppose $\sup{S} > \inf{T}$. - Then there exists some $c > 0$ such that $\sup{S} = \inf{T} + c$. - Therefore $\inf{T} < \sup{S} - c / 2$. - By \nameref{sub:theorem-i.32a}, there exists some $x \in S$ such that - $\sup{S} - c / 2 < x$. - Thus $$\inf{T} < \sup{S} - c / 2 < x.$$ - But by hypothesis, $x \in S$ is a lower bound of $T$ meaning $x \leq \inf{T}$. - Therefore $x < x$, a contradiction. - Out original assumption is incorrect; that is, $\sup{S} \leq \inf{T}$. - -\end{proof} + For the sake of contradiction, suppose $\sup{S} > \inf{T}$. + Then there exists some $c > 0$ such that $\sup{S} = \inf{T} + c$. + Therefore $\inf{T} < \sup{S} - c / 2$. + By \nameref{sub:theorem-i.32a}, there exists some $x \in S$ such that + $\sup{S} - c / 2 < x$. + Thus $$\inf{T} < \sup{S} - c / 2 < x.$$ + But by hypothesis, $x \in S$ is a lower bound of $T$ meaning + $x \leq \inf{T}$. + Therefore $x < x$, a contradiction. + Out original assumption is incorrect; that is, $\sup{S} \leq \inf{T}$. + \end{proof} \chapter{The Concepts of Integral Calculus}% \hyperlabel{chap:concepts-integral-calculus} @@ -667,176 +611,150 @@ Given nonempty subsets $A$ and $B$ of $\mathbb{R}$, let $C$ denote the set \section{The Concept of Area as a Set Function}% \hyperlabel{sec:concept-area-set-function} -We assume there exists a class $\mathscr{M}$ of measurable sets in the plane and - a set function $a$, whose domain is $\mathscr{M}$, with the following - properties: + We assume there exists a class $\mathscr{M}$ of measurable sets in the plane and + a set function $a$, whose domain is $\mathscr{M}$, with the following + properties: \subsection{\defined{Nonnegative Property}}% \hyperlabel{sub:nonnegative-property} -For each set $S$ in $\mathscr{M}$, we have $a(S) \geq 0$. - -\begin{axiom} + For each set $S$ in $\mathscr{M}$, we have $a(S) \geq 0$. \codep*{Common/Geometry/Area}{Nonnegative-Property} {Nonnegative Property} -\end{axiom} - \subsection{\defined{Additive Property}}% \hyperlabel{sub:area-additive-property} -If $S$ and $T$ are in $\mathscr{M}$, then $S \cup T$ and $S \cap T$ are in - $\mathscr{M}$, and we have $a(S \cup T) = a(S) + a(T) - a(S \cap T)$. - -\begin{axiom} + If $S$ and $T$ are in $\mathscr{M}$, then $S \cup T$ and $S \cap T$ are in + $\mathscr{M}$, and we have $a(S \cup T) = a(S) + a(T) - a(S \cap T)$. \codep*{Common/Geometry/Area}{Additive-Property} {Additive Property} -\end{axiom} - \subsection{\defined{Difference Property}}% \hyperlabel{sub:area-difference-property} -If $S$ and $T$ are in $\mathscr{M}$ with $S \subseteq T$, then $T - S$ is in - $\mathscr{M}$, and we have $a(T - S) = a(T) - a(S)$. - -\begin{axiom} + If $S$ and $T$ are in $\mathscr{M}$ with $S \subseteq T$, then $T - S$ is in + $\mathscr{M}$, and we have $a(T - S) = a(T) - a(S)$. \codep*{Common/Geometry/Area}{Difference-Property} {Difference Property} -\end{axiom} - \subsection{\defined{Invariance Under Congruence}}% \hyperlabel{sub:area-invariance-under-congruence} -If a set $S$ is in $\mathscr{M}$ and if $T$ is congruent to $S$, then $T$ is - also in $\mathscr{M}$ and we have $a(S) = a(T)$. - -\begin{axiom} + If a set $S$ is in $\mathscr{M}$ and if $T$ is congruent to $S$, then $T$ is + also in $\mathscr{M}$ and we have $a(S) = a(T)$. \codep*{Common/Geometry/Area}{Invariance-Under-Congruence} {Invariance Under Congruence} -\end{axiom} - \subsection{\defined{Choice of Scale}}% \hyperlabel{sub:area-choice-scale} -Every rectangle $R$ is in $\mathscr{M}$. -If the edges of $R$ have lengths $h$ and $k$, then $a(R) = hk$. - -\begin{axiom} + Every rectangle $R$ is in $\mathscr{M}$. + If the edges of $R$ have lengths $h$ and $k$, then $a(R) = hk$. \codep*{Common/Geometry/Area}{Choice-of-Scale} {Choice of Scale} -\end{axiom} - \subsection{\pending{Exhaustion Property}}% \hyperlabel{sub:area-exhaustion-property} -Let $Q$ be a set that can be enclosed between two step regions $S$ and $T$, so - that - \begin{equation} - \hyperlabel{sub:exhaustion-property-eq1} - S \subseteq Q \subseteq T. - \end{equation} -If there is one and only one number $c$ which satisfies the inequalities - $$a(S) \leq c \leq a(T)$$ for all step regions $S$ and $T$ satisfying - \eqref{sub:exhaustion-property-eq1}, then $Q$ is measurable and $a(Q) = c$. - -\begin{axiom} + Let $Q$ be a set that can be enclosed between two step regions $S$ and $T$, so + that + \begin{equation} + \hyperlabel{sub:exhaustion-property-eq1} + S \subseteq Q \subseteq T. + \end{equation} + If there is one and only one number $c$ which satisfies the inequalities + $$a(S) \leq c \leq a(T)$$ for all step regions $S$ and $T$ satisfying + \eqref{sub:exhaustion-property-eq1}, then $Q$ is measurable and $a(Q) = c$. \codep*{Common/Geometry/Area}{Exhaustion-Property} {Exhaustion Property} -\end{axiom} - \section{Exercises 1.7}% \hyperlabel{sec:exercises-1.7} \subsection{\pending{Exercise 1.7.1}}% \hyperlabel{sub:exercise-1.7.1} -Prove that each of the following sets is measurable and has zero area: + Prove that each of the following sets is measurable and has zero area: \subsubsection{\pending{Exercise 1.7.1a}}% \hyperlabel{ssub:exercise-1.7.1a} -A set consisting of a single point. + A set consisting of a single point. -\begin{proof} - - Let $S$ be a set consisting of a single point. - By definition of a point, $S$ is a rectangle in which all vertices coincide. - By \nameref{sub:area-choice-scale}, $S$ is measurable with area its width - times its height. - The width and height of $S$ is trivially zero. - Therefore $a(S) = (0)(0) = 0$. - -\end{proof} + \begin{proof} + Let $S$ be a set consisting of a single point. + By definition of a point, $S$ is a rectangle in which all vertices coincide. + By \nameref{sub:area-choice-scale}, $S$ is measurable with area its width + times its height. + The width and height of $S$ is trivially zero. + Therefore $a(S) = (0)(0) = 0$. + \end{proof} \subsubsection{\pending{Exercise 1.7.1b}}% \hyperlabel{ssub:exercise-1.7.1b} -A set consisting of a finite number of points in a plane. + A set consisting of a finite number of points in a plane. -\begin{proof} + \begin{proof} - Define predicate $P(n)$ as "A set consisting of $n$ points in a plane is - measurable with area $0$". - We use induction to prove $P(n)$ holds for all $n > 0$. + Define predicate $P(n)$ as "A set consisting of $n$ points in a plane is + measurable with area $0$". + We use induction to prove $P(n)$ holds for all $n > 0$. - \paragraph{Base Case}% + \paragraph{Base Case}% - Consider a set $S$ consisting of a single point in a plane. - By \nameref{ssub:exercise-1.7.1a}, $S$ is measurable with area $0$. - Thus $P(1)$ holds. + Consider a set $S$ consisting of a single point in a plane. + By \nameref{ssub:exercise-1.7.1a}, $S$ is measurable with area $0$. + Thus $P(1)$ holds. - \paragraph{Induction Step}% + \paragraph{Induction Step}% - Assume induction hypothesis $P(k)$ holds for some $k > 0$. - Let $S_{k+1}$ be a set consisting of $k + 1$ points in a plane. - Pick an arbitrary point of $S_{k+1}$. - Denote the set containing just this point as $T$. - Denote the remaining set of points as $S_k$. - By construction, $S_{k+1} = S_k \cup T$. - By the induction hypothesis, $S_k$ is measurable with area $0$. - By \nameref{ssub:exercise-1.7.1a}, $T$ is measurable with area $0$. - By the \nameref{sub:area-additive-property}, $S_k \cup T$ is - measurable, $S_k \cap T$ is measurable, and - \begin{align} - a(S_{k+1}) - & = a(S_k \cup T) \nonumber \\ - & = a(S_k) + a(T) - a(S_k \cap T) \nonumber \\ - & = 0 + 0 - a(S_k \cap T). \hyperlabel{ssub:exercise-1.7.1b-eq1} - \end{align} - There are two cases to consider: + Assume induction hypothesis $P(k)$ holds for some $k > 0$. + Let $S_{k+1}$ be a set consisting of $k + 1$ points in a plane. + Pick an arbitrary point of $S_{k+1}$. + Denote the set containing just this point as $T$. + Denote the remaining set of points as $S_k$. + By construction, $S_{k+1} = S_k \cup T$. + By the induction hypothesis, $S_k$ is measurable with area $0$. + By \nameref{ssub:exercise-1.7.1a}, $T$ is measurable with area $0$. + By the \nameref{sub:area-additive-property}, $S_k \cup T$ is + measurable, $S_k \cap T$ is measurable, and + \begin{align} + a(S_{k+1}) + & = a(S_k \cup T) \nonumber \\ + & = a(S_k) + a(T) - a(S_k \cap T) \nonumber \\ + & = 0 + 0 - a(S_k \cap T). \hyperlabel{ssub:exercise-1.7.1b-eq1} + \end{align} + There are two cases to consider: - \subparagraph{Case 1}% + \subparagraph{Case 1}% - $S_k \cap T = \emptyset$. - Then it trivially follows that $a(S_k \cap T) = 0$. + $S_k \cap T = \emptyset$. + Then it trivially follows that $a(S_k \cap T) = 0$. - \subparagraph{Case 2}% + \subparagraph{Case 2}% - $S_k \cap T \neq \emptyset$. - Since $T$ consists of a single point, $S_k \cap T = T$. - By \nameref{ssub:exercise-1.7.1a}, $a(S_k \cap T) = a(T) = 0$. + $S_k \cap T \neq \emptyset$. + Since $T$ consists of a single point, $S_k \cap T = T$. + By \nameref{ssub:exercise-1.7.1a}, $a(S_k \cap T) = a(T) = 0$. - \vspace{8pt} - \noindent - In both cases, \eqref{ssub:exercise-1.7.1b-eq1} evaluates to $0$, implying - $P(k + 1)$ as expected. + \vspace{8pt} + \noindent + In both cases, \eqref{ssub:exercise-1.7.1b-eq1} evaluates to $0$, implying + $P(k + 1)$ as expected. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - By mathematical induction, it follows for all $n > 0$, $P(n)$ is true. + By mathematical induction, it follows for all $n > 0$, $P(n)$ is true. -\end{proof} + \end{proof} \subsubsection{\pending{Exercise 1.7.1c}}% \hyperlabel{ssub:exercise-1.7.1c} @@ -904,426 +822,424 @@ The union of a finite collection of line segments in a plane. \subsection{\pending{Exercise 1.7.2}}% \hyperlabel{sub:exercise-1.7.2} -Every right triangular region is measurable because it can be obtained as the - intersection of two rectangles. -Prove that every triangular region is measurable and that its area is one half - the product of its base and altitude. + Every right triangular region is measurable because it can be obtained as the + intersection of two rectangles. + Prove that every triangular region is measurable and that its area is one half + the product of its base and altitude. -\begin{proof} + \begin{proof} + Let $T'$ be a triangular region with base of length $a$, height of length + $b$, and hypotenuse of length $c$. + Consider the translation and rotation of $T'$, say $T$, such that its + hypotenuse is entirely within quadrant I and the vertex opposite the + hypotenuse is situated at point $(0, 0)$. - Let $T'$ be a triangular region with base of length $a$, height of length $b$, - and hypotenuse of length $c$. - Consider the translation and rotation of $T'$, say $T$, such that its - hypotenuse is entirely within quadrant I and the vertex opposite the - hypotenuse is situated at point $(0, 0)$. + Let $R$ be a rectangle of width $a$, height $b$, and bottom-left corner at + $(0, 0)$. + By construction, $R$ covers all of $T$. + Let $S$ be a rectangle of width $c$ and height $a\sin{\theta}$, where + $\theta$ is the acute angle measured from the bottom-right corner of $T$ + relative to the $x$-axis. + As an example, consider the image below of triangle $T$ with width $4$ and + height $3$: - Let $R$ be a rectangle of width $a$, height $b$, and bottom-left corner at - $(0, 0)$. - By construction, $R$ covers all of $T$. - Let $S$ be a rectangle of width $c$ and height $a\sin{\theta}$, where $\theta$ - is the acute angle measured from the bottom-right corner of $T$ relative - to the $x$-axis. - As an example, consider the image below of triangle $T$ with width $4$ and - height $3$: + \begin{figure}[ht] + \includegraphics{right-triangle} + \centering + \end{figure} - \begin{figure}[ht] - \includegraphics{right-triangle} - \centering - \end{figure} - - By \nameref{sub:area-choice-scale}, both $R$ and $S$ are measurable. - By this same axiom, $a(R) = ab$ and $a(S) = ca\sin{\theta}$. - By the \nameref{sub:area-additive-property}, $R \cup S$ and $R \cap S$ are - both measurable. - $a(R \cap S) = a(T)$ and $a(R \cup S)$ can be determined by noting that - $R$'s construction implies identity $a(R) = 2a(T)$. - Therefore - \begin{align*} - a(T) - & = a(R \cap S) \\ - & = a(R) + a(S) - a(R \cup S) \\ - & = ab + ca\sin{\theta} - a(R \cup S) \\ - & = ab + ca\sin{\theta} - (ca\sin{\theta} + \frac{1}{2}a(R)) \\ - & = ab + ca\sin{\theta} - ca\sin{\theta} - a(T). - \end{align*} - Solving for $a(T)$ gives the desired identity: $$a(T) = \frac{1}{2}ab.$$ - By \nameref{sub:area-invariance-under-congruence}, $a(T') = a(T)$, concluding - our proof. - -\end{proof} + By \nameref{sub:area-choice-scale}, both $R$ and $S$ are measurable. + By this same axiom, $a(R) = ab$ and $a(S) = ca\sin{\theta}$. + By the \nameref{sub:area-additive-property}, $R \cup S$ and $R \cap S$ are + both measurable. + $a(R \cap S) = a(T)$ and $a(R \cup S)$ can be determined by noting that + $R$'s construction implies identity $a(R) = 2a(T)$. + Therefore + \begin{align*} + a(T) + & = a(R \cap S) \\ + & = a(R) + a(S) - a(R \cup S) \\ + & = ab + ca\sin{\theta} - a(R \cup S) \\ + & = ab + ca\sin{\theta} - (ca\sin{\theta} + \frac{1}{2}a(R)) \\ + & = ab + ca\sin{\theta} - ca\sin{\theta} - a(T). + \end{align*} + Solving for $a(T)$ gives the desired identity: $$a(T) = \frac{1}{2}ab.$$ + By \nameref{sub:area-invariance-under-congruence}, $a(T') = a(T)$, + concluding our proof. + \end{proof} \subsection{\pending{Exercise 1.7.3}}% \hyperlabel{sub:exercise-1.7.3} -Prove that every trapezoid and every parallelogram is measurable and derive the - usual formulas for their areas. + Prove that every trapezoid and every parallelogram is measurable and derive + the usual formulas for their areas. -\begin{proof} + \begin{proof} - We begin by proving the formula for a trapezoid. - Let $S$ be a trapezoid with height $h$ and bases $b_1$ and $b_2$, $b_1 < b_2$. - There are three cases to consider: + We begin by proving the formula for a trapezoid. + Let $S$ be a trapezoid with height $h$ and bases $b_1$ and $b_2$, + $b_1 < b_2$. + There are three cases to consider: - \begin{figure}[ht] - \includegraphics[width=\textwidth]{trapezoid-cases} - \centering - \end{figure} + \begin{figure}[ht] + \includegraphics[width=\textwidth]{trapezoid-cases} + \centering + \end{figure} - \paragraph{Case 1}% + \paragraph{Case 1}% - Suppose $S$ is a right trapezoid. - Then $S$ is the union of non-overlapping rectangle $R$ of width $b_1$ and - height $h$ with right triangle $T$ of base $b_2 - b_1$ and height $h$. - By \nameref{sub:area-choice-scale}, $R$ is measurable. - By \nameref{sub:exercise-1.7.2}, $T$ is measurable. - By the \nameref{sub:area-additive-property}, $R \cup T$ and $R \cap T$ are - both measurable and - \begin{align*} - a(S) - & = a(R \cup T) \\ - & = a(R) + a(T) - a(R \cap T) \\ - & = a(R) + a(T) & \text{by construction} \\ - & = b_1h + a(T) & \text{Choice of Scale} \\ - & = b_1h + \frac{1}{2}(b_2 - b_1)h & \textref{sub:exercise-1.7.2} \\ - & = \frac{b_1 + b_2}{2}h. - \end{align*} + Suppose $S$ is a right trapezoid. + Then $S$ is the union of non-overlapping rectangle $R$ of width $b_1$ and + height $h$ with right triangle $T$ of base $b_2 - b_1$ and height $h$. + By \nameref{sub:area-choice-scale}, $R$ is measurable. + By \nameref{sub:exercise-1.7.2}, $T$ is measurable. + By the \nameref{sub:area-additive-property}, $R \cup T$ and $R \cap T$ are + both measurable and + \begin{align*} + a(S) + & = a(R \cup T) \\ + & = a(R) + a(T) - a(R \cap T) \\ + & = a(R) + a(T) & \text{by construction} \\ + & = b_1h + a(T) & \text{Choice of Scale} \\ + & = b_1h + \frac{1}{2}(b_2 - b_1)h & \textref{sub:exercise-1.7.2} \\ + & = \frac{b_1 + b_2}{2}h. + \end{align*} - \paragraph{Case 2}% + \paragraph{Case 2}% - Suppose $S$ is an acute trapezoid. - Then $S$ is the union of non-overlapping triangle $T$ and right trapezoid $R$. - Let $c$ denote the length of base $T$. - Then $R$ has longer base edge of length $b_2 - c$. - By \nameref{sub:exercise-1.7.2}, $T$ is measurable. - By Case 1, $R$ is measurable. - By the \nameref{sub:area-additive-property}, $R \cup T$ and $R \cap T$ are - both measurable and - \begin{align*} - a(S) - & = a(T) + a(R) - a(R \cap T) \\ - & = a(T) + a(R) & \text{by construction} \\ - & = \frac{1}{2}ch + a(R) & \textref{sub:exercise-1.7.2} \\ - & = \frac{1}{2}ch + \frac{b_1 + b_2 - c}{2}h & \text{Case 1} \\ - & = \frac{b_1 + b_2}{2}h. - \end{align*} + Suppose $S$ is an acute trapezoid. + Then $S$ is the union of non-overlapping triangle $T$ and right trapezoid + $R$. + Let $c$ denote the length of base $T$. + Then $R$ has longer base edge of length $b_2 - c$. + By \nameref{sub:exercise-1.7.2}, $T$ is measurable. + By Case 1, $R$ is measurable. + By the \nameref{sub:area-additive-property}, $R \cup T$ and $R \cap T$ are + both measurable and + \begin{align*} + a(S) + & = a(T) + a(R) - a(R \cap T) \\ + & = a(T) + a(R) & \text{by construction} \\ + & = \frac{1}{2}ch + a(R) & \textref{sub:exercise-1.7.2} \\ + & = \frac{1}{2}ch + \frac{b_1 + b_2 - c}{2}h & \text{Case 1} \\ + & = \frac{b_1 + b_2}{2}h. + \end{align*} - \paragraph{Case 3}% + \paragraph{Case 3}% - Suppose $S$ is an obtuse trapezoid. - Then $S$ is the union of non-overlapping triangle $T$ and right trapezoid $R$. + Suppose $S$ is an obtuse trapezoid. + Then $S$ is the union of non-overlapping triangle $T$ and right trapezoid + $R$. + Let $c$ denote the length of base $T$. + Reflect $T$ vertically to form another right triangle, say $T'$. + Then $T' \cup R$ is an acute trapezoid. + By \nameref{sub:area-invariance-under-congruence}, + \begin{equation} + \hyperlabel{sub:exercise-1.7.3-eq1} + \tag{3.1} + a(T' \cup R) = a(T \cup R). + \end{equation} + By construction, $T' \cup R$ has height $h$ and bases $b_1 - c$ and + $b_2 + c$ meaning + \begin{align*} + a(T \cup R) + & = a(T' \cup R) & \eqref{sub:exercise-1.7.3-eq1} \\ + & = \frac{b_1 - c + b_2 + c}{2}h & \text{Case 2} \\ + & = \frac{b_1 + b_2}{2}h. + \end{align*} + + \paragraph{Conclusion}% + + These cases are exhaustive and in agreement with one another. + Thus $S$ is measurable and $$a(S) = \frac{b_1 + b_2}{2}h.$$ + + \suitdivider + + Let $P$ be a parallelogram with base $b$ and height $h$. + Then $P$ is the union of non-overlapping triangle $T$ and right trapezoid + $R$. Let $c$ denote the length of base $T$. Reflect $T$ vertically to form another right triangle, say $T'$. Then $T' \cup R$ is an acute trapezoid. By \nameref{sub:area-invariance-under-congruence}, \begin{equation} - \hyperlabel{sub:exercise-1.7.3-eq1} - \tag{3.1} + \hyperlabel{sub:exercise-1.7.3-eq2} a(T' \cup R) = a(T \cup R). \end{equation} - By construction, $T' \cup R$ has height $h$ and bases $b_1 - c$ and $b_2 + c$ + By construction, $T' \cup R$ has height $h$ and bases $b - c$ and $b + c$ meaning \begin{align*} a(T \cup R) - & = a(T' \cup R) & \eqref{sub:exercise-1.7.3-eq1} \\ - & = \frac{b_1 - c + b_2 + c}{2}h & \text{Case 2} \\ - & = \frac{b_1 + b_2}{2}h. + & = a(T' \cup R) & \eqref{sub:exercise-1.7.3-eq2} \\ + & = \frac{b - c + b + c}{2}h & \text{Area of Trapezoid} \\ + & = bh. \end{align*} - \paragraph{Conclusion}% - - These cases are exhaustive and in agreement with one another. - Thus $S$ is measurable and $$a(S) = \frac{b_1 + b_2}{2}h.$$ - - \suitdivider - - Let $P$ be a parallelogram with base $b$ and height $h$. - Then $P$ is the union of non-overlapping triangle $T$ and right trapezoid $R$. - Let $c$ denote the length of base $T$. - Reflect $T$ vertically to form another right triangle, say $T'$. - Then $T' \cup R$ is an acute trapezoid. - By \nameref{sub:area-invariance-under-congruence}, - \begin{equation} - \hyperlabel{sub:exercise-1.7.3-eq2} - a(T' \cup R) = a(T \cup R). - \end{equation} - By construction, $T' \cup R$ has height $h$ and bases $b - c$ and $b + c$ - meaning - \begin{align*} - a(T \cup R) - & = a(T' \cup R) & \eqref{sub:exercise-1.7.3-eq2} \\ - & = \frac{b - c + b + c}{2}h & \text{Area of Trapezoid} \\ - & = bh. - \end{align*} - -\end{proof} + \end{proof} \subsection{\pending{Exercise 1.7.4}}% \hyperlabel{sub:exercise-1.7.4} -Let $P$ be a polygon whose vertices are lattice points. -The area of $P$ is $I + \frac{1}{2}B - 1$, where $I$ denotes the number of - lattice points inside the polygon and $B$ denotes the number on the boundary. + Let $P$ be a polygon whose vertices are lattice points. + The area of $P$ is $I + \frac{1}{2}B - 1$, where $I$ denotes the number of + lattice points inside the polygon and $B$ denotes the number on the + boundary. \subsubsection{\pending{Exercise 1.7.4a}}% \hyperlabel{ssub:exercise-1.7.4a} -Prove that the formula is valid for rectangles with sides parallel to the - coordinate axes. + Prove that the formula is valid for rectangles with sides parallel to the + coordinate axes. -\begin{proof} + \begin{proof} + Let $P$ be a rectangle with sides parallel to the coordinate axes, with + width $w$, height $h$, and lattice points for vertices. + We assume $P$ has three non-collinear points, ruling out any instances of + points or line segments. - Let $P$ be a rectangle with sides parallel to the coordinate axes, with width - $w$, height $h$, and lattice points for vertices. - We assume $P$ has three non-collinear points, ruling out any instances of - points or line segments. - - By \nameref{sub:area-choice-scale}, $P$ is measurable with area $a(P) = wh$. - By construction, $P$ has $I = (w - 1)(h - 1)$ interior lattice points and - $B = 2(w + h)$ lattice points on its boundary. - The following shows the lattice point area formula is in agreement with - the expected result: - \begin{align*} - I + \frac{1}{2}B - 1 - & = (w - 1)(h - 1) + \frac{1}{2}\left[ 2(w + h) \right] - 1 \\ - & = (wh - w - h + 1) + \frac{1}{2}\left[ 2(w + h) \right] - 1 \\ - & = (wh - w - h + 1) + (w + h) - 1 \\ - & = wh. - \end{align*} - -\end{proof} + By \nameref{sub:area-choice-scale}, $P$ is measurable with area $a(P) = wh$. + By construction, $P$ has $I = (w - 1)(h - 1)$ interior lattice points and + $B = 2(w + h)$ lattice points on its boundary. + The following shows the lattice point area formula is in agreement with + the expected result: + \begin{align*} + I + \frac{1}{2}B - 1 + & = (w - 1)(h - 1) + \frac{1}{2}\left[ 2(w + h) \right] - 1 \\ + & = (wh - w - h + 1) + \frac{1}{2}\left[ 2(w + h) \right] - 1 \\ + & = (wh - w - h + 1) + (w + h) - 1 \\ + & = wh. + \end{align*} + \end{proof} \subsubsection{\pending{Exercise 1.7.4b}}% \hyperlabel{ssub:exercise-1.7.4b} -Prove that the formula is valid for right triangles and parallelograms. + Prove that the formula is valid for right triangles and parallelograms. -\begin{proof} + \begin{proof} + Let $P$ be a right triangle with width $w > 0$, height $h > 0$, and lattice + points for vertices. + Let $T$ be the triangle $P$ translated, rotated, and reflected such that the + its vertices are $(0, 0)$, $(0, w)$, and $(w, h)$. + Let $I_T$ and $B_T$ be the number of interior and boundary points of $T$ + respectively. + Let $H_L$ denote the number of lattice points on $T$'s hypotenuse. - Let $P$ be a right triangle with width $w > 0$, height $h > 0$, and lattice - points for vertices. - Let $T$ be the triangle $P$ translated, rotated, and reflected such that the - its vertices are $(0, 0)$, $(0, w)$, and $(w, h)$. - Let $I_T$ and $B_T$ be the number of interior and boundary points of $T$ - respectively. - Let $H_L$ denote the number of lattice points on $T$'s hypotenuse. + Let $R$ be the overlapping rectangle of width $w$ and height $h$, situated + with bottom-left corner at $(0, 0)$. + Let $I_R$ and $B_R$ be the number of interior and boundary points + of $R$ respectively. - Let $R$ be the overlapping rectangle of width $w$ and height $h$, situated - with bottom-left corner at $(0, 0)$. - Let $I_R$ and $B_R$ be the number of interior and boundary points - of $R$ respectively. + By construction, $T$ shares two sides with $R$. + Therefore + \begin{equation} + \hyperlabel{ssub:exercise-1.7.4b-eq1} + B_T = \frac{1}{2}B_R - 1 + H_L. + \end{equation} + Likewise, + \begin{equation} + \hyperlabel{ssub:exercise-1.7.4b-eq2} + I_T = \frac{1}{2}(I_R - (H_L - 2)). + \end{equation} + The following shows the lattice point area formula is in agreement with + the expected result: + \begin{align*} + I_T + \frac{1}{2}B_T - 1 + & = \frac{1}{2}(I_R - (H_L - 2)) + \frac{1}{2}B_T - 1 + & \eqref{ssub:exercise-1.7.4b-eq2} \\ + & = \frac{1}{2}\left[ I_R - H_L + B_T \right] \\ + & = \frac{1}{2}\left[ I_R - H_L + \frac{1}{2}B_R - 1 + H_L \right] + & \eqref{ssub:exercise-1.7.4b-eq1} \\ + & = \frac{1}{2}\left[ I_R + \frac{1}{2}B_R - 1 \right] \\ + & = \frac{1}{2}\left[ wh \right] & \textref{ssub:exercise-1.7.4a}. + \end{align*} - By construction, $T$ shares two sides with $R$. - Therefore - \begin{equation} - \hyperlabel{ssub:exercise-1.7.4b-eq1} - B_T = \frac{1}{2}B_R - 1 + H_L. - \end{equation} - Likewise, - \begin{equation} - \hyperlabel{ssub:exercise-1.7.4b-eq2} - I_T = \frac{1}{2}(I_R - (H_L - 2)). - \end{equation} - The following shows the lattice point area formula is in agreement with - the expected result: - \begin{align*} - I_T + \frac{1}{2}B_T - 1 - & = \frac{1}{2}(I_R - (H_L - 2)) + \frac{1}{2}B_T - 1 - & \eqref{ssub:exercise-1.7.4b-eq2} \\ - & = \frac{1}{2}\left[ I_R - H_L + B_T \right] \\ - & = \frac{1}{2}\left[ I_R - H_L + \frac{1}{2}B_R - 1 + H_L \right] - & \eqref{ssub:exercise-1.7.4b-eq1} \\ - & = \frac{1}{2}\left[ I_R + \frac{1}{2}B_R - 1 \right] \\ - & = \frac{1}{2}\left[ wh \right] & \textref{ssub:exercise-1.7.4a}. - \end{align*} - - We do not prove this formula is valid for parallelograms here. - Instead, refer to \nameref{ssub:exercise-1.7.4c} below. - -\end{proof} + We do not prove this formula is valid for parallelograms here. + Instead, refer to \nameref{ssub:exercise-1.7.4c} below. + \end{proof} \subsubsection{\pending{Exercise 1.7.4c}}% \hyperlabel{ssub:exercise-1.7.4c} -Use induction on the number of edges to construct a proof for general polygons. + Use induction on the number of edges to construct a proof for general + polygons. -\begin{proof} + \begin{proof} - Define predicate $P(n)$ as "An $n$-polygon with vertices on lattice points has - area $I + \frac{1}{2}B - 1$." - We use induction to prove $P(n)$ holds for all $n \geq 3$. + Define predicate $P(n)$ as "An $n$-polygon with vertices on lattice points + has area $I + \frac{1}{2}B - 1$." + We use induction to prove $P(n)$ holds for all $n \geq 3$. - \paragraph{Base Case}% + \paragraph{Base Case}% - A $3$-polygon is a triangle. - By \nameref{ssub:exercise-1.7.4b}, the lattice point area formula holds. - Thus $P(3)$ holds. + A $3$-polygon is a triangle. + By \nameref{ssub:exercise-1.7.4b}, the lattice point area formula holds. + Thus $P(3)$ holds. - \paragraph{Induction Step}% + \paragraph{Induction Step}% - Assume induction hypothesis $P(k)$ holds for some $k \geq 3$. - Let $P$ be a $(k + 1)$-polygon with vertices on lattice points. - Such a polygon is equivalent to the union of a $k$-polygon $S$ with a - triangle $T$. - That is, $P = S \cup T$. + Assume induction hypothesis $P(k)$ holds for some $k \geq 3$. + Let $P$ be a $(k + 1)$-polygon with vertices on lattice points. + Such a polygon is equivalent to the union of a $k$-polygon $S$ with a + triangle $T$. + That is, $P = S \cup T$. - Let $I_P$ be the number of interior lattice points of $P$. - Let $B_P$ be the number of boundary lattice points of $P$. - Similarly, let $I_S$, $I_T$, $B_S$, and $B_T$ be the number of interior - and boundary lattice points of $S$ and $T$. - Let $c$ denote the number of boundary points shared between $S$ and $T$. + Let $I_P$ be the number of interior lattice points of $P$. + Let $B_P$ be the number of boundary lattice points of $P$. + Similarly, let $I_S$, $I_T$, $B_S$, and $B_T$ be the number of interior + and boundary lattice points of $S$ and $T$. + Let $c$ denote the number of boundary points shared between $S$ and $T$. - By our induction hypothesis, $a(S) = I_S + \frac{1}{2}B_S - 1$. - By our base case, $a(T) = I_T + \frac{1}{2}B_T - 1$. - By construction, it follows: - \begin{align*} - I_P & = I_S + I_T + c - 2 \\ - B_P & = B_S + B_T - (c - 2) - c \\ - & = B_S + B_T - 2c + 2. - \end{align*} - Applying the lattice point area formula to $P$ yields the following: - \begin{align*} - & I_P + \frac{1}{2}B_P - 1 \\ - & = (I_S + I_T + c - 2) + \frac{1}{2}(B_S + B_T - 2c + 2) - 1 \\ - & = I_S + I_T + c - 2 + \frac{1}{2}B_S + \frac{1}{2}B_T - c + 1 - 1 \\ - & = (I_S + \frac{1}{2}B_S - 1) + (I_T + \frac{1}{2}B_T - 1) \\ - & = a(S) + (I_T + \frac{1}{2}B_T - 1) & \text{induction hypothesis} \\ - & = a(S) + a(T). & \text{base case} - \end{align*} - By the \nameref{sub:area-additive-property}, $S \cup T$ is measurable, - $S \cap T$ is measurable, and - \begin{align*} - a(P) - & = a(S \cup T) \\ - & = a(S) + a(T) - a(S \cap T) \\ - & = a(S) + a(T). & \text{by construction} - \end{align*} - This shows the lattice point area formula is in agreement with our axiomatic - definition of area. - Thus $P(k + 1)$ holds. + By our induction hypothesis, $a(S) = I_S + \frac{1}{2}B_S - 1$. + By our base case, $a(T) = I_T + \frac{1}{2}B_T - 1$. + By construction, it follows: + \begin{align*} + I_P & = I_S + I_T + c - 2 \\ + B_P & = B_S + B_T - (c - 2) - c \\ + & = B_S + B_T - 2c + 2. + \end{align*} + Applying the lattice point area formula to $P$ yields the following: + \begin{align*} + & I_P + \frac{1}{2}B_P - 1 \\ + & = (I_S + I_T + c - 2) + \frac{1}{2}(B_S + B_T - 2c + 2) - 1 \\ + & = I_S + I_T + c - 2 + \frac{1}{2}B_S + \frac{1}{2}B_T - c + 1 - 1 \\ + & = (I_S + \frac{1}{2}B_S - 1) + (I_T + \frac{1}{2}B_T - 1) \\ + & = a(S) + (I_T + \frac{1}{2}B_T - 1) & \text{induction hypothesis} \\ + & = a(S) + a(T). & \text{base case} + \end{align*} + By the \nameref{sub:area-additive-property}, $S \cup T$ is measurable, + $S \cap T$ is measurable, and + \begin{align*} + a(P) + & = a(S \cup T) \\ + & = a(S) + a(T) - a(S \cap T) \\ + & = a(S) + a(T). & \text{by construction} + \end{align*} + This shows the lattice point area formula is in agreement with our + axiomatic definition of area. + Thus $P(k + 1)$ holds. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - By mathematical induction, it follows for all $n \geq 3$, $P(n)$ is true. + By mathematical induction, it follows for all $n \geq 3$, $P(n)$ is true. -\end{proof} + \end{proof} \subsection{\pending{Exercise 1.7.5}}% \hyperlabel{sub:exercise-1.7.5} -Prove that a triangle whose vertices are lattice points cannot be equilateral. + Prove that a triangle whose vertices are lattice points cannot be equilateral. -[\textit{Hint:} Assume there is such a triangle and compute its area in two -ways, using Exercises 2 and 4.] + [\textit{Hint:} Assume there is such a triangle and compute its area in two + ways, using Exercises 2 and 4.] -\begin{proof} - - Proceed by contradiction. - Let $T$ be an equilateral triangle whose vertices are lattice points. - Assume each side of $T$ has length $a$. - Then $T$ has height $h = (a\sqrt{3}) / 2$. - By \nameref{sub:exercise-1.7.2}, - \begin{equation} - \hyperlabel{sub:exercise-1.7.5-eq1} - \tag{5.1} - a(T) = \frac{1}{2}ah = \frac{a^2\sqrt{3}}{4}. - \end{equation} - Let $I$ and $B$ denote the number of interior and boundary lattice points of - $T$ respectively. - By \nameref{sub:exercise-1.7.4}, - \begin{equation} - \hyperlabel{sub:exercise-1.7.5-eq2} - \tag{5.2} - a(T) = I + \frac{1}{2}B - 1. - \end{equation} - But \eqref{sub:exercise-1.7.5-eq1} is irrational whereas - \eqref{sub:exercise-1.7.5-eq2} is not. - This is a contradiction. - Thus, there is \textit{no} equilateral triangle whose vertices are lattice - points. - -\end{proof} + \begin{proof} + Proceed by contradiction. + Let $T$ be an equilateral triangle whose vertices are lattice points. + Assume each side of $T$ has length $a$. + Then $T$ has height $h = (a\sqrt{3}) / 2$. + By \nameref{sub:exercise-1.7.2}, + \begin{equation} + \hyperlabel{sub:exercise-1.7.5-eq1} + \tag{5.1} + a(T) = \frac{1}{2}ah = \frac{a^2\sqrt{3}}{4}. + \end{equation} + Let $I$ and $B$ denote the number of interior and boundary lattice points of + $T$ respectively. + By \nameref{sub:exercise-1.7.4}, + \begin{equation} + \hyperlabel{sub:exercise-1.7.5-eq2} + \tag{5.2} + a(T) = I + \frac{1}{2}B - 1. + \end{equation} + But \eqref{sub:exercise-1.7.5-eq1} is irrational whereas + \eqref{sub:exercise-1.7.5-eq2} is not. + This is a contradiction. + Thus, there is \textit{no} equilateral triangle whose vertices are lattice + points. + \end{proof} \subsection{\pending{Exercise 1.7.6}}% \hyperlabel{sub:exercise-1.7.6} -Let $A = \{1, 2, 3, 4, 5\}$, and let $\mathscr{M}$ denote the class of all - subsets of $A$. -(There are 32 altogether, counting $A$ itself and the empty set $\emptyset$.) -For each set $S$ in $\mathscr{M}$, let $n(S)$ denote the number of distinct - elements in $S$. -If $S = \{1, 2, 3, 4\}$ and $T = \{3, 4, 5\}$, compute $n(S \cup T)$, - $n(S \cap T)$, $n(S - T)$, and $n(T - S)$. -Prove that the set function $n$ satisfies the first three axioms for area. + Let $A = \{1, 2, 3, 4, 5\}$, and let $\mathscr{M}$ denote the class of all + subsets of $A$. + (There are 32 altogether, counting $A$ itself and the empty set $\emptyset$.) + For each set $S$ in $\mathscr{M}$, let $n(S)$ denote the number of distinct + elements in $S$. + If $S = \{1, 2, 3, 4\}$ and $T = \{3, 4, 5\}$, compute $n(S \cup T)$, + $n(S \cap T)$, $n(S - T)$, and $n(T - S)$. + Prove that the set function $n$ satisfies the first three axioms for area. -\begin{proof} + \begin{proof} - Let $S = \{1, 2, 3, 4\}$ and $T = \{3, 4, 5\}$. - Then - \begin{align*} - n(S \cup T) - & = n(\{1, 2, 3, 4\} \cup \{3, 4, 5\}) \\ - & = n(\{1, 2, 3, 4, 5\}) \\ - & = 5. \\ - n(S \cap T) - & = n(\{1, 2, 3, 4\} \cap \{3, 4, 5\}) \\ - & = n(\{3, 4\}) \\ - & = 2. \\ - n(S - T) - & = n(\{1, 2, 3, 4\} - \{3, 4, 5\}) \\ - & = n(\{1, 2\}) \\ - & = 2. \\ - n(T - S) - & = n(\{3, 4, 5\} - \{1, 2, 3, 4\}) \\ - & = n(\{5\}) \\ - & = 1. - \end{align*} - We now prove $n$ satisfies the first three axioms for area. + Let $S = \{1, 2, 3, 4\}$ and $T = \{3, 4, 5\}$. + Then + \begin{align*} + n(S \cup T) + & = n(\{1, 2, 3, 4\} \cup \{3, 4, 5\}) \\ + & = n(\{1, 2, 3, 4, 5\}) \\ + & = 5. \\ + n(S \cap T) + & = n(\{1, 2, 3, 4\} \cap \{3, 4, 5\}) \\ + & = n(\{3, 4\}) \\ + & = 2. \\ + n(S - T) + & = n(\{1, 2, 3, 4\} - \{3, 4, 5\}) \\ + & = n(\{1, 2\}) \\ + & = 2. \\ + n(T - S) + & = n(\{3, 4, 5\} - \{1, 2, 3, 4\}) \\ + & = n(\{5\}) \\ + & = 1. + \end{align*} + We now prove $n$ satisfies the first three axioms for area. - \paragraph{Nonnegative Property}% + \paragraph{Nonnegative Property}% - $n$ returns the length of some member of $\mathscr{M}$. - By hypothesis, the smallest possible input to $n$ is $\emptyset$. - Since $n(\emptyset) = 0$, it follows $n(S) \geq 0$ for all $S \subset A$. + $n$ returns the length of some member of $\mathscr{M}$. + By hypothesis, the smallest possible input to $n$ is $\emptyset$. + Since $n(\emptyset) = 0$, it follows $n(S) \geq 0$ for all $S \subset A$. - \paragraph{Additive Property}% + \paragraph{Additive Property}% - Let $S$ and $T$ be members of $\mathscr{M}$. - It trivially follows that both $S \cup T$ and $S \cap T$ are in - $\mathscr{M}$. - Consider the value of $n(S \cup T)$. - There are two cases to consider: + Let $S$ and $T$ be members of $\mathscr{M}$. + It trivially follows that both $S \cup T$ and $S \cap T$ are in + $\mathscr{M}$. + Consider the value of $n(S \cup T)$. + There are two cases to consider: - \subparagraph{Case 1}% + \subparagraph{Case 1}% - Suppose $S \cap T = \emptyset$. - That is, there is no common element shared between $S$ and $T$. - Thus - \begin{align*} - n(S \cup T) - & = n(S) + n(T) \\ - & = n(S) + n(T) - 0 \\ - & = n(S) + n(T) - n(S \cap T). - \end{align*} + Suppose $S \cap T = \emptyset$. + That is, there is no common element shared between $S$ and $T$. + Thus + \begin{align*} + n(S \cup T) + & = n(S) + n(T) \\ + & = n(S) + n(T) - 0 \\ + & = n(S) + n(T) - n(S \cap T). + \end{align*} - \subparagraph{Case 2}% + \subparagraph{Case 2}% - Suppose $S \cap T \neq \emptyset$. - Then $n(S) + n(T)$ counts each element of $S \cap T$ twice. - Therefore $n(S \cup T) = n(S) + n(T) - n(S \cap T)$. + Suppose $S \cap T \neq \emptyset$. + Then $n(S) + n(T)$ counts each element of $S \cap T$ twice. + Therefore $n(S \cup T) = n(S) + n(T) - n(S \cap T)$. - \subparagraph{Conclusion}% + \subparagraph{Conclusion}% - These cases are exhaustive and in agreement with one another. - Thus $n(S \cup T) = n(S) + n(T) - n(S \cap T)$. + These cases are exhaustive and in agreement with one another. + Thus $n(S \cup T) = n(S) + n(T) - n(S \cap T)$. - \paragraph{Difference Property}% + \paragraph{Difference Property}% - Suppose $S, T \in \mathscr{M}$ such that $S \subseteq T$. - That is, every member of $S$ is a member of $T$. - By definition, $T - S$ consists of members in $T$ but not in $S$. - Thus $n(T - S) = n(T) - n(S)$. + Suppose $S, T \in \mathscr{M}$ such that $S \subseteq T$. + That is, every member of $S$ is a member of $T$. + By definition, $T - S$ consists of members in $T$ but not in $S$. + Thus $n(T - S) = n(T) - n(S)$. -\end{proof} + \end{proof} \section{Exercises 1.11}% \hyperlabel{sec:exercises-1-11} @@ -1331,451 +1247,450 @@ Prove that the set function $n$ satisfies the first three axioms for area. \subsection{\pending{Exercise 1.11.4}}% \hyperlabel{sub:exercise-1.11.4} -Prove that the greatest-integer function has the properties indicated: + Prove that the greatest-integer function has the properties indicated: \subsubsection{\verified{Exercise 1.11.4a}}% \hyperlabel{ssub:exercise-1.11.4a} -$\floor{x + n} = \floor{x} + n$ for every integer $n$. - -\begin{proof} + $\floor{x + n} = \floor{x} + n$ for every integer $n$. + % FIXUP: padding \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_4a} - Let $x$ be a real number and $n$ an integer. - Let $m = \floor{x + n}$. - By definition of the floor function, $m$ is the unique integer such that - $m \leq x + n < m + 1$. - Then $m - n \leq x < (m - n) + 1$. - That is, $m - n = \floor{x}$. - Rearranging terms we see that $m = \floor{x} + n$ as expected. - -\end{proof} + \begin{proof} + Let $x$ be a real number and $n$ an integer. + Let $m = \floor{x + n}$. + By definition of the floor function, $m$ is the unique integer such that + $m \leq x + n < m + 1$. + Then $m - n \leq x < (m - n) + 1$. + That is, $m - n = \floor{x}$. + Rearranging terms we see that $m = \floor{x} + n$ as expected. + \end{proof} \subsubsection{\verified{Exercise 1.11.4b}}% \hyperlabel{ssub:exercise-1.11.4b} -$\floor{-x} = - \begin{cases} - -\floor{x} & \text{if } x \text{ is an integer}, \\ - -\floor{x} - 1 & \text{otherwise}. - \end{cases}$ + $\floor{-x} = + \begin{cases} + -\floor{x} & \text{if } x \text{ is an integer}, \\ + -\floor{x} - 1 & \text{otherwise}. + \end{cases}$ -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Apostol/Chapter\_1\_11} + % FIXUP: padding + \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_4b\_1} \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_4b\_2} - There are two cases to consider: + \begin{proof} - \paragraph{Case 1}% + There are two cases to consider: - Suppose $x$ is an integer. - Then $x = \floor{x}$ and $-x = \floor{-x}$. - It immediately follows that $$\floor{-x} = -x = -\floor{x}.$$ + \paragraph{Case 1}% - \paragraph{Case 2}% + Suppose $x$ is an integer. + Then $x = \floor{x}$ and $-x = \floor{-x}$. + It immediately follows that $$\floor{-x} = -x = -\floor{x}.$$ - Suppose $x$ is not an integer. - Let $m = \floor{-x}$. - By definition of the floor function, $m$ is the unique integer such that - $m \leq -x < m + 1$. - Equivalently, $-m - 1 < x \leq -m$. - Since $x$ is not an integer, it follows $-m - 1 \leq x < -m$. - Then, by definition of the floor function, $\floor{x} = -m - 1$. - Solving for $m$ yields $$\floor{-x} = m = -\floor{x} - 1.$$ + \paragraph{Case 2}% - \paragraph{Conclusion}% + Suppose $x$ is not an integer. + Let $m = \floor{-x}$. + By definition of the floor function, $m$ is the unique integer such that + $m \leq -x < m + 1$. + Equivalently, $-m - 1 < x \leq -m$. + Since $x$ is not an integer, it follows $-m - 1 \leq x < -m$. + Then, by definition of the floor function, $\floor{x} = -m - 1$. + Solving for $m$ yields $$\floor{-x} = m = -\floor{x} - 1.$$ - The above two cases are exhaustive. Thus - $$\floor{-x} = - \begin{cases} - -\floor{x} & \text{if } x \text{ is an integer}, \\ - -\floor{x} - 1 & \text{otherwise}. - \end{cases}$$ + \paragraph{Conclusion}% -\end{proof} + The above two cases are exhaustive. Thus + $$\floor{-x} = + \begin{cases} + -\floor{x} & \text{if } x \text{ is an integer}, \\ + -\floor{x} - 1 & \text{otherwise}. + \end{cases}$$ + + \end{proof} \subsubsection{\verified{Exercise 1.11.4c}}% \hyperlabel{ssub:exercise-1.11.4c} -$\floor{x + y} = \floor{x} + \floor{y}$ or $\floor{x} + \floor{y} + 1$. - -\begin{proof} + $\floor{x + y} = \floor{x} + \floor{y}$ or $\floor{x} + \floor{y} + 1$. + % FIXUP: padding \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_4c} - Rewrite $x$ and $y$ as the sum of their floor and fractional components: - $x = \floor{x} + \{x\}$ and $y = \floor{y} + \{y\}$. - Now - \begin{align} - \floor{x + y} - & = \floor{\floor{x} + \{x\} + \floor{y} + \{y\}} \nonumber \\ - & = \floor{\floor{x} + \floor{y} + \{x\} + \{y\}} \nonumber \\ - & = \floor{x} + \floor{y} + \floor{\{x\} + \{y\}} - & \textref{ssub:exercise-1.11.4a} \hyperlabel{ssub:exercise-1.11.4c-eq1} - \end{align} - There are two cases to consider: + \begin{proof} - \paragraph{Case 1}% + Rewrite $x$ and $y$ as the sum of their floor and fractional components: + $x = \floor{x} + \{x\}$ and $y = \floor{y} + \{y\}$. + Now + \begin{align} + \floor{x + y} + & = \floor{\floor{x} + \{x\} + \floor{y} + \{y\}} \nonumber \\ + & = \floor{\floor{x} + \floor{y} + \{x\} + \{y\}} \nonumber \\ + & = \floor{x} + \floor{y} + \floor{\{x\} + \{y\}} + & \textref{ssub:exercise-1.11.4a} + \hyperlabel{ssub:exercise-1.11.4c-eq1} + \end{align} + There are two cases to consider: - Suppose $\{x\} + \{y\} < 1$. - Then $\floor{\{x\} + \{y\}} = 0$. - Substituting this value into \eqref{ssub:exercise-1.11.4c-eq1} yields - $$\floor{x + y} = \floor{x} + \floor{y}.$$ + \paragraph{Case 1}% - \paragraph{Case 2}% + Suppose $\{x\} + \{y\} < 1$. + Then $\floor{\{x\} + \{y\}} = 0$. + Substituting this value into \eqref{ssub:exercise-1.11.4c-eq1} yields + $$\floor{x + y} = \floor{x} + \floor{y}.$$ - Suppose $\{x\} + \{y\} \geq 1$. - Because $\{x\}$ and $\{y\}$ are both less than $1$, $\{x\} + \{y\} < 2$. - Thus $\floor{\{x\} + \{y\}} = 1$. - Substituting this value into \eqref{ssub:exercise-1.11.4c-eq1} yields - $$\floor{x + y} = \floor{x} + \floor{y} + 1.$$ + \paragraph{Case 2}% - \paragraph{Conclusion}% + Suppose $\{x\} + \{y\} \geq 1$. + Because $\{x\}$ and $\{y\}$ are both less than $1$, $\{x\} + \{y\} < 2$. + Thus $\floor{\{x\} + \{y\}} = 1$. + Substituting this value into \eqref{ssub:exercise-1.11.4c-eq1} yields + $$\floor{x + y} = \floor{x} + \floor{y} + 1.$$ - Since the above two cases are exhaustive, it follows - $\floor{x + y} = \floor{x} + \floor{y}$ or $\floor{x} + \floor{y} + 1$. + \paragraph{Conclusion}% -\end{proof} + Since the above two cases are exhaustive, it follows + $\floor{x + y} = \floor{x} + \floor{y}$ or $\floor{x} + \floor{y} + 1$. + + \end{proof} \subsubsection{\pending{Exercise 1.11.4d}}% \hyperlabel{ssub:exercise-1.11.4d} -$\floor{2x} = \floor{x} + \floor{x + \frac{1}{2}}.$ - -\begin{proof} + $\floor{2x} = \floor{x} + \floor{x + \frac{1}{2}}.$ + % FIXUP: padding \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_4d} - This is immediately proven by applying \nameref{sub:hermites-identity}. - -\end{proof} + \begin{proof} + This is immediately proven by applying \nameref{sub:hermites-identity}. + \end{proof} \subsubsection{\pending{Exercise 1.11.4e}}% \hyperlabel{ssub:exercise-1.11.4e} -$\floor{3x} = \floor{x} + \floor{x + \frac{1}{3}} + \floor{x + \frac{2}{3}}.$ - -\begin{proof} + $\floor{3x} = \floor{x} + \floor{x + \frac{1}{3}} + \floor{x + \frac{2}{3}}.$ + % FIXUP: padding \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_4e} - This is immediately proven by applying \nameref{sub:hermites-identity}. - -\end{proof} + \begin{proof} + This is immediately proven by applying \nameref{sub:hermites-identity}. + \end{proof} \subsection{\pending{Hermite's Identity}}% \hyperlabel{sub:hermites-identity} \hyperlabel{sub:exercise-1.11.5} -The formulas in Exercises 4(d) and 4(e) suggest a generalization for - $\floor{nx}$. -State and prove such a generalization. - -\begin{proof} + The formulas in Exercises 4(d) and 4(e) suggest a generalization for + $\floor{nx}$. + State and prove such a generalization. + % FIXUP: padding \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_5} - We prove that for all natural numbers $n$ and real numbers $x$, the following - identity holds: - \begin{equation} - \hyperlabel{sub:exercise-1.11.5-eq1} - \floor{nx} = \sum_{i=0}^{n-1} \floor{x + \frac{i}{n}} - \end{equation} - By definition of the floor function, $x = \floor{x} + r$ for some - $r \in \ico{0}{1}$. - Define $S$ as the partition of non-overlapping subintervals - $$\ico{0}{\frac{1}{n}}, \ico{\frac{1}{n}}{\frac{2}{n}}, \ldots, - \ico{\frac{n-1}{n}}{1}.$$ - By construction, $\cup\; S = \ico{0}{1}$. - Therefore there exists some $j \in \mathbb{N}$ such that - \begin{equation} - \hyperlabel{sub:exercise-1.11.5-eq2} - r \in \ico{\frac{j}{n}}{\frac{j+1}{n}}. - \end{equation} - With these definitions established, we now show the left- and right-hand sides - of \eqref{sub:exercise-1.11.5-eq1} evaluate to the same number. + \begin{proof} - \paragraph{Left-Hand Side}% - - Consider the left-hand side of identity \eqref{sub:exercise-1.11.5-eq1}. - By \eqref{sub:exercise-1.11.5-eq2}, $nr \in \ico{j}{j + 1}$. - Therefore $\floor{nr} = j$. - Thus - \begin{align} - \floor{nx} - & = \floor{n(\floor{x} + r)} \nonumber \\ - & = \floor{n\floor{x} + nr} \nonumber \\ - & = \floor{n\floor{x}} + \floor{nr}. \nonumber - & \textref{ssub:exercise-1.11.4a} \\ - & = \floor{n\floor{x}} + j \nonumber \\ - & = n\floor{x} + j. \hyperlabel{sub:exercise-1.11.5-eq3} - \end{align} - - \paragraph{Right-Hand Side}% - - Now consider the right-hand side of identity - \eqref{sub:exercise-1.11.5-eq1}. - We note each summand, by construction, is the floor of $x$ added to a - nonnegative number less than one. - Therefore each summand contributes either $\floor{x}$ or $\floor{x} + 1$ to - the total. - Letting $z$ denote the number of summands that contribute $\floor{x} + 1$, - we have + We prove that for all natural numbers $n$ and real numbers $x$, the + following identity holds: \begin{equation} - \hyperlabel{sub:exercise-1.11.5-eq4} - \sum_{i=0}^{n-1} \floor{x + \frac{i}{n}} = n\floor{x} + z. + \hyperlabel{sub:exercise-1.11.5-eq1} + \floor{nx} = \sum_{i=0}^{n-1} \floor{x + \frac{i}{n}} \end{equation} - The value of $z$ corresponds to the number of indices $i$ that satisfy - $$\frac{i}{n} \geq 1 - r.$$ - By \eqref{sub:exercise-1.11.5-eq2}, it follows - \begin{align*} - 1 - r - & \in \ioc{1 - \frac{j+1}{n}}{1-\frac{j}{n}} \\ - & = \ioc{\frac{n - j - 1}{n}}{\frac{n - j}{n}}. - \end{align*} - Thus we can determine the value of $z$ by instead counting the number of - indices $i$ that satisfy $$\frac{i}{n} \geq \frac{n - j}{n}.$$ - Rearranging terms, we see that $i \geq n - j$ holds for - $z = (n - 1) - (n - j) + 1 = j$ of the $n$ summands. - Substituting the value of $z$ into \eqref{sub:exercise-1.11.5-eq4} yields + By definition of the floor function, $x = \floor{x} + r$ for some + $r \in \ico{0}{1}$. + Define $S$ as the partition of non-overlapping subintervals + $$\ico{0}{\frac{1}{n}}, \ico{\frac{1}{n}}{\frac{2}{n}}, \ldots, + \ico{\frac{n-1}{n}}{1}.$$ + By construction, $\cup\; S = \ico{0}{1}$. + Therefore there exists some $j \in \mathbb{N}$ such that \begin{equation} - \hyperlabel{sub:exercise-1.11.5-eq5} - \sum_{i=0}^{n-1} \floor{x + \frac{i}{n}} = n\floor{x} + j. + \hyperlabel{sub:exercise-1.11.5-eq2} + r \in \ico{\frac{j}{n}}{\frac{j+1}{n}}. \end{equation} + With these definitions established, we now show the left- and right-hand + sides of \eqref{sub:exercise-1.11.5-eq1} evaluate to the same number. - \paragraph{Conclusion}% + \paragraph{Left-Hand Side}% - Since \eqref{sub:exercise-1.11.5-eq3} and \eqref{sub:exercise-1.11.5-eq5} - agree with one another, it follows identity - \eqref{sub:exercise-1.11.5-eq1} holds. + Consider the left-hand side of identity \eqref{sub:exercise-1.11.5-eq1}. + By \eqref{sub:exercise-1.11.5-eq2}, $nr \in \ico{j}{j + 1}$. + Therefore $\floor{nr} = j$. + Thus + \begin{align} + \floor{nx} + & = \floor{n(\floor{x} + r)} \nonumber \\ + & = \floor{n\floor{x} + nr} \nonumber \\ + & = \floor{n\floor{x}} + \floor{nr}. \nonumber + & \textref{ssub:exercise-1.11.4a} \\ + & = \floor{n\floor{x}} + j \nonumber \\ + & = n\floor{x} + j. \hyperlabel{sub:exercise-1.11.5-eq3} + \end{align} -\end{proof} + \paragraph{Right-Hand Side}% + + Now consider the right-hand side of identity + \eqref{sub:exercise-1.11.5-eq1}. + We note each summand, by construction, is the floor of $x$ added to a + nonnegative number less than one. + Therefore each summand contributes either $\floor{x}$ or $\floor{x} + 1$ + to the total. + Letting $z$ denote the number of summands that contribute $\floor{x} + 1$, + we have + \begin{equation} + \hyperlabel{sub:exercise-1.11.5-eq4} + \sum_{i=0}^{n-1} \floor{x + \frac{i}{n}} = n\floor{x} + z. + \end{equation} + The value of $z$ corresponds to the number of indices $i$ that satisfy + $$\frac{i}{n} \geq 1 - r.$$ + By \eqref{sub:exercise-1.11.5-eq2}, it follows + \begin{align*} + 1 - r + & \in \ioc{1 - \frac{j+1}{n}}{1-\frac{j}{n}} \\ + & = \ioc{\frac{n - j - 1}{n}}{\frac{n - j}{n}}. + \end{align*} + Thus we can determine the value of $z$ by instead counting the number of + indices $i$ that satisfy $$\frac{i}{n} \geq \frac{n - j}{n}.$$ + Rearranging terms, we see that $i \geq n - j$ holds for + $z = (n - 1) - (n - j) + 1 = j$ of the $n$ summands. + Substituting the value of $z$ into \eqref{sub:exercise-1.11.5-eq4} yields + \begin{equation} + \hyperlabel{sub:exercise-1.11.5-eq5} + \sum_{i=0}^{n-1} \floor{x + \frac{i}{n}} = n\floor{x} + j. + \end{equation} + + \paragraph{Conclusion}% + + Since \eqref{sub:exercise-1.11.5-eq3} and \eqref{sub:exercise-1.11.5-eq5} + agree with one another, it follows identity + \eqref{sub:exercise-1.11.5-eq1} holds. + + \end{proof} \subsection{\pending{Exercise 1.11.6}}% \hyperlabel{sub:exercise-1.11.6} -Recall that a lattice point $(x, y)$ in the plane is one whose coordinates are - integers. -Let $f$ be a nonnegative function whose domain is the interval $[a, b]$, where - $a$ and $b$ are integers, $a < b$. -Let $S$ denote the set of points $(x, y)$ satisfying $a \leq x \leq b$, - $0 < y \leq f(x)$. -Prove that the number of lattice points in $S$ is equal to the sum - $$\sum_{n=a}^b \floor{f(n)}.$$ + Recall that a lattice point $(x, y)$ in the plane is one whose coordinates are + integers. + Let $f$ be a nonnegative function whose domain is the interval $[a, b]$, where + $a$ and $b$ are integers, $a < b$. + Let $S$ denote the set of points $(x, y)$ satisfying $a \leq x \leq b$, + $0 < y \leq f(x)$. + Prove that the number of lattice points in $S$ is equal to the sum + $$\sum_{n=a}^b \floor{f(n)}.$$ -\begin{proof} + \begin{proof} - Let $i = a, \ldots, b$ and define $S_i = \mathbb{N} \cap \ioc{0}{f(i)}$. - By construction, the number of lattice points in $S$ is - \begin{equation} - \hyperlabel{sub:exercise-1.11.6-eq1} - \sum_{n = a}^b \abs{S_n}. - \end{equation} - All that remains is to show $\abs{S_i} = \floor{f(i)}$. - There are two cases to consider: + Let $i = a, \ldots, b$ and define $S_i = \mathbb{N} \cap \ioc{0}{f(i)}$. + By construction, the number of lattice points in $S$ is + \begin{equation} + \hyperlabel{sub:exercise-1.11.6-eq1} + \sum_{n = a}^b \abs{S_n}. + \end{equation} + All that remains is to show $\abs{S_i} = \floor{f(i)}$. + There are two cases to consider: - \paragraph{Case 1}% + \paragraph{Case 1}% - Suppose $f(i)$ is an integer. - Then the number of integers in $\ioc{0}{f(i)}$ is $f(i) = \floor{f(i)}$. + Suppose $f(i)$ is an integer. + Then the number of integers in $\ioc{0}{f(i)}$ is $f(i) = \floor{f(i)}$. - \paragraph{Case 2}% + \paragraph{Case 2}% - Suppose $f(i)$ is not an integer. - Then the number of integers in $\ioc{0}{f(i)}$ is the same as that of - $\ioc{0}{\floor{f(i)}}$. - Once again, that number is $\floor{f(i)}$. + Suppose $f(i)$ is not an integer. + Then the number of integers in $\ioc{0}{f(i)}$ is the same as that of + $\ioc{0}{\floor{f(i)}}$. + Once again, that number is $\floor{f(i)}$. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - By cases 1 and 2, $\abs{S_i} = \floor{f(i)}$. - Substituting this identity into \eqref{sub:exercise-1.11.6-eq1} finishes the - proof. + By cases 1 and 2, $\abs{S_i} = \floor{f(i)}$. + Substituting this identity into \eqref{sub:exercise-1.11.6-eq1} finishes + the proof. -\end{proof} + \end{proof} \subsection{\pending{Exercise 1.11.7}}% \hyperlabel{sub:exercise-1.11.7} -If $a$ and $b$ are positive integers with no common factor, we have the formula - $$\sum_{n=1}^{b-1} \floor{\frac{na}{b}} = \frac{(a - 1)(b - 1)}{2}.$$ -When $b = 1$, the sum on the left is understood to be $0$. + If $a$ and $b$ are positive integers with no common factor, we have the + formula + $$\sum_{n=1}^{b-1} \floor{\frac{na}{b}} = \frac{(a - 1)(b - 1)}{2}.$$ + When $b = 1$, the sum on the left is understood to be $0$. -\begin{note} - When $b = 1$, the proofs of (a) and (b) are trivial. - We continue under the assumption $b > 1$. -\end{note} + \begin{note} + When $b = 1$, the proofs of (a) and (b) are trivial. + We continue under the assumption $b > 1$. + \end{note} \subsubsection{\pending{Exercise 1.11.7a}}% \hyperlabel{ssub:exercise-1.11.7a} -Derive this result by a geometric argument, counting lattice points in a right - triangle. + Derive this result by a geometric argument, counting lattice points in a right + triangle. -\begin{proof} + \begin{proof} - Let $f \colon [1, b - 1] \rightarrow \mathbb{R}$ be given by $f(x) = ax / b$. - Let $S$ denote the set of points $(x, y)$ satisfying $1 \leq x \leq b - 1$, - $0 < y \leq f(x)$. - By \nameref{sub:exercise-1.11.6}, the number of lattice points of $S$ is equal - to the sum - \begin{equation} - \hyperlabel{ssub:exercise-1.11.7a-eq1} - \sum_{n=1}^{b-1} \floor{f(n)} = \sum_{n=1}^{b-1} \floor{\frac{na}{b}}. - \end{equation} - Define $T$ to be the triangle of width $w = b$ and height $h = f(b) = a$ - as $$T = \{ (x, y) : 0 < x < b, 0 < y \leq f(x) \}.$$ - By construction, $T$ does not introduce any additional lattice points. - Thus $S$ and $T$ have the same number of lattice points. - Let $H_L$ denote the number of boundary points on $T$'s hypotenuse. - We prove that (i) $H_L = 2$ and (ii) that $T$ has $\frac{(a - 1)(b - 1)}{2}$ - lattice points. - - \paragraph{(i)}% - \hyperlabel{par:exercise-1.11.7a-i} - - Consider the line $L$ overlapping the hypotenuse of $T$. - By construction, $T$'s hypotenuse has endpoints $(0, 0)$ and $(b, a)$. - By hypothesis, $a$ and $b$ are positive, excluding the possibility of $L$ - being vertical. - Define the slope of $L$ as $$m = \frac{a}{b}.$$ - $H_L$ coincides with the number of indices $i = 0, \ldots, b$ such that - $(i, i * m)$ is a lattice point. - But $a$ and $b$ are coprime by hypothesis and $i \leq b$. - Thus $i * m$ is an integer if and only if $i = 0$ or $i = b$. - Thus $H_L = 2$. - - \paragraph{(ii)}% - - Next we count the number of lattice points in $T$. - Let $R$ be the overlapping retangle of width $w$ and height $h$, situated - with bottom-left corner at $(0, 0)$. - Let $I_R$ denote the number of interior lattice points of $R$. - Let $I_T$ and $B_T$ denote the interior and boundary lattice points of $T$ - respectively. - By \nameref{ssub:exercise-1.7.4b-eq2}, - \begin{align} - I_T - & = \frac{1}{2}(I_R - (H_L - 2)) \nonumber \\ - & = \frac{1}{2}(I_R - (2 - 2)) - & \textref{par:exercise-1.11.7a-i} \nonumber \\ - & = \frac{1}{2}I_R. & \hyperlabel{ssub:exercise-1.11.7a-eq2} - \end{align} - Furthermore, since both the adjacent and opposite side of $T$ are not - included in $T$ and there exist no lattice points on $T$'s hypotenuse - besides the endpoints, it follows + Let $f \colon [1, b - 1] \rightarrow \mathbb{R}$ be given by + $f(x) = ax / b$. + Let $S$ denote the set of points $(x, y)$ satisfying $1 \leq x \leq b - 1$, + $0 < y \leq f(x)$. + By \nameref{sub:exercise-1.11.6}, the number of lattice points of $S$ is + equal to the sum \begin{equation} - \hyperlabel{ssub:exercise-1.11.7a-eq3} - B_T = 0. + \hyperlabel{ssub:exercise-1.11.7a-eq1} + \sum_{n=1}^{b-1} \floor{f(n)} = \sum_{n=1}^{b-1} \floor{\frac{na}{b}}. \end{equation} - Thus the number of lattice points of $T$ equals - \begin{align} - I_T + B_T - & = I_T & \eqref{ssub:exercise-1.11.7a-eq3} \nonumber \\ - & = \frac{1}{2}I_R & \eqref{ssub:exercise-1.11.7a-eq2} \nonumber \\ - & = \frac{(b - 1)(a - 1)}{2}. - & \textref{ssub:exercise-1.7.4a} \hyperlabel{ssub:exercise-1.11.7a-eq4} - \end{align} + Define $T$ to be the triangle of width $w = b$ and height $h = f(b) = a$ + as $$T = \{ (x, y) : 0 < x < b, 0 < y \leq f(x) \}.$$ + By construction, $T$ does not introduce any additional lattice points. + Thus $S$ and $T$ have the same number of lattice points. + Let $H_L$ denote the number of boundary points on $T$'s hypotenuse. + We prove that (i) $H_L = 2$ and (ii) that $T$ has $\frac{(a - 1)(b - 1)}{2}$ + lattice points. - \paragraph{Conclusion}% + \paragraph{(i)}% + \hyperlabel{par:exercise-1.11.7a-i} - By \eqref{ssub:exercise-1.11.7a-eq1} the number of lattice points of $S$ is - equal to the sum $$\sum_{n=1}^{b-1} \floor{\frac{na}{b}}.$$ - But the number of lattice points of $S$ is the same as that of $T$. - By \eqref{ssub:exercise-1.11.7a-eq4}, the number of lattice points in $T$ is - equal to $$\frac{(b - 1)(a - 1)}{2}.$$ - Thus $$\sum_{n=1}^{b-1} \floor{\frac{na}{b}} = \frac{(a - 1)(b - 1)}{2}.$$ + Consider the line $L$ overlapping the hypotenuse of $T$. + By construction, $T$'s hypotenuse has endpoints $(0, 0)$ and $(b, a)$. + By hypothesis, $a$ and $b$ are positive, excluding the possibility of $L$ + being vertical. + Define the slope of $L$ as $$m = \frac{a}{b}.$$ + $H_L$ coincides with the number of indices $i = 0, \ldots, b$ such that + $(i, i * m)$ is a lattice point. + But $a$ and $b$ are coprime by hypothesis and $i \leq b$. + Thus $i * m$ is an integer if and only if $i = 0$ or $i = b$. + Thus $H_L = 2$. -\end{proof} + \paragraph{(ii)}% + + Next we count the number of lattice points in $T$. + Let $R$ be the overlapping retangle of width $w$ and height $h$, situated + with bottom-left corner at $(0, 0)$. + Let $I_R$ denote the number of interior lattice points of $R$. + Let $I_T$ and $B_T$ denote the interior and boundary lattice points of $T$ + respectively. + By \nameref{ssub:exercise-1.7.4b-eq2}, + \begin{align} + I_T + & = \frac{1}{2}(I_R - (H_L - 2)) \nonumber \\ + & = \frac{1}{2}(I_R - (2 - 2)) + & \textref{par:exercise-1.11.7a-i} \nonumber \\ + & = \frac{1}{2}I_R. & \hyperlabel{ssub:exercise-1.11.7a-eq2} + \end{align} + Furthermore, since both the adjacent and opposite side of $T$ are not + included in $T$ and there exist no lattice points on $T$'s hypotenuse + besides the endpoints, it follows + \begin{equation} + \hyperlabel{ssub:exercise-1.11.7a-eq3} + B_T = 0. + \end{equation} + Thus the number of lattice points of $T$ equals + \begin{align} + I_T + B_T + & = I_T & \eqref{ssub:exercise-1.11.7a-eq3} \nonumber \\ + & = \frac{1}{2}I_R & \eqref{ssub:exercise-1.11.7a-eq2} \nonumber \\ + & = \frac{(b - 1)(a - 1)}{2}. + & \textref{ssub:exercise-1.7.4a} + \hyperlabel{ssub:exercise-1.11.7a-eq4} + \end{align} + + \paragraph{Conclusion}% + + By \eqref{ssub:exercise-1.11.7a-eq1} the number of lattice points of $S$ + is equal to the sum $$\sum_{n=1}^{b-1} \floor{\frac{na}{b}}.$$ + But the number of lattice points of $S$ is the same as that of $T$. + By \eqref{ssub:exercise-1.11.7a-eq4}, the number of lattice points in $T$ + is equal to $$\frac{(b - 1)(a - 1)}{2}.$$ + Thus $$\sum_{n=1}^{b-1} \floor{\frac{na}{b}} = \frac{(a - 1)(b - 1)}{2}.$$ + + \end{proof} \subsubsection{\pending{Exercise 1.11.7b}}% \hyperlabel{ssub:exercise-1.11.7b} -Derive the result analytically as follows: -By changing the index of summation, note that - $\sum_{n=1}^{b-1} \floor{na / b} = \sum_{n=1}^{b-1} \floor{a(b - n) / b}$. -Now apply Exercises 4(a) and (b) to the bracket on the right. - -\begin{proof} + Derive the result analytically as follows: + By changing the index of summation, note that + $\sum_{n=1}^{b-1} \floor{na / b} = \sum_{n=1}^{b-1} \floor{a(b - n) / b}$. + Now apply Exercises 4(a) and (b) to the bracket on the right. + % FIXUP: padding \code{Bookshelf/Apostol/Chapter\_1\_11} {Apostol.Chapter\_1\_11.exercise\_7b} - Let $n = 1, \ldots, b - 1$. - By hypothesis, $a$ and $b$ are coprime. - Furthermore, $n < b$ for all values of $n$. - Thus $an / b$ is not an integer. - By \nameref{ssub:exercise-1.11.4b}, - \begin{equation} - \hyperlabel{ssub:exercise-1.11.7b-eq1} - \floor{-\frac{an}{b}} = -\floor{\frac{an}{b}} - 1. - \end{equation} - Consider the following: - \begin{align*} - \sum_{n=1}^{b-1} \floor{\frac{na}{b}} - & = \sum_{n=1}^{b-1} \floor{\frac{a(b - n)}{b}} \\ - & = \sum_{n=1}^{b-1} \floor{\frac{ab - an}{b}} \\ - & = \sum_{n=1}^{b-1} \floor{-\frac{an}{b} + a} \\ - & = \sum_{n=1}^{b-1} \floor{-\frac{an}{b}} + a. - & \textref{ssub:exercise-1.11.4a} \\ - & = \sum_{n=1}^{b-1} -\floor{\frac{an}{b}} - 1 + a - & \eqref{ssub:exercise-1.11.7b-eq1} \\ - & = -\sum_{n=1}^{b-1} \floor{\frac{an}{b}} - \sum_{n=1}^{b-1} 1 + - \sum_{n=1}^{b-1} a \\ - & = -\sum_{n=1}^{b-1} \floor{\frac{an}{b}} - (b - 1) + a(b - 1). - \end{align*} - Rearranging the above yields - $$2\sum_{n=1}^{b-1} \floor{\frac{an}{b}} = (a - 1)(b - 1).$$ - Dividing both sides of the above identity concludes the proof. - -\end{proof} + \begin{proof} + Let $n = 1, \ldots, b - 1$. + By hypothesis, $a$ and $b$ are coprime. + Furthermore, $n < b$ for all values of $n$. + Thus $an / b$ is not an integer. + By \nameref{ssub:exercise-1.11.4b}, + \begin{equation} + \hyperlabel{ssub:exercise-1.11.7b-eq1} + \floor{-\frac{an}{b}} = -\floor{\frac{an}{b}} - 1. + \end{equation} + Consider the following: + \begin{align*} + \sum_{n=1}^{b-1} \floor{\frac{na}{b}} + & = \sum_{n=1}^{b-1} \floor{\frac{a(b - n)}{b}} \\ + & = \sum_{n=1}^{b-1} \floor{\frac{ab - an}{b}} \\ + & = \sum_{n=1}^{b-1} \floor{-\frac{an}{b} + a} \\ + & = \sum_{n=1}^{b-1} \floor{-\frac{an}{b}} + a. + & \textref{ssub:exercise-1.11.4a} \\ + & = \sum_{n=1}^{b-1} -\floor{\frac{an}{b}} - 1 + a + & \eqref{ssub:exercise-1.11.7b-eq1} \\ + & = -\sum_{n=1}^{b-1} \floor{\frac{an}{b}} - \sum_{n=1}^{b-1} 1 + + \sum_{n=1}^{b-1} a \\ + & = -\sum_{n=1}^{b-1} \floor{\frac{an}{b}} - (b - 1) + a(b - 1). + \end{align*} + Rearranging the above yields + $$2\sum_{n=1}^{b-1} \floor{\frac{an}{b}} = (a - 1)(b - 1).$$ + Dividing both sides of the above identity concludes the proof. + \end{proof} \subsection{\pending{Exercise 1.11.8}}% \hyperlabel{sub:exercise-1.11.8} -Let $S$ be a set of points on the real line. -Let $\mathcal{X}_S$ denote the \nameref{ref:characteristic-function} of $S$. -Let $f$ be a \nameref{ref:step-function} which takes the constant value - $c_k$ on the $k$th open subinterval $I_k$ of some partition of an interval - $[a, b]$. -Prove that for each $x$ in the union $I_1 \cup I_2 \cup \cdots \cup I_n$ we have - $$f(x) = \sum_{k=1}^n c_k\mathcal{X}_{I_k}(x).$$ -This property is described by saying that every step function is a linear - combination of characteristic functions of intervals. + Let $S$ be a set of points on the real line. + Let $\mathcal{X}_S$ denote the \nameref{ref:characteristic-function} of $S$. + Let $f$ be a \nameref{ref:step-function} which takes the constant value + $c_k$ on the $k$th open subinterval $I_k$ of some partition of an interval + $[a, b]$. + Prove that for each $x$ in the union $I_1 \cup I_2 \cup \cdots \cup I_n$ we + have $$f(x) = \sum_{k=1}^n c_k\mathcal{X}_{I_k}(x).$$ + This property is described by saying that every step function is a linear + combination of characteristic functions of intervals. -\begin{proof} - - Let $x \in I_1 \cup I_2 \cup \cdots \cup I_n$ and $N = \{1, \ldots, n\}$. - Let $k \in N$ such that $x \in I_k$. - Consider an arbitrary $j \in N - \{k\}$. - By definition of a nameref{ref:partition}, $I_j \cap I_k = \emptyset$. - That is, $I_j$ and $I_k$ are disjoint for all $j \in N - \{k\}$. - Therefore, by definition of the characteristic function, - $\mathcal{X}_{I_k}(x) = 1$ and $\mathcal{X}_{I_j}(x) = 0$ for all - $j \in N - \{k\}$. - Thus - \begin{align*} - f(x) - & = c_k \\ - & = (c_k)(1) + \sum\nolimits_{j \in N - \{k\}} (c_j)(0) \\ - & = c_k\mathcal{X}_{I_k}(x) + - \sum\nolimits_{j \in N - \{k\}} c_j\mathcal{X}_{I_j}(x) \\ - & = \sum_{k=1}^n c_k\mathcal{X}_{I_k}(x). - \end{align*} - -\end{proof} + \begin{proof} + Let $x \in I_1 \cup I_2 \cup \cdots \cup I_n$ and $N = \{1, \ldots, n\}$. + Let $k \in N$ such that $x \in I_k$. + Consider an arbitrary $j \in N - \{k\}$. + By definition of a nameref{ref:partition}, $I_j \cap I_k = \emptyset$. + That is, $I_j$ and $I_k$ are disjoint for all $j \in N - \{k\}$. + Therefore, by definition of the characteristic function, + $\mathcal{X}_{I_k}(x) = 1$ and $\mathcal{X}_{I_j}(x) = 0$ for all + $j \in N - \{k\}$. + Thus + \begin{align*} + f(x) + & = c_k \\ + & = (c_k)(1) + \sum\nolimits_{j \in N - \{k\}} (c_j)(0) \\ + & = c_k\mathcal{X}_{I_k}(x) + + \sum\nolimits_{j \in N - \{k\}} c_j\mathcal{X}_{I_j}(x) \\ + & = \sum_{k=1}^n c_k\mathcal{X}_{I_k}(x). + \end{align*} + \end{proof} \section{Properties of the Integral of a Step Function}% \hyperlabel{sec:properties-integral-step-function} @@ -1784,309 +1699,285 @@ This property is described by saying that every step function is a linear \hyperlabel{sub:step-additive-property} \hyperlabel{sub:theorem-1.2} -\begin{theorem}[1.2] + \begin{theorem}[1.2] + Let $s$ and $t$ be \nameref{ref:step-function}s on closed interval + $[a, b]$. + Then + $$\int_a^b \left[ s(x) + t(x) \right] \mathop{dx} = + \int_a^b s(x) \mathop{dx} + \int_a^b t(x) \mathop{dx}.$$ + \end{theorem} - Let $s$ and $t$ be \nameref{ref:step-function}s on closed interval - $[a, b]$. - Then - $$\int_a^b \left[ s(x) + t(x) \right] \mathop{dx} = - \int_a^b s(x) \mathop{dx} + \int_a^b t(x) \mathop{dx}.$$ + \begin{proof} + Let $s$ and $t$ be step functions on closed interval $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P_s$ such that $s$ is constant on each open subinterval of $P_s$. + Likewise, there exists a partition $P_t$ such that $t$ is constant on each + open subinterval of $P_t$. + Therefore $s + t$ is a step function with step partition + $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\},$$ the common refinement of + $P_s$ and $P_t$ with subdivision points $x_0$, $x_1$, $\ldots$, $x_n$. -\end{theorem} - -\begin{proof} - - Let $s$ and $t$ be step functions on closed interval $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P_s$ such that $s$ is constant on each open subinterval of $P_s$. - Likewise, there exists a partition $P_t$ such that $t$ is constant on each - open subinterval of $P_t$. - Therefore $s + t$ is a step function with step partition - $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\},$$ the common refinement of - $P_s$ and $P_t$ with subdivision points $x_0$, $x_1$, $\ldots$, $x_n$. - - $s$ and $t$ remain constant on every open subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of - $P$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b \left[ s(x) + t(x) \right] \mathop{dx} - & = \sum_{k=1}^n (s_k + t_k) \cdot (x_k - x_{k-1}) \\ - & = \sum_{k=1}^n \left[ s_k \cdot (x_k - x_{k-1}) + - t_k \cdot (x_k - x_{k-1}) \right] \\ - & = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) + - \sum_{k=1}^n t_k \cdot (x_k - x_{k-1}) \\ - & = \int_a^b s(x) \mathop{dx} + \int_a^b t(x) \mathop{dx}. - \end{align*} - -\end{proof} + $s$ and $t$ remain constant on every open subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P$. + Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of + $P$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b \left[ s(x) + t(x) \right] \mathop{dx} + & = \sum_{k=1}^n (s_k + t_k) \cdot (x_k - x_{k-1}) \\ + & = \sum_{k=1}^n \left[ s_k \cdot (x_k - x_{k-1}) + + t_k \cdot (x_k - x_{k-1}) \right] \\ + & = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) + + \sum_{k=1}^n t_k \cdot (x_k - x_{k-1}) \\ + & = \int_a^b s(x) \mathop{dx} + \int_a^b t(x) \mathop{dx}. + \end{align*} + \end{proof} \subsection{\pending{Homogeneous Property}}% \hyperlabel{sub:step-homogeneous-property} \hyperlabel{sub:theorem-1.3} -\begin{theorem}[1.3] + \begin{theorem}[1.3] + Let $s$ be a \nameref{ref:step-function} on closed interval $[a, b]$. + For every real number $c$, we have + $$\int_a^b c \cdot s(x) \mathop{dx} = c\int_a^b s(x) \mathop{dx}.$$ + \end{theorem} - Let $s$ be a \nameref{ref:step-function} on closed interval $[a, b]$. - For every real number $c$, we have - $$\int_a^b c \cdot s(x) \mathop{dx} = c\int_a^b s(x) \mathop{dx}.$$ - -\end{theorem} - -\begin{proof} - - Let $s$ be a step function on closed interval $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open - subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - Then $c \cdot s$ is a step function with step partition $P$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b c \cdot s(x) \mathop{dx} - & = \sum_{k=1}^n c \cdot s_k \cdot (x_k - x_{k-1}) \\ - & = c \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) \\ - & = c \int_a^b s(x) \mathop{dx}. - \end{align*} - -\end{proof} + \begin{proof} + Let $s$ be a step function on closed interval $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open + subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P$. + Then $c \cdot s$ is a step function with step partition $P$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b c \cdot s(x) \mathop{dx} + & = \sum_{k=1}^n c \cdot s_k \cdot (x_k - x_{k-1}) \\ + & = c \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) \\ + & = c \int_a^b s(x) \mathop{dx}. + \end{align*} + \end{proof} \subsection{\pending{Linearity Property}}% \hyperlabel{sub:step-linearity-property} \hyperlabel{sub:theorem-1.4} -\begin{theorem}[1.4] + \begin{theorem}[1.4] + Let $s$ and $t$ be \nameref{ref:step-function}s on closed interval + $[a, b]$. + For every real $c_1$ and $c_2$, we have + $$\int_a^b \left[ c_1s(x) + c_2t(x) \right] \mathop{dx} = + c_1\int_a^b s(x) \mathop{dx} + c_2\int_a^b t(x) \mathop{dx}.$$ + \end{theorem} - Let $s$ and $t$ be \nameref{ref:step-function}s on closed interval - $[a, b]$. - For every real $c_1$ and $c_2$, we have - $$\int_a^b \left[ c_1s(x) + c_2t(x) \right] \mathop{dx} = - c_1\int_a^b s(x) \mathop{dx} + c_2\int_a^b t(x) \mathop{dx}.$$ - -\end{theorem} - -\begin{proof} - - Let $s$ and $t$ be step functions on closed interval $[a, b]$. - Let $c_1$ and $c_2$ be real numbers. - Then $c_1 \cdot s$ and $c_2 \cdot t$ are step functions. - Then - \begin{align*} - & \int_a^b \left[ c_1s(x) + c_2t(x) \right] \mathop{dx} \\ - & = \int_a^b c_1s(x) \mathop{dx} + \int_a^b c_2t(x) \mathop{dx} - & \textref{sub:step-additive-property} \\ - & = c_1\int_a^b s(x) \mathop{dx} + c_2\int_a^b t(x). \mathop{dx} - & \textref{sub:step-homogeneous-property} - \end{align*} - -\end{proof} + \begin{proof} + Let $s$ and $t$ be step functions on closed interval $[a, b]$. + Let $c_1$ and $c_2$ be real numbers. + Then $c_1 \cdot s$ and $c_2 \cdot t$ are step functions. + Then + \begin{align*} + & \int_a^b \left[ c_1s(x) + c_2t(x) \right] \mathop{dx} \\ + & = \int_a^b c_1s(x) \mathop{dx} + \int_a^b c_2t(x) \mathop{dx} + & \textref{sub:step-additive-property} \\ + & = c_1\int_a^b s(x) \mathop{dx} + c_2\int_a^b t(x). \mathop{dx} + & \textref{sub:step-homogeneous-property} + \end{align*} + \end{proof} \subsection{\pending{Comparison Theorem}}% \hyperlabel{sub:step-comparison-theorem} \hyperlabel{sub:theorem-1.5} -\begin{theorem}[1.5] + \begin{theorem}[1.5] + Let $s$ and $t$ be \nameref{ref:step-function}s on closed interval + $[a, b]$. + If $s(x) < t(x)$ for every $x$ in $[a, b]$, then + $$\int_a^b s(x) \mathop{dx} < \int_a^b t(x) \mathop{dx}.$$ + \end{theorem} - Let $s$ and $t$ be \nameref{ref:step-function}s on closed interval - $[a, b]$. - If $s(x) < t(x)$ for every $x$ in $[a, b]$, then - $$\int_a^b s(x) \mathop{dx} < \int_a^b t(x) \mathop{dx}.$$ + \begin{proof} + Let $s$ and $t$ be step functions on closed interval $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P_s$ such that $s$ is constant on each open subinterval of $P_s$. + Likewise, there exists a partition $P_t$ such that $t$ is constant on each + open subinterval of $P_t$. + Let $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\}$$ be the common + refinement of $P_s$ and $P_t$ with subdivision points $x_0$, $x_1$, + $\ldots$, $x_n$. -\end{theorem} - -\begin{proof} - - Let $s$ and $t$ be step functions on closed interval $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P_s$ such that $s$ is constant on each open subinterval of $P_s$. - Likewise, there exists a partition $P_t$ such that $t$ is constant on each - open subinterval of $P_t$. - Let $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\}$$ be the common refinement - of $P_s$ and $P_t$ with subdivision points $x_0$, $x_1$, $\ldots$, $x_n$. - - By construction, $P$ is a step partition for both $s$ and $t$. - Thus $s$ and $t$ remain constant on every open subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of - $P$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) \\ - & < \sum_{k=1}^n t_k \cdot (x_k - x_{k-1}) & \text{by hypothesis} \\ - & = \int_a^b t(x) \mathop{dx}. - \end{align*} - -\end{proof} + By construction, $P$ is a step partition for both $s$ and $t$. + Thus $s$ and $t$ remain constant on every open subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P$. + Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of + $P$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) \\ + & < \sum_{k=1}^n t_k \cdot (x_k - x_{k-1}) & \text{by hypothesis} \\ + & = \int_a^b t(x) \mathop{dx}. + \end{align*} + \end{proof} \subsection{\pending{Additivity With Respect to the Interval of Integration}}% \hyperlabel{sub:step-additivity-with-respect-interval-integration} \hyperlabel{sub:theorem-1.6} -\begin{theorem}[1.6] + \begin{theorem}[1.6] + Let $a, b, c \in \mathbb{R}$ and $s$ a \nameref{ref:step-function} on the + smallest closed interval containing them. + Then + $$\int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx} + + \int_b^a s(x) \mathop{dx} = 0.$$ + \end{theorem} - Let $a, b, c \in \mathbb{R}$ and $s$ a \nameref{ref:step-function} on the - smallest closed interval containing them. - Then - $$\int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx} + - \int_b^a s(x) \mathop{dx} = 0.$$ + \begin{proof} + WLOG, suppose $a < c < b$ and $s$ be a step function on closed interval + $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P$ such that $s$ is constant on each open subinterval of $P$. -\end{theorem} - -\begin{proof} - - WLOG, suppose $a < c < b$ and $s$ be a step function on closed interval - $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P$ such that $s$ is constant on each open subinterval of $P$. - - Let $Q = \{x_0, x_1, \ldots, x_n\}$ be a refinement of $P$ that includes $c$ - as a subdivision point. - Then $Q$ is a step partition of $s$ and there exists some $0 < i < n$ such - that $x_i = c$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $Q$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n s_k \cdot (x_k - x_{k - 1}) \\ - & = \sum_{k=1}^i s_k \cdot (x_k - x_{k - 1}) + - \sum_{k=i+1}^n s_k \cdot (x_k - x_{k - 1}) \\ - & = \int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx}. - \end{align*} - Rearranging terms shows - \begin{align*} - 0 - & = \int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx} - - \int_a^b s(x) \mathop{dx} \\ - & = \int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx} + - \int_b^a s(x) \mathop{dx}. - \end{align*} - -\end{proof} + Let $Q = \{x_0, x_1, \ldots, x_n\}$ be a refinement of $P$ that includes $c$ + as a subdivision point. + Then $Q$ is a step partition of $s$ and there exists some $0 < i < n$ such + that $x_i = c$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $Q$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n s_k \cdot (x_k - x_{k - 1}) \\ + & = \sum_{k=1}^i s_k \cdot (x_k - x_{k - 1}) + + \sum_{k=i+1}^n s_k \cdot (x_k - x_{k - 1}) \\ + & = \int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx}. + \end{align*} + Rearranging terms shows + \begin{align*} + 0 + & = \int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx} - + \int_a^b s(x) \mathop{dx} \\ + & = \int_a^c s(x) \mathop{dx} + \int_c^b s(x) \mathop{dx} + + \int_b^a s(x) \mathop{dx}. + \end{align*} + \end{proof} \subsection{\pending{Invariance Under Translation}}% \hyperlabel{sub:step-invariance-under-translation} \hyperlabel{sub:theorem-1.7} -\begin{theorem}[1.7] + \begin{theorem}[1.7] + Let $s$ be a step function on closed interval $[a, b]$. + Then + $$\int_a^b s(x) \mathop{dx} = + \int_{a+c}^{b+x} s(x - c) \mathop{dx} \quad\text{for every real } c.$$ + \end{theorem} - Let $s$ be a step function on closed interval $[a, b]$. - Then - $$\int_a^b s(x) \mathop{dx} = - \int_{a+c}^{b+x} s(x - c) \mathop{dx} \quad\text{for every real } c.$$ + \begin{proof} + Let $s$ be a step function on closed interval $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open + subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P$. -\end{theorem} + Let $c$ be a real number. + Then $t(x) = s(x - c)$ is a step function on closed interval + $[a + c, b + c]$ with partition + $Q = \{x_0 + c, x_1 + c, \ldots, x_n + c\}$. + Furthermore, $t$ is constant on each open subinterval of $Q$. + Let $t_k$ denote the value of $t$ on the $k$th open subinterval of $Q$. + By construction, $t_k = s_k$. -\begin{proof} - - Let $s$ be a step function on closed interval $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open - subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - - Let $c$ be a real number. - Then $t(x) = s(x - c)$ is a step function on closed interval $[a + c, b + c]$ - with partition $Q = \{x_0 + c, x_1 + c, \ldots, x_n + c\}$. - Furthermore, $t$ is constant on each open subinterval of $Q$. - Let $t_k$ denote the value of $t$ on the $k$th open subinterval of $Q$. - By construction, $t_k = s_k$. - - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_{a+c}^{b+c} s(x - c) \mathop{dx} - & = \int_{a+c}^{b+c} t(x) \mathop{dx} \\ - & = \sum_{k=1}^n t_k \cdot ((x_k + c) - (x_{k - 1} + c)) \\ - & = \sum_{k=1}^n t_k \cdot (x_k - x_{k - 1}) \\ - & = \sum_{k=1}^n s_k \cdot (x_k - x_{k - 1}) \\ - & = \int_a^b s(x) \mathop{dx}. - \end{align*} - -\end{proof} + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_{a+c}^{b+c} s(x - c) \mathop{dx} + & = \int_{a+c}^{b+c} t(x) \mathop{dx} \\ + & = \sum_{k=1}^n t_k \cdot ((x_k + c) - (x_{k - 1} + c)) \\ + & = \sum_{k=1}^n t_k \cdot (x_k - x_{k - 1}) \\ + & = \sum_{k=1}^n s_k \cdot (x_k - x_{k - 1}) \\ + & = \int_a^b s(x) \mathop{dx}. + \end{align*} + \end{proof} \subsection{\pending{Expansion or Contraction of the Interval of Integration}}% \hyperlabel{sub:step-expansion-contraction-interval-integration} \hyperlabel{sub:theorem-1.8} -\begin{theorem}[1.8] + \begin{theorem}[1.8] + Let $s$ be a step function on closed interval $[a, b]$. + Then + $$\int_{ka}^{kb} s \left( \frac{x}{k} \right) \mathop{dx} = + k \int_a^b s(x) \mathop{dx} \quad\text{for every } k \neq 0.$$ + \end{theorem} - Let $s$ be a step function on closed interval $[a, b]$. - Then - $$\int_{ka}^{kb} s \left( \frac{x}{k} \right) \mathop{dx} = - k \int_a^b s(x) \mathop{dx} \quad\text{for every } k \neq 0.$$ + \begin{proof} -\end{theorem} + Let $s$ be a step function on closed interval $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open + subinterval of $P$. + Let $s_i$ denote the value of $s$ on the $i$th open subinterval of $P$. -\begin{proof} + Let $k \neq 0$ be a real number. + There are two cases to consider: - Let $s$ be a step function on closed interval $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open - subinterval of $P$. - Let $s_i$ denote the value of $s$ on the $i$th open subinterval of $P$. + \paragraph{Case 1}% - Let $k \neq 0$ be a real number. - There are two cases to consider: + Suppose $k > 0$. + Then $t(x) = s(x / k)$ is a step function on closed interval $[ka, kb]$ + with partition $Q = \{kx_0, kx_1, \ldots, kx_n\}$. + Furthermore $t_i = s_i$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_{ka}^{kb} s(x / k) \mathop{dx} + & = \int_{ka}^{kb} t(x) \mathop{dx} \\ + & = \sum_{i=1}^n t_i \cdot (kx_i - kx_{i-1}) \\ + & = k \sum_{i=1}^n t_i \cdot (x_i - x_{i-1}) \\ + & = k \sum_{i=1}^n s_i \cdot(x_i - x_{i-1}) \\ + & = k \int_a^b s(x) \mathop{dx}. + \end{align*} - \paragraph{Case 1}% + \paragraph{Case 2}% - Suppose $k > 0$. - Then $t(x) = s(x / k)$ is a step function on closed interval $[ka, kb]$ - with partition $Q = \{kx_0, kx_1, \ldots, kx_n\}$. - Furthermore $t_i = s_i$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_{ka}^{kb} s(x / k) \mathop{dx} - & = \int_{ka}^{kb} t(x) \mathop{dx} \\ - & = \sum_{i=1}^n t_i \cdot (kx_i - kx_{i-1}) \\ - & = k \sum_{i=1}^n t_i \cdot (x_i - x_{i-1}) \\ - & = k \sum_{i=1}^n s_i \cdot(x_i - x_{i-1}) \\ - & = k \int_a^b s(x) \mathop{dx}. - \end{align*} + Let $k < 0$ be a real number. + Then $t(x) = s(x / k)$ is a step function on closed interval $[kb, ka]$ + with partition $Q = \{kx_n, kx_{n-1}, \ldots, kx_0\}$. + Furthermore $t_i = s_i$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_{ka}^{kb} s(x / k) \mathop{dx} + & = -\int_{kb}^{ka} s(x / k) \mathop{dx} \\ + & = -\int_{kb}^{ka} t(x) \mathop{dx} \\ + & = -\sum_{i=1}^n t_i \cdot (kx_{i-1} - kx_i) \\ + & = -\sum_{i=1}^n s_i \cdot (kx_{i-1} - kx_i) \\ + & = -\sum_{i=1}^n s_i \cdot (-k) \cdot (x_i - x_{i-1}) \\ + & = k \sum_{i=1}^n s_i \cdot (x_i - x_{i-1}) \\ + & = k \int_a^b s(x) \mathop{dx}. + \end{align*} - \paragraph{Case 2}% - - Let $k < 0$ be a real number. - Then $t(x) = s(x / k)$ is a step function on closed interval $[kb, ka]$ - with partition $Q = \{kx_n, kx_{n-1}, \ldots, kx_0\}$. - Furthermore $t_i = s_i$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_{ka}^{kb} s(x / k) \mathop{dx} - & = -\int_{kb}^{ka} s(x / k) \mathop{dx} \\ - & = -\int_{kb}^{ka} t(x) \mathop{dx} \\ - & = -\sum_{i=1}^n t_i \cdot (kx_{i-1} - kx_i) \\ - & = -\sum_{i=1}^n s_i \cdot (kx_{i-1} - kx_i) \\ - & = -\sum_{i=1}^n s_i \cdot (-k) \cdot (x_i - x_{i-1}) \\ - & = k \sum_{i=1}^n s_i \cdot (x_i - x_{i-1}) \\ - & = k \int_a^b s(x) \mathop{dx}. - \end{align*} - -\end{proof} + \end{proof} \subsection{\pending{Reflection Property}}% \hyperlabel{sub:step-reflection-property} -Let $s$ be a step function on closed interval $[a, b]$. -Then - $$\int_a^b s(x) \mathop{dx} = -\int_{-b}^{-a} s(-x) \mathop{dx}.$$ + \begin{theorem} + Let $s$ be a step function on closed interval $[a, b]$. + Then + $$\int_a^b s(x) \mathop{dx} = -\int_{-b}^{-a} s(-x) \mathop{dx}.$$ + \end{theorem} -\begin{proof} - - Let $k = -1$. - By \nameref{sub:step-expansion-contraction-interval-integration}, - $$\int_{-a}^{-b} s \left( \frac{x}{-1} \right) = - -\int_a^b s(x) \mathop{dx}.$$ - Simplifying the left-hand side of the above identity, and multiplying both - sides by $-1$ yields the desired result. - -\end{proof} + \begin{proof} + Let $k = -1$. + By \nameref{sub:step-expansion-contraction-interval-integration}, + $$\int_{-a}^{-b} s \left( \frac{x}{-1} \right) = + -\int_a^b s(x) \mathop{dx}.$$ + Simplifying the left-hand side of the above identity, and multiplying both + sides by $-1$ yields the desired result. + \end{proof} \section{Exercises 1.15}% \hyperlabel{sec:exercises-1.15} @@ -2094,103 +1985,96 @@ Then \subsection{\pending{Exercise 1.15.1}}% \hyperlabel{sub:exercise-1.15.1} -Compute the value of each of the following integrals. + Compute the value of each of the following integrals. \subsubsection{\pending{Exercise 1.15.1a}}% \hyperlabel{ssub:exercise-1.15.1a} -$\int_{-1}^3 \floor{x} \mathop{dx}$. + $\int_{-1}^3 \floor{x} \mathop{dx}$. -\begin{proof} - - Let $s(x) = \floor{x}$ with domain $[-1, 3]$. - By construction, $s$ is a step function with partition - $P = \{-1, 0, 1, 2, 3\} = \{x_0, x_1, x_2, x_3, x_4\}$. - Let $s_k$ denote the constant value $s$ takes on the $k$th open subinterval of - $P$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_{-1}^3 \floor{x} \mathop{dx} - & = \sum_{k=1}^4 s_k \cdot (x_k - x_{k-1}) \\ - & = -1 + 0 + 1 + 2 \\ - & = 2. - \end{align*} - -\end{proof} + \begin{proof} + Let $s(x) = \floor{x}$ with domain $[-1, 3]$. + By construction, $s$ is a step function with partition + $P = \{-1, 0, 1, 2, 3\} = \{x_0, x_1, x_2, x_3, x_4\}$. + Let $s_k$ denote the constant value $s$ takes on the $k$th open subinterval of + $P$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_{-1}^3 \floor{x} \mathop{dx} + & = \sum_{k=1}^4 s_k \cdot (x_k - x_{k-1}) \\ + & = -1 + 0 + 1 + 2 \\ + & = 2. + \end{align*} + \end{proof} \subsubsection{\pending{Exercise 1.15.1c}}% \hyperlabel{ssub:exercise-1.15.1c} -$\int_{-1}^3 \left(\floor{x} + \floor{x + \frac{1}{2}}\right) \mathop{dx}$. + $\int_{-1}^3 \left(\floor{x} + \floor{x + \frac{1}{2}}\right) \mathop{dx}$. -\begin{proof} - - Let $s(x) = \floor{x} + \floor{x + \frac{1}{2}}$ with domain $[-1, 3]$. - By construction, $s$ is a step function with partition - \begin{align*} - P - & = \{-1, -\frac{1}{2}, 0, \frac{1}{2}, 1, \frac{3}{2}, 2, \frac{5}{2}, - 3\} \\ - & = \{x_0, x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8\}. - \end{align*} - Let $s_k$ denote the constant value $s$ takes on the $k$th open subinterval of - $P$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_{-1}^3 \floor{x} + \floor{x + \frac{1}{2}} - & = \sum_{k=1}^8 s_k \cdot (x_k - x_{k-1}) \\ - & = \frac{1}{2} \sum_{k=1}^8 s_k \\ - & = \frac{1}{2} \left( -2 - 1 + 0 + 1 + 2 + 3 + 4 + 5 \right) \\ - & = 6. - \end{align*} - -\end{proof} + \begin{proof} + Let $s(x) = \floor{x} + \floor{x + \frac{1}{2}}$ with domain $[-1, 3]$. + By construction, $s$ is a step function with partition + \begin{align*} + P + & = \{-1, -\frac{1}{2}, 0, \frac{1}{2}, 1, \frac{3}{2}, 2, \frac{5}{2}, + 3\} \\ + & = \{x_0, x_1, x_2, x_3, x_4, x_5, x_6, x_7, x_8\}. + \end{align*} + Let $s_k$ denote the constant value $s$ takes on the $k$th open subinterval of + $P$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_{-1}^3 \floor{x} + \floor{x + \frac{1}{2}} + & = \sum_{k=1}^8 s_k \cdot (x_k - x_{k-1}) \\ + & = \frac{1}{2} \sum_{k=1}^8 s_k \\ + & = \frac{1}{2} \left( -2 - 1 + 0 + 1 + 2 + 3 + 4 + 5 \right) \\ + & = 6. + \end{align*} + \end{proof} \subsubsection{\pending{Exericse 1.15.1e}}% \hyperlabel{ssub:exercise-1.15.1e} -$\int_{-1}^3 \floor{2x} \mathop{dx}$. + $\int_{-1}^3 \floor{2x} \mathop{dx}$. -\begin{proof} - - Let $s(x) = \floor{2x}$. - By \nameref{sub:hermites-identity}, - $s(x) = \floor{x} + \floor{x + \frac{1}{2}}$. - Thus, by \nameref{ssub:exercise-1.15.1c}, - $$\int_{-1}^3 \floor{2x} \mathop{dx} = 6.$$ - -\end{proof} + \begin{proof} + Let $s(x) = \floor{2x}$. + By \nameref{sub:hermites-identity}, + $s(x) = \floor{x} + \floor{x + \frac{1}{2}}$. + Thus, by \nameref{ssub:exercise-1.15.1c}, + $$\int_{-1}^3 \floor{2x} \mathop{dx} = 6.$$ + \end{proof} \subsection{\pending{Exercise 1.15.3}}% \hyperlabel{sub:exercise-1.15.3} -Show that - $\int_a^b \floor{x} \mathop{dx} + \int_a^b \floor{-x} \mathop{dx} = a - b$. + Show that + $\int_a^b \floor{x} \mathop{dx} + \int_a^b \floor{-x} \mathop{dx} = a - b$. -\begin{proof} - - Let $s(x) = \floor{x}$ and $t(x) = \floor{-x}$, both with domain $[a, b]$. - Let $x_1$, $\ldots$, $x_{n-1}$ denote the integers found in interval $(a, b)$. - Then $P = \{x_0, x_1, \ldots, x_n\}$, $x_0 = a$ and $x_n = b$, is a step - \nameref{ref:partition} of both $s$ and $t$. - Let $s_k$ and $t_k$ denote the constant values $s$ and $t$ take on the $k$th - open subinterval of $P$ respectively. - By \nameref{ssub:exercise-1.11.4b}, $\floor{-x} = -\floor{x} - 1$ for all $x$ - in every open subinterval of $P$. - That is, $s_k = -t_k - 1$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b \floor{x} \mathop{dx} + \int_a^b \floor{-x} \mathop{dx} - & = \sum_{k=1}^n s_k (x_k - x_{k-1}) + - \sum_{k=1}^n t_k (x_k - x_{k-1}) \\ - & = \sum_{k=1}^n (x_k - x_{k-1}) \cdot (s_k + t_k) \\ - & = \sum_{k=1}^n (x_k - x_{k-1}) \cdot (-t_k - 1 + t_k) \\ - & = \sum_{k=1}^n (x_{k-1} - x_k) \\ - & = x_0 - x_n \\ - & = a - b. - \end{align*} - -\end{proof} + \begin{proof} + Let $s(x) = \floor{x}$ and $t(x) = \floor{-x}$, both with domain $[a, b]$. + Let $x_1$, $\ldots$, $x_{n-1}$ denote the integers found in interval + $(a, b)$. + Then $P = \{x_0, x_1, \ldots, x_n\}$, $x_0 = a$ and $x_n = b$, is a step + \nameref{ref:partition} of both $s$ and $t$. + Let $s_k$ and $t_k$ denote the constant values $s$ and $t$ take on the $k$th + open subinterval of $P$ respectively. + By \nameref{ssub:exercise-1.11.4b}, $\floor{-x} = -\floor{x} - 1$ for all + $x$ in every open subinterval of $P$. + That is, $s_k = -t_k - 1$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b \floor{x} \mathop{dx} + \int_a^b \floor{-x} \mathop{dx} + & = \sum_{k=1}^n s_k (x_k - x_{k-1}) + + \sum_{k=1}^n t_k (x_k - x_{k-1}) \\ + & = \sum_{k=1}^n (x_k - x_{k-1}) \cdot (s_k + t_k) \\ + & = \sum_{k=1}^n (x_k - x_{k-1}) \cdot (-t_k - 1 + t_k) \\ + & = \sum_{k=1}^n (x_{k-1} - x_k) \\ + & = x_0 - x_n \\ + & = a - b. + \end{align*} + \end{proof} \subsection{\pending{Exercise 1.15.5}}% \hyperlabel{sub:exercise-1.15.5} @@ -2198,69 +2082,65 @@ Show that \subsubsection{\pending{Exercise 1.15.5a}}% \hyperlabel{ssub:exercise-1.15.5a} -Prove that $\int_0^2 \floor{t^2} \mathop{dt} = 5 - \sqrt{2} - \sqrt{3}$. + Prove that $\int_0^2 \floor{t^2} \mathop{dt} = 5 - \sqrt{2} - \sqrt{3}$. -\begin{proof} - - Let $s(t) = \floor{t^2}$ with domain $[0, 2]$. - Then $s$ is a \nameref{ref:step-function} with partition - $P = \{0, 1, \sqrt{2}, \sqrt{3}, 2\} = \{x_0, x_1, \ldots, x_4\}$. - Let $s_k$ denote the constant value that $s$ takes in the $k$th open - subinterval of $P$. - By the \nameref{ref:integral-step-function}, - \begin{align*} - \int_0^2 \floor{t^2} \mathop{dt} - & = \sum_{k=1}^4 s_k \cdot (x_k - x_{k-1}) \\ - & = 0 \cdot (1 - 0) + 1 \cdot (\sqrt{2} - 1) + - 2 \cdot (\sqrt{3} - \sqrt{2}) + 3 \cdot (2 - \sqrt{3}) \\ - & = 5 - \sqrt{2} - \sqrt{3}. - \end{align*} - -\end{proof} + \begin{proof} + Let $s(t) = \floor{t^2}$ with domain $[0, 2]$. + Then $s$ is a \nameref{ref:step-function} with partition + $P = \{0, 1, \sqrt{2}, \sqrt{3}, 2\} = \{x_0, x_1, \ldots, x_4\}$. + Let $s_k$ denote the constant value that $s$ takes in the $k$th open + subinterval of $P$. + By the \nameref{ref:integral-step-function}, + \begin{align*} + \int_0^2 \floor{t^2} \mathop{dt} + & = \sum_{k=1}^4 s_k \cdot (x_k - x_{k-1}) \\ + & = 0 \cdot (1 - 0) + 1 \cdot (\sqrt{2} - 1) + + 2 \cdot (\sqrt{3} - \sqrt{2}) + 3 \cdot (2 - \sqrt{3}) \\ + & = 5 - \sqrt{2} - \sqrt{3}. + \end{align*} + \end{proof} \subsubsection{\pending{Exercise 1.15.5b}}% \hyperlabel{ssub:exercise-1.15.5b} -Compute $\int_{-3}^3 \floor{t^2} \mathop{dt}$. + Compute $\int_{-3}^3 \floor{t^2} \mathop{dt}$. -\begin{proof} - - Let $s(t) = \floor{t^2}$ with domain $[0, 3]$. - Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} - \begin{align*} - P - & = \{\sqrt{0}, \sqrt{1}, \sqrt{2}, \sqrt{3}, \sqrt{4}, \sqrt{5}, - \sqrt{6}, \sqrt{7}, \sqrt{8}, \sqrt{9}\} \\ - & = \{x_0, x_1, \ldots, x_9\}. - \end{align*} - Let $s_k$ denote the constant value that $s$ takes in the $k$th open - subinterval of $P$. - By the \nameref{ref:integral-step-function}, - \begin{align} - \int_0^3 \floor{t^2} \mathop{dt} - & = \sum_{k=1}^9 s_k \cdot (x_k - x_{k-1}) - \nonumber \\ - & = \sum_{k=0}^8 k \cdot (\sqrt{k + 1} - \sqrt{k}). - \hyperlabel{sub:exercise-1.15.5b-eq1} - \end{align} - We notice $\floor{t^2}$ is symmetric about the $y$-axis. - Thus - \begin{equation} - \hyperlabel{sub:exercise-1.15.5b-eq2} - \int_{-3}^0 \floor{t^2} \mathop{dt} = \int_0^3 \floor{t^2}. - \end{equation} - By \nameref{sub:step-additivity-with-respect-interval-integration}, - \begin{align*} - \int_{-3}^3 \floor{t^2} \mathop{dt} - & = \int_{-3}^0 \floor{t^2} \mathop{dt} + - \int_0^3 \floor{t^2} \mathop{dt} \\ - & = 2\int_0^3 \floor{t^2} \mathop{dt} - & \eqref{sub:exercise-1.15.5b-eq2} \\ - & = 2 \left[\sum_{k=0}^8 k \cdot (\sqrt{k + 1} - \sqrt{k})\right]. - & \eqref{sub:exercise-1.15.5b-eq1} - \end{align*} - -\end{proof} + \begin{proof} + Let $s(t) = \floor{t^2}$ with domain $[0, 3]$. + Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} + \begin{align*} + P + & = \{\sqrt{0}, \sqrt{1}, \sqrt{2}, \sqrt{3}, \sqrt{4}, \sqrt{5}, + \sqrt{6}, \sqrt{7}, \sqrt{8}, \sqrt{9}\} \\ + & = \{x_0, x_1, \ldots, x_9\}. + \end{align*} + Let $s_k$ denote the constant value that $s$ takes in the $k$th open + subinterval of $P$. + By the \nameref{ref:integral-step-function}, + \begin{align} + \int_0^3 \floor{t^2} \mathop{dt} + & = \sum_{k=1}^9 s_k \cdot (x_k - x_{k-1}) + \nonumber \\ + & = \sum_{k=0}^8 k \cdot (\sqrt{k + 1} - \sqrt{k}). + \hyperlabel{sub:exercise-1.15.5b-eq1} + \end{align} + We notice $\floor{t^2}$ is symmetric about the $y$-axis. + Thus + \begin{equation} + \hyperlabel{sub:exercise-1.15.5b-eq2} + \int_{-3}^0 \floor{t^2} \mathop{dt} = \int_0^3 \floor{t^2}. + \end{equation} + By \nameref{sub:step-additivity-with-respect-interval-integration}, + \begin{align*} + \int_{-3}^3 \floor{t^2} \mathop{dt} + & = \int_{-3}^0 \floor{t^2} \mathop{dt} + + \int_0^3 \floor{t^2} \mathop{dt} \\ + & = 2\int_0^3 \floor{t^2} \mathop{dt} + & \eqref{sub:exercise-1.15.5b-eq2} \\ + & = 2 \left[\sum_{k=0}^8 k \cdot (\sqrt{k + 1} - \sqrt{k})\right]. + & \eqref{sub:exercise-1.15.5b-eq1} + \end{align*} + \end{proof} \subsection{\pending{Exercise 1.15.7}}% \hyperlabel{sub:exercise-1.15.7} @@ -2268,333 +2148,320 @@ Compute $\int_{-3}^3 \floor{t^2} \mathop{dt}$. \subsubsection{\pending{Exercise 1.15.7a}}% \hyperlabel{ssub:exercise-1.15.7a} -Compute $\int_0^9 \floor{\sqrt{t}} \mathop{dt}$. + Compute $\int_0^9 \floor{\sqrt{t}} \mathop{dt}$. -\begin{proof} - - Let $s(t) = \floor{\sqrt{t}}$ with domain $[0, 9]$. - Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} - $P = \{0, 1, 4, 9\} = \{x_0, x_1, x_2, x_3\}$. - Let $s_k$ denote the constant value that $s$ takes in the $k$th open - subinterval of $P$. - By the \nameref{ref:integral-step-function}, - \begin{align*} - \int_0^9 \floor{\sqrt{t}} \mathop{dt} - & = \sum_{k=1}^3 s_k \cdot (x_k - x_{k-1}) \\ - & = 0 \cdot (1 - 0) + 1 \cdot (4 - 1) + 2 \cdot (9 - 4) \\ - & = 13. - \end{align*} - -\end{proof} + \begin{proof} + Let $s(t) = \floor{\sqrt{t}}$ with domain $[0, 9]$. + Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} + $P = \{0, 1, 4, 9\} = \{x_0, x_1, x_2, x_3\}$. + Let $s_k$ denote the constant value that $s$ takes in the $k$th open + subinterval of $P$. + By the \nameref{ref:integral-step-function}, + \begin{align*} + \int_0^9 \floor{\sqrt{t}} \mathop{dt} + & = \sum_{k=1}^3 s_k \cdot (x_k - x_{k-1}) \\ + & = 0 \cdot (1 - 0) + 1 \cdot (4 - 1) + 2 \cdot (9 - 4) \\ + & = 13. + \end{align*} + \end{proof} \subsubsection{\pending{Exercise 1.15.7b}}% \hyperlabel{ssub:exercise-1.15.7b} -If $n$ is a positive integer, prove that - $$\int_0^{n^2} \floor{\sqrt{t}} \mathop{dt} = n(n - 1)(4n + 1) / 6.$$ + If $n$ is a positive integer, prove that + $$\int_0^{n^2} \floor{\sqrt{t}} \mathop{dt} = n(n - 1)(4n + 1) / 6.$$ -\begin{proof} + \begin{proof} - Define predicate $P(n)$ as - \begin{equation} - \hyperlabel{sub:exercise-1.15.7b-eq1} - \int_0^{n^2} \floor{\sqrt{t}} \mathop{dt} = \frac{n(n - 1)(4n + 1)}{6}. - \end{equation} - We use induction to prove $P(n)$ holds for all integers satisfying $n > 0$. + Define predicate $P(n)$ as + \begin{equation} + \hyperlabel{sub:exercise-1.15.7b-eq1} + \int_0^{n^2} \floor{\sqrt{t}} \mathop{dt} = \frac{n(n - 1)(4n + 1)}{6}. + \end{equation} + We use induction to prove $P(n)$ holds for all integers satisfying $n > 0$. - \paragraph{Base Case}% + \paragraph{Base Case}% - Let $n = 1$. - Define $s(t) = \floor{\sqrt{t}}$ with domain $[0, 1]$. - Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} - $P = \{0, 1\} = \{x_0, x_1\}$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - By definition of the \nameref{ref:integral-step-function}, the left-hand - side of \eqref{sub:exercise-1.15.7b-eq1} evaluates to - \begin{align*} - \int_0^{n^2} \floor{\sqrt{t}} \mathop{dt} - & = \int_0^1 \floor{\sqrt{t}} \mathop{dt} \\ - & = \sum_{k=1}^1 s_k \cdot (x_k - x_{k-1}) \\ - & = 0. - \end{align*} - The right-hand side of \eqref{sub:exercise-1.15.7b-eq1} likewise evaluates - to $0$. - Thus $P(1)$ holds. + Let $n = 1$. + Define $s(t) = \floor{\sqrt{t}}$ with domain $[0, 1]$. + Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} + $P = \{0, 1\} = \{x_0, x_1\}$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval + of $P$. + By definition of the \nameref{ref:integral-step-function}, the left-hand + side of \eqref{sub:exercise-1.15.7b-eq1} evaluates to + \begin{align*} + \int_0^{n^2} \floor{\sqrt{t}} \mathop{dt} + & = \int_0^1 \floor{\sqrt{t}} \mathop{dt} \\ + & = \sum_{k=1}^1 s_k \cdot (x_k - x_{k-1}) \\ + & = 0. + \end{align*} + The right-hand side of \eqref{sub:exercise-1.15.7b-eq1} likewise evaluates + to $0$. + Thus $P(1)$ holds. - \paragraph{Induction Step}% + \paragraph{Induction Step}% - Let $n > 0$ be a positive integer and suppose $P(n)$ is true. - Define $s(t) = \floor{\sqrt{t}}$ with domain $[0, (n + 1)^2]$. - Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} - \begin{align*} - P - & = \{0, 1, 4, \ldots, n^2, (n + 1)^2\} \\ - & = \{x_0, x_1, \ldots, x_n, x_{n + 1}\}. - \end{align*} - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - By definition of the \nameref{ref:integral-step-function}, it follows - that - \begin{align*} - & \int_0^{(n + 1)^2} s(x) \mathop{dx} \\ - & = \sum_{k=1}^{n + 1} s_k \cdot (x_k - x_{k-1}) \\ - & = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) + - \left[s_{n+1} \cdot (x_{n + 1} - x_n)\right] \\ - & = \int_0^{n^2} s(x) \mathop{dx} + - \left[s_{n+1} \cdot (x_{n + 1} - x_n)\right] \\ - & = \int_0^{n^2} s(x) \mathop{dx} + - \left[ n \cdot ((n + 1)^2 - n^2) \right] \\ - & = \int_0^{n^2} s(x) \mathop{dx} + \left[ 2n^2 + n \right] \\ - & = \frac{n(n - 1)(4n + 1)}{6} + 2n^2 + n - & \text{induction hypothesis} \\ - & = \frac{n(n - 1)(4n + 1) + 12n^2 + 6n}{6} \\ - & = \frac{4n^3 + 9n^2 + 5n}{6} \\ - & = \frac{(n^2 + n)(4n + 5)}{6} \\ - & = \frac{(n + 1)((n + 1) - 1)(4(n + 1) + 1)}{6}. - \end{align*} - Thus $P(n + 1)$ holds. + Let $n > 0$ be a positive integer and suppose $P(n)$ is true. + Define $s(t) = \floor{\sqrt{t}}$ with domain $[0, (n + 1)^2]$. + Then $s$ is a \nameref{ref:step-function} with \nameref{ref:partition} + \begin{align*} + P + & = \{0, 1, 4, \ldots, n^2, (n + 1)^2\} \\ + & = \{x_0, x_1, \ldots, x_n, x_{n + 1}\}. + \end{align*} + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval + of $P$. + By definition of the \nameref{ref:integral-step-function}, it follows + that + \begin{align*} + & \int_0^{(n + 1)^2} s(x) \mathop{dx} \\ + & = \sum_{k=1}^{n + 1} s_k \cdot (x_k - x_{k-1}) \\ + & = \sum_{k=1}^n s_k \cdot (x_k - x_{k-1}) + + \left[s_{n+1} \cdot (x_{n + 1} - x_n)\right] \\ + & = \int_0^{n^2} s(x) \mathop{dx} + + \left[s_{n+1} \cdot (x_{n + 1} - x_n)\right] \\ + & = \int_0^{n^2} s(x) \mathop{dx} + + \left[ n \cdot ((n + 1)^2 - n^2) \right] \\ + & = \int_0^{n^2} s(x) \mathop{dx} + \left[ 2n^2 + n \right] \\ + & = \frac{n(n - 1)(4n + 1)}{6} + 2n^2 + n + & \text{induction hypothesis} \\ + & = \frac{n(n - 1)(4n + 1) + 12n^2 + 6n}{6} \\ + & = \frac{4n^3 + 9n^2 + 5n}{6} \\ + & = \frac{(n^2 + n)(4n + 5)}{6} \\ + & = \frac{(n + 1)((n + 1) - 1)(4(n + 1) + 1)}{6}. + \end{align*} + Thus $P(n + 1)$ holds. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - By mathematical induction, it follows for all positive integers $n$, $P(n)$ - is true. + By mathematical induction, it follows for all positive integers $n$, + $P(n)$ is true. -\end{proof} + \end{proof} \subsection{\pending{Exercise 1.15.9}}% \hyperlabel{sub:exercise-1.15.9} -Show that the following property is equivalent to - \nameref{sub:step-expansion-contraction-interval-integration}: - \begin{equation} - \hyperlabel{sub:exercise-1.15.9-eq1} - \int_{ka}^{kb} f(x) \mathop{dx} = k \int_a^b f(kx) \mathop{dx}. - \end{equation} + Show that the following property is equivalent to + \nameref{sub:step-expansion-contraction-interval-integration}: + \begin{equation} + \hyperlabel{sub:exercise-1.15.9-eq1} + \int_{ka}^{kb} f(x) \mathop{dx} = k \int_a^b f(kx) \mathop{dx}. + \end{equation} -\begin{proof} - - Let $f$ be a step function on closed interval $[a, b]$ and $k \neq 0$. - Applying \nameref{sub:step-expansion-contraction-interval-integration} to the - right-hand side of \eqref{sub:exercise-1.15.9-eq1} yields - $$k\int_{ka}^{kb} f(kx / k) \mathop{dx} = - k\left[k\int_a^b f(kx) \mathop{dx}\right].$$ - Simplifying the left-hand side and dividing both sides by $k$ immediately - yields the desired result. - -\end{proof} + \begin{proof} + Let $f$ be a step function on closed interval $[a, b]$ and $k \neq 0$. + Applying \nameref{sub:step-expansion-contraction-interval-integration} to + the right-hand side of \eqref{sub:exercise-1.15.9-eq1} yields + $$k\int_{ka}^{kb} f(kx / k) \mathop{dx} = + k\left[k\int_a^b f(kx) \mathop{dx}\right].$$ + Simplifying the left-hand side and dividing both sides by $k$ immediately + yields the desired result. + \end{proof} \subsection{\pending{Exercise 1.15.11}}% \hyperlabel{sub:exercise-1.15.11} -If we instead defined the integral of step functions as - \begin{equation*} - \hyperlabel{sub:exercise-1.15.11-eq1} - \int_a^b s(x) \mathop{dx} = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}), - \end{equation*} - a new and different theory of integration would result. -Which of the following properties would remain valid in this new theory? + If we instead defined the integral of step functions as + \begin{equation*} + \hyperlabel{sub:exercise-1.15.11-eq1} + \int_a^b s(x) \mathop{dx} = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}), + \end{equation*} + a new and different theory of integration would result. + Which of the following properties would remain valid in this new theory? \subsubsection{\pending{Exercise 1.15.11a}}% \hyperlabel{ssub:exercise-1.15.11a} -$\int_a^b s + \int_b^c s = \int_a^c s$. + $\int_a^b s + \int_b^c s = \int_a^c s$. -\begin{note} - This property mirrors - \nameref{sub:step-additivity-with-respect-interval-integration}. -\end{note} + \begin{note} + This property mirrors + \nameref{sub:step-additivity-with-respect-interval-integration}. + \end{note} -\begin{proof} + \begin{proof} + The above property is \textbf{valid}. - The above property is \textbf{valid}. + \vspace{6pt} - \vspace{6pt} - - WLOG, suppose $a < b < c$. - Let $s$ be a step function defined on closed interval $[a, c]$. - By definition of a \nameref{ref:step-function}, there exists a - \nameref{ref:partition} such that $s$ is constant on each open - subinterval of $P$. - Let $Q = \{x_0, x_1, \ldots, x_n\}$ be a refinement of $P$ that includes $b$ - as a subdivision point. - Then $Q$ is a step partition of $s$ and there exists some $0 < i < n$ such - that $x_i = c$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $Q$. - By \eqref{sub:exercise-1.15.11-eq1}, - \begin{align*} - \int_a^c s - & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ - & = \sum_{k=1}^i s_k^3 \cdot (x_k - x_{k-1}) + - \sum_{k=i+1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ - & = \int_a^b s + \int_b^c s. - \end{align*} - -\end{proof} + WLOG, suppose $a < b < c$. + Let $s$ be a step function defined on closed interval $[a, c]$. + By definition of a \nameref{ref:step-function}, there exists a + \nameref{ref:partition} such that $s$ is constant on each open + subinterval of $P$. + Let $Q = \{x_0, x_1, \ldots, x_n\}$ be a refinement of $P$ that includes $b$ + as a subdivision point. + Then $Q$ is a step partition of $s$ and there exists some $0 < i < n$ such + that $x_i = c$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $Q$. + By \eqref{sub:exercise-1.15.11-eq1}, + \begin{align*} + \int_a^c s + & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ + & = \sum_{k=1}^i s_k^3 \cdot (x_k - x_{k-1}) + + \sum_{k=i+1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ + & = \int_a^b s + \int_b^c s. + \end{align*} + \end{proof} \subsubsection{\pending{Exercise 1.15.11b}}% \hyperlabel{ssub:exercise-1.15.11b} -$\int_a^b (s + t) = \int_a^b s + \int_a^b t$. + $\int_a^b (s + t) = \int_a^b s + \int_a^b t$. -\begin{note} - This property mirrors the \nameref{sub:step-additive-property}. -\end{note} + \begin{note} + This property mirrors the \nameref{sub:step-additive-property}. + \end{note} -\begin{proof} + \begin{proof} + The above property is \textbf{invalid}. - The above property is \textbf{invalid}. + \vspace{6pt} - \vspace{6pt} + Let $s$ and $t$ be step functions on closed interval $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P_s$ such that $s$ is constant on each open subinterval of $P_s$. + Likewise, there exists a partition $P_t$ such that $t$ is constant on each + open subinterval of $P_t$. + Therefore $s + t$ is a step function with step partition + $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\},$$ + the common refinement of $P_s$ and $P_t$ with subdivision points + $x_0$, $x_1$, $\ldots$, $x_n$. - Let $s$ and $t$ be step functions on closed interval $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P_s$ such that $s$ is constant on each open subinterval of $P_s$. - Likewise, there exists a partition $P_t$ such that $t$ is constant on each - open subinterval of $P_t$. - Therefore $s + t$ is a step function with step partition - $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\},$$ - the common refinement of $P_s$ and $P_t$ with subdivision points - $x_0$, $x_1$, $\ldots$, $x_n$. - - $s$ and $t$ remain constant on every open subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P_s$. - Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of - $P_t$. - By \eqref{sub:exercise-1.15.11-eq1}, - \begin{align*} - \int_a^b s + t - & = \sum_{k=1}^n (s_k + t_k)^3 \cdot (x_k - x_{k-1}) \\ - & = \sum_{k=1}^n - \left[ s_k^3 + 3s_k^2t_k + 3s_kt_k^2 + t_k^3 \right] \\ - & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \;+ \\ - & \quad\qquad - \sum_{k=1}^n t_k^3 \cdot (x_k - x_{k-1}) \;+ \\ - & \quad\qquad - \sum_{k=1}^n (3s_k^2t_k + 3s_kt_k^2) \cdot (x_k - x_{k - 1}) \\ - & = \int_a^b s + \int_a^b t + - \sum_{k=1}^n (3s_k^2t_k + 3s_kt_k^2) \cdot (x_k - x_{k - 1}). - \end{align*} - Since this last addend does not necessarily equal $0$, the desired property is - invalid. - -\end{proof} + $s$ and $t$ remain constant on every open subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P_s$. + Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of + $P_t$. + By \eqref{sub:exercise-1.15.11-eq1}, + \begin{align*} + \int_a^b s + t + & = \sum_{k=1}^n (s_k + t_k)^3 \cdot (x_k - x_{k-1}) \\ + & = \sum_{k=1}^n + \left[ s_k^3 + 3s_k^2t_k + 3s_kt_k^2 + t_k^3 \right] \\ + & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \;+ \\ + & \quad\qquad + \sum_{k=1}^n t_k^3 \cdot (x_k - x_{k-1}) \;+ \\ + & \quad\qquad + \sum_{k=1}^n (3s_k^2t_k + 3s_kt_k^2) \cdot (x_k - x_{k - 1}) \\ + & = \int_a^b s + \int_a^b t + + \sum_{k=1}^n (3s_k^2t_k + 3s_kt_k^2) \cdot (x_k - x_{k - 1}). + \end{align*} + Since this last addend does not necessarily equal $0$, the desired property + is invalid. + \end{proof} \subsubsection{\pending{Exercise 1.15.11c}}% \hyperlabel{ssub:exercise-1.15.11c} -$\int_a^b c \cdot s = c \int_a^b s$. + $\int_a^b c \cdot s = c \int_a^b s$. -\begin{note} - This property mirrors the \nameref{sub:step-homogeneous-property}. -\end{note} + \begin{note} + This property mirrors the \nameref{sub:step-homogeneous-property}. + \end{note} -\begin{proof} + \begin{proof} + The above property is \textbf{invalid}. - The above property is \textbf{invalid}. + \vspace{6pt} - \vspace{6pt} - - Let $s$ be a step function on closed interval $[a, b]$. - By definition of a step function, there exists a \nameref{ref:partition} - $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open - subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - Then $c \cdot s$ is a step function with step partition $P$. - By \eqref{sub:exercise-1.15.11-eq1}, - \begin{align*} - \int_a^b c \cdot s - & = \sum_{k=1}^n (c \cdot s_k)^3 \cdot (x_k - x_{k-1}) \\ - & = \sum_{k=1}^n c^3 \cdot s_k^3 \cdot (x_k - x_{k-1}) \\ - & = c^3 \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ - & = c^3 \int_a^b s. - \end{align*} - Since $c^3$ does not necessarily equal $c$, the desired property is invalid. - -\end{proof} + Let $s$ be a step function on closed interval $[a, b]$. + By definition of a step function, there exists a \nameref{ref:partition} + $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is constant on each open + subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P$. + Then $c \cdot s$ is a step function with step partition $P$. + By \eqref{sub:exercise-1.15.11-eq1}, + \begin{align*} + \int_a^b c \cdot s + & = \sum_{k=1}^n (c \cdot s_k)^3 \cdot (x_k - x_{k-1}) \\ + & = \sum_{k=1}^n c^3 \cdot s_k^3 \cdot (x_k - x_{k-1}) \\ + & = c^3 \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ + & = c^3 \int_a^b s. + \end{align*} + Since $c^3$ does not necessarily equal $c$, the desired property is invalid. + \end{proof} \subsubsection{\pending{Exercise 1.15.11d}}% \hyperlabel{ssub:exercise-1.15.11d} -$\int_{a+c}^{b+c} s(x) \mathop{dx} = \int_a^b s(x + c) \mathop{dx}$. + $\int_{a+c}^{b+c} s(x) \mathop{dx} = \int_a^b s(x + c) \mathop{dx}$. -\begin{note} - This property mirrors \nameref{sub:step-invariance-under-translation}. -\end{note} + \begin{note} + This property mirrors \nameref{sub:step-invariance-under-translation}. + \end{note} -\begin{proof} + \begin{proof} + The above property is \textbf{valid}. - The above property is \textbf{valid}. + \vspace{6pt} - \vspace{6pt} + Let $s$ be a step function on closed interval $[a + c, b + c]$. + By definition of a \nameref{ref:step-function}, there exists a + \nameref{ref:partition} $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is + constant on each open subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P$. - Let $s$ be a step function on closed interval $[a + c, b + c]$. - By definition of a \nameref{ref:step-function}, there exists a - \nameref{ref:partition} $P = \{x_0, x_1, \ldots, x_n\}$ such that $s$ is - constant on each open subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - - Let $c$ be a real number. - Then $t(x) = s(x + c)$ is a step function on closed interval $[a, b]$ with - partition $Q = \{x_0 - c, x_1 - c, \ldots, x_n - c\}$. - Furthermore, $t$ is constant on each open subinterval of $Q$. - Let $t_k$ denote the value of $t$ on the $k$th open subinterval of $Q$. - By construction, $t_k = s_k$. - By \eqref{sub:exercise-1.15.11-eq1}, - \begin{align*} - \int_{a+c}^{b+c} s(x) \mathop{dx} - & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ - & = \sum_{k=1}^n s_k^3 \cdot ((x_k - c) - (x_{k-1} - c)) \\ - & = \sum_{k=1}^n t_k^3 \cdot ((x_k - c) - (x_{k-1} - c)) \\ - & = \int_a^b t(x) \mathop{dx} \\ - & = \int_a^b s(x + c) \mathop{dx}. - \end{align*} - -\end{proof} + Let $c$ be a real number. + Then $t(x) = s(x + c)$ is a step function on closed interval $[a, b]$ with + partition $Q = \{x_0 - c, x_1 - c, \ldots, x_n - c\}$. + Furthermore, $t$ is constant on each open subinterval of $Q$. + Let $t_k$ denote the value of $t$ on the $k$th open subinterval of $Q$. + By construction, $t_k = s_k$. + By \eqref{sub:exercise-1.15.11-eq1}, + \begin{align*} + \int_{a+c}^{b+c} s(x) \mathop{dx} + & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ + & = \sum_{k=1}^n s_k^3 \cdot ((x_k - c) - (x_{k-1} - c)) \\ + & = \sum_{k=1}^n t_k^3 \cdot ((x_k - c) - (x_{k-1} - c)) \\ + & = \int_a^b t(x) \mathop{dx} \\ + & = \int_a^b s(x + c) \mathop{dx}. + \end{align*} + \end{proof} \subsubsection{\pending{Exercise 1.15.11e}}% \hyperlabel{ssub:exercise-1.15.11e} -If $s(x) < t(x)$ for each $x$ in $[a, b]$, then $\int_a^b s < \int_a^b t$. + If $s(x) < t(x)$ for each $x$ in $[a, b]$, then $\int_a^b s < \int_a^b t$. -\begin{note} - This property mirrors the \nameref{sub:step-comparison-theorem}. -\end{note} + \begin{note} + This property mirrors the \nameref{sub:step-comparison-theorem}. + \end{note} -\begin{proof} + \begin{proof} + The above property is \textbf{valid}. - The above property is \textbf{valid}. + \vspace{6pt} - \vspace{6pt} + Let $s$ and $t$ be step functions on closed interval $[a, b]$. + By definition of a \nameref{ref:step-function}, there exists a + \nameref{ref:partition} $P_s$ such that $s$ is constant on each open + subinterval of $P_s$. + Likewise, there exists a partition $P_t$ such that $t$ is constant on each + open subinterval of $P_t$. + Let $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\}$$ be the common + refinement of $P_s$ and $P_t$ with subdivision points $x_0$, $x_1$, + $\ldots$, $x_n$. - Let $s$ and $t$ be step functions on closed interval $[a, b]$. - By definition of a \nameref{ref:step-function}, there exists a - \nameref{ref:partition} $P_s$ such that $s$ is constant on each open - subinterval of $P_s$. - Likewise, there exists a partition $P_t$ such that $t$ is constant on each - open subinterval of $P_t$. - Let $$P = P_s \cup P_t = \{x_0, x_1, \ldots, x_n\}$$ be the common refinement - of $P_s$ and $P_t$ with subdivision points $x_0$, $x_1$, $\ldots$, $x_n$. - - By construction, $P$ is a step partition for both $s$ and $t$. - Thus $s$ and $t$ remain constant on every open subinterval of $P$. - Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of - $P$. - Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of - $P$. - By \eqref{sub:exercise-1.15.11-eq1}, - \begin{align*} - \int_a^b s - & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ - & < \sum_{k=1}^n t_k^3 \cdot (x_k - x_{k-1}) \\ - & = \int_a^b t. - \end{align*} - -\end{proof} + By construction, $P$ is a step partition for both $s$ and $t$. + Thus $s$ and $t$ remain constant on every open subinterval of $P$. + Let $s_k$ denote the constant value of $s$ on the $k$th open subinterval of + $P$. + Let $t_k$ denote the constant value of $t$ on the $k$th open subinterval of + $P$. + By \eqref{sub:exercise-1.15.11-eq1}, + \begin{align*} + \int_a^b s + & = \sum_{k=1}^n s_k^3 \cdot (x_k - x_{k-1}) \\ + & < \sum_{k=1}^n t_k^3 \cdot (x_k - x_{k-1}) \\ + & = \int_a^b t. + \end{align*} + \end{proof} \section{Upper and Lower Integrals}% \hyperlabel{sec:upper-lower-integrals} @@ -2602,65 +2469,67 @@ If $s(x) < t(x)$ for each $x$ in $[a, b]$, then $\int_a^b s < \int_a^b t$. \subsection{\pending{Theorem 1.9}}% \hyperlabel{sub:theorem-1.9} -\begin{theorem}[1.9] + \begin{theorem}[1.9] + Every function $f$ which is bounded on $[a, b]$ has a lower integral + $\ubar{I}(f)$ and an upper integral $\overline{I}(f)$ satisfying the + inequalities + \begin{equation} + \hyperlabel{sub:theorem-1.9-eq1} + \int_a^b s(x) \mathop{dx} \leq \ubar{I}(f) \leq + \bar{I}(f) \leq \int_a^b t(x) \mathop{dx} + \end{equation} + for all \nameref{ref:step-function}s $s$ and $t$ with $s \leq f \leq t$. + The function $f$ is \nameref{ref:integrable} on $[a, b]$ if and only if + its upper and lower integrals are equal, in which case we have + $$\int_a^b f(x) \mathop{dx} = \ubar{I}(f) = \bar{I}(f).$$ + \end{theorem} - Every function $f$ which is bounded on $[a, b]$ has a lower integral - $\ubar{I}(f)$ and an upper integral $\overline{I}(f)$ satisfying the - inequalities - \begin{equation} - \hyperlabel{sub:theorem-1.9-eq1} - \int_a^b s(x) \mathop{dx} \leq \ubar{I}(f) \leq - \bar{I}(f) \leq \int_a^b t(x) \mathop{dx} - \end{equation} - for all \nameref{ref:step-function}s $s$ and $t$ with $s \leq f \leq t$. - The function $f$ is \nameref{ref:integrable} on $[a, b]$ if and only if - its upper and lower integrals are equal, in which case we have - $$\int_a^b f(x) \mathop{dx} = \ubar{I}(f) = \bar{I}(f).$$ + \begin{proof} -\end{theorem} + Let $f$ be a function bounded on $[a, b]$. + We prove that (i) $f$ has a lower and upper integral satisfying + \eqref{sub:theorem-1.9-eq1} and (ii) that $f$ is integrable on $[a, b]$ if + and only if its lower and upper integrals are equal. -\begin{proof} + \paragraph{(i)}% - Let $f$ be a function bounded on $[a, b]$. - We prove that (i) $f$ has a lower and upper integral satisfying - \eqref{sub:theorem-1.9-eq1} and (ii) that $f$ is integrable on $[a, b]$ if - and only if its lower and upper integrals are equal. + Because $f$ is bounded, there exists some $M > 0$ such that + $\abs{f(x)} \leq M$ for all $x \in [a, b]$. - \paragraph{(i)}% + Let $S$ denote the set of numbers $\int_a^b s(x) \mathop{dx}$ obtained as + $s$ runs through all step functions below $f$. + That is, let + $$S = \left\{ \int_a^b s(x) \mathop{dx} : s \leq f \right\}.$$ + Note $S$ is nonempty since, e.g. constant function $c(x) = -M$ is a + member. - Because $f$ is bounded, there exists some $M > 0$ such that - $\abs{f(x)} \leq M$ for all $x \in [a, b]$. + Likewise, let $T$ denote the set of numbers $\int_a^b t(x) \mathop{dx}$ + obtained as $t$ runs through all step functions above $f$. + That is, let + $$T = \left\{ \int_a^b t(x) \mathop{dx} : f \leq t \right\}.$$ + Note $T$ is nonempty since e.g. constant function $c(x) = M$ is a member. - Let $S$ denote the set of numbers $\int_a^b s(x) \mathop{dx}$ obtained as - $s$ runs through all step functions below $f$. - That is, let $$S = \left\{ \int_a^b s(x) \mathop{dx} : s \leq f \right\}.$$ - Note $S$ is nonempty since, e.g. constant function $c(x) = -M$ is a member. + By construction, $s \leq t$ for every $s$ in $S$ and $t$ in $T$. + Therefore \nameref{sec:theorem-i.34} tells us $S$ has a + \nameref{ref:supremum}, $T$ has an \nameref{ref:infimum}, and + $\sup{S} \leq \inf{T}$. + By definition of the \nameref{ref:lower-integral}, + $\ubar{I}(f) = \sup{S}$. + By definition of the \nameref{ref:upper-integral}, $\bar{I}(f) = \inf{S}$. + Thus \eqref{sub:theorem-1.9-eq1} holds. - Likewise, let $T$ denote the set of numbers $\int_a^b t(x) \mathop{dx}$ - obtained as $t$ runs through all step functions above $f$. - That is, let $$T = \left\{ \int_a^b t(x) \mathop{dx} : f \leq t \right\}.$$ - Note $T$ is nonempty since e.g. constant function $c(x) = M$ is a member. + \paragraph{(ii)}% - By construction, $s \leq t$ for every $s$ in $S$ and $t$ in $T$. - Therefore \nameref{sec:theorem-i.34} tells us $S$ has a - \nameref{ref:supremum}, $T$ has an \nameref{ref:infimum}, and - $\sup{S} \leq \inf{T}$. - By definition of the \nameref{ref:lower-integral}, $\ubar{I}(f) = \sup{S}$. - By definition of the \nameref{ref:upper-integral}, $\bar{I}(f) = \inf{S}$. - Thus \eqref{sub:theorem-1.9-eq1} holds. + By definition of integrability, $f$ is integrable on $[a, b]$ if and only + if there exists one and only one number $I$ such that + $$\int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}$$ + for every pair of step functions $s$ and $t$ satisfying + \eqref{ref:integral-bounded-function-eq1}. + By \eqref{sub:theorem-1.9-eq1} and the definition of the supremum/infimum, + this holds if and only if $\ubar{I}(f) = \bar{I}(f)$, concluding the + proof. - \paragraph{(ii)}% - - By definition of integrability, $f$ is integrable on $[a, b]$ if and only if - there exists one and only one number $I$ such that - $$\int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}$$ - for every pair of step functions $s$ and $t$ satisfying - \eqref{ref:integral-bounded-function-eq1}. - By \eqref{sub:theorem-1.9-eq1} and the definition of the supremum/infimum, - this holds if and only if $\ubar{I}(f) = \bar{I}(f)$, concluding the - proof. - -\end{proof} + \end{proof} \section{The Area of an Ordinate Set Expressed as an Integral}% \hyperlabel{sec:area-ordinate-set-expressed-integral} @@ -2668,81 +2537,76 @@ If $s(x) < t(x)$ for each $x$ in $[a, b]$, then $\int_a^b s < \int_a^b t$. \subsection{\pending{Theorem 1.10}}% \hyperlabel{sub:theorem-1.10} -\begin{theorem}[1.10] + \begin{theorem}[1.10] + Let $f$ be a nonnegative function, \nameref{ref:integrable} on an interval + $[a, b]$, and let $Q$ denote the ordinate set of $f$ over $[a, b]$. + Then $Q$ is measurable and its area is equal to the integral + $\int_a^b f(x) \mathop{dx}$. + \end{theorem} - Let $f$ be a nonnegative function, \nameref{ref:integrable} on an interval - $[a, b]$, and let $Q$ denote the ordinate set of $f$ over $[a, b]$. - Then $Q$ is measurable and its area is equal to the integral - $\int_a^b f(x) \mathop{dx}$. - -\end{theorem} - -\begin{proof} - - Let $f$ be a nonnegative function, \nameref{ref:integrable} on $[a, b]$. - By definition of integrability, there exists one and only one number $I$ such - that $$\int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}$$ for - every pair of step functions $s$ and $t$ satisfying - \eqref{ref:integral-bounded-function-eq1}. - In other words, $I$ is the one and only number that satisfies - $$a(S) \leq I \leq a(T)$$ for every pair of step regions - $S \subseteq Q \subseteq T$. - By the \nameref{sub:area-exhaustion-property}, $Q$ is measurable and its area - is equal to $I = \int_a^b f(x) \mathop{dx}$. - -\end{proof} + \begin{proof} + Let $f$ be a nonnegative function, \nameref{ref:integrable} on $[a, b]$. + By definition of integrability, there exists one and only one number $I$ + such that + $$\int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}$$ for + every pair of step functions $s$ and $t$ satisfying + \eqref{ref:integral-bounded-function-eq1}. + In other words, $I$ is the one and only number that satisfies + $$a(S) \leq I \leq a(T)$$ for every pair of step regions + $S \subseteq Q \subseteq T$. + By the \nameref{sub:area-exhaustion-property}, $Q$ is measurable and its + area is equal to $I = \int_a^b f(x) \mathop{dx}$. + \end{proof} \subsection{\pending{Theorem 1.11}}% \hyperlabel{sub:theorem-1.11} -\begin{theorem}[1.11] + \begin{theorem}[1.11] + Let $f$ be a nonnegative function, integrable on an interval $[a, b]$. + Then the graph of $f$, that is, the set + \begin{equation} + \hyperlabel{sub:theorem-1.11-eq1} + \{(x, y) \mid a \leq x \leq b, y = f(x)\}, + \end{equation} + is measurable and has area equal to $0$. + \end{theorem} - Let $f$ be a nonnegative function, integrable on an interval $[a, b]$. - Then the graph of $f$, that is, the set - \begin{equation} - \hyperlabel{sub:theorem-1.11-eq1} - \{(x, y) \mid a \leq x \leq b, y = f(x)\}, - \end{equation} - is measurable and has area equal to $0$. + \begin{proof} -\end{theorem} + Let $f$ be a nonnegative function, integrable on an interval $[a, b]$. + Let $$Q' = \{(x, y) \mid a \leq x \leq b, 0 \leq y < f(x)\}.$$ + We show that (i) $Q'$ is measurable with area equal to + $\int_a^b f(x) \mathop{dx}$ and (ii) the graph of $f$ is meaurable with + area equal to $0$. -\begin{proof} + \paragraph{(i)}% + \hyperlabel{par:theorem-1.11-i} - Let $f$ be a nonnegative function, integrable on an interval $[a, b]$. - Let $$Q' = \{(x, y) \mid a \leq x \leq b, 0 \leq y < f(x)\}.$$ - We show that (i) $Q'$ is measurable with area equal to - $\int_a^b f(x) \mathop{dx}$ and (ii) the graph of $f$ is meaurable with area - equal to $0$. + By definition of integrability, there exists one and only one number $I$ + such that + $$\int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}$$ + for every pair of step functions $s$ and $t$ satisfying + \eqref{ref:integral-bounded-function-eq1}. + In other words, $I$ is the one and only number that satisfies + $$a(S) \leq I \leq a(T)$$ for every pair of step regions + $S \subseteq Q' \subseteq T$. + By the \nameref{sub:area-exhaustion-property}, $Q'$ is measurable and its + area is equal to $I = \int_a^b f(x) \mathop{dx}$. - \paragraph{(i)}% - \hyperlabel{par:theorem-1.11-i} + \paragraph{(ii)}% - By definition of integrability, there exists one and only one number $I$ - such that - $$\int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}$$ - for every pair of step functions $s$ and $t$ satisfying - \eqref{ref:integral-bounded-function-eq1}. - In other words, $I$ is the one and only number that satisfies - $$a(S) \leq I \leq a(T)$$ for every pair of step regions - $S \subseteq Q' \subseteq T$. - By the \nameref{sub:area-exhaustion-property}, $Q'$ is measurable and its - area is equal to $I = \int_a^b f(x) \mathop{dx}$. + Let $Q$ denote the ordinate set of $f$. + By \nameref{sub:theorem-1.10}, $Q$ is measurable with area equal to the + integral $I = \int_a^b f(x) \mathop{dx}$. + By \nameref{par:theorem-1.11-i}, $Q'$ is + measurable with area also equal to $I$. + We note the graph of $f$, \eqref{sub:theorem-1.11-eq1}, is equal to set + $Q - Q'$. + By the \nameref{sub:area-difference-property}, $Q - Q'$ is measurable and + $$a(Q - Q') = a(Q) - a(Q') = I - I = 0.$$ + Thus the graph of $f$ is measurable and has area equal to $0$. - \paragraph{(ii)}% - - Let $Q$ denote the ordinate set of $f$. - By \nameref{sub:theorem-1.10}, $Q$ is measurable with area equal to the - integral $I = \int_a^b f(x) \mathop{dx}$. - By \nameref{par:theorem-1.11-i}, $Q'$ is - measurable with area also equal to $I$. - We note the graph of $f$, \eqref{sub:theorem-1.11-eq1}, is equal to set - $Q - Q'$. - By the \nameref{sub:area-difference-property}, $Q - Q'$ is measurable and - $$a(Q - Q') = a(Q) - a(Q') = I - I = 0.$$ - Thus the graph of $f$ is measurable and has area equal to $0$. - -\end{proof} + \end{proof} \section [Integrability of Bounded Monotonic Functions] @@ -2752,250 +2616,240 @@ If $s(x) < t(x)$ for each $x$ in $[a, b]$, then $\int_a^b s < \int_a^b t$. \subsection{\pending{Theorem 1.12}}% \hyperlabel{sub:theorem-1.12} -\begin{theorem}[1.12] + \begin{theorem}[1.12] + If $f$ is \nameref{ref:monotonic} on a closed interval $[a, b]$, then $f$ + is \nameref{ref:integrable} on $[a, b]$. + \end{theorem} - If $f$ is \nameref{ref:monotonic} on a closed interval $[a, b]$, then $f$ - is \nameref{ref:integrable} on $[a, b]$. + \begin{proof} -\end{theorem} + Let $f$ be a monotonic function on closed interval $[a, b]$. + That is to say, either $f$ is increasing on $[a, b]$ or $f$ is decreasing on + $[a, b]$. + Because $f$ is on a closed interval, it is bounded. + By \nameref{sub:theorem-1.9}, $f$ has a \nameref{ref:lower-integral} + $\ubar{I}(f)$, $f$ has an \nameref{ref:upper-integral} $\bar{I}(f)$, + and $f$ is integrable if and only if $\ubar{I}(f) = \bar{I}(f)$. -\begin{proof} + Consider a partition $P = \{x_0, x_1, \ldots, x_n\}$ of $[a, b]$ in which + $x_k - x_{k-1} = (b - a) / n$ for each $k = 1, \ldots, n$. + There are two cases to consider: - Let $f$ be a monotonic function on closed interval $[a, b]$. - That is to say, either $f$ is increasing on $[a, b]$ or $f$ is decreasing on - $[a, b]$. - Because $f$ is on a closed interval, it is bounded. - By \nameref{sub:theorem-1.9}, $f$ has a \nameref{ref:lower-integral} - $\ubar{I}(f)$, $f$ has an \nameref{ref:upper-integral} $\bar{I}(f)$, - and $f$ is integrable if and only if $\ubar{I}(f) = \bar{I}(f)$. + \paragraph{Case 1}% - Consider a partition $P = \{x_0, x_1, \ldots, x_n\}$ of $[a, b]$ in which - $x_k - x_{k-1} = (b - a) / n$ for each $k = 1, \ldots, n$. - There are two cases to consider: + Suppose $f$ is increasing. + Let $s$ be the step function below $f$ with constant value $f(x_{k-1})$ + on every $k$th open subinterval of $P$. + Let $t$ be the step function above $f$ with constant value $f(x_k)$ + on every $k$th open subinterval of $P$. + Then, by \eqref{sub:theorem-1.9-eq1}, it follows + \begin{equation} + \hyperlabel{sub:theorem-1.12-eq1} + \int_a^b s(x) \mathop{dx} \leq \ubar{I}(f) + \leq \bar{I}(f) \leq \int_a^b t(x) \mathop{dx}. + \end{equation} + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] \\ + \int_a^b t(x) \mathop{dx} + & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right]. + \end{align*} + Thus + \begin{align*} + \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right] - + \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] \\ + & = \left[\frac{b - a}{n}\right] \sum_{k=1}^n f(x_k) - f(x_{k-1}) \\ + & = \frac{(b - a)(f(b) - f(a))}{n}. + \end{align*} + By \eqref{sub:theorem-1.12-eq1}, + \begin{align*} + \ubar{I}(f) + & \leq \bar{I}(f) \\ + & \leq \int_a^b t(x) \mathop{dx} \\ + & = \int_a^b s(x) \mathop{dx} + \frac{(b - a)(f(b) - f(a))}{n} \\ + & \leq \ubar{I}(f) + \frac{(b - a)(f(b) - f(a))}{n}. + \end{align*} + Since the above holds for all positive integers $n$, + \nameref{sec:theorem-i.31} indicates $\ubar{I}(f) = \bar{I}(f)$. - \paragraph{Case 1}% + \paragraph{Case 2}% - Suppose $f$ is increasing. - Let $s$ be the step function below $f$ with constant value $f(x_{k-1})$ - on every $k$th open subinterval of $P$. - Let $t$ be the step function above $f$ with constant value $f(x_k)$ - on every $k$th open subinterval of $P$. - Then, by \eqref{sub:theorem-1.9-eq1}, it follows - \begin{equation} - \hyperlabel{sub:theorem-1.12-eq1} - \int_a^b s(x) \mathop{dx} \leq \ubar{I}(f) - \leq \bar{I}(f) \leq \int_a^b t(x) \mathop{dx}. - \end{equation} - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] \\ - \int_a^b t(x) \mathop{dx} - & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right]. - \end{align*} - Thus - \begin{align*} - \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right] - - \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] \\ - & = \left[\frac{b - a}{n}\right] \sum_{k=1}^n f(x_k) - f(x_{k-1}) \\ - & = \frac{(b - a)(f(b) - f(a))}{n}. - \end{align*} - By \eqref{sub:theorem-1.12-eq1}, - \begin{align*} - \ubar{I}(f) - & \leq \bar{I}(f) \\ - & \leq \int_a^b t(x) \mathop{dx} \\ - & = \int_a^b s(x) \mathop{dx} + \frac{(b - a)(f(b) - f(a))}{n} \\ - & \leq \ubar{I}(f) + \frac{(b - a)(f(b) - f(a))}{n}. - \end{align*} - Since the above holds for all positive integers $n$, - \nameref{sec:theorem-i.31} indicates $\ubar{I}(f) = \bar{I}(f)$. + Suppose $f$ is decreasing. + Let $s$ be the step function below $f$ with constant value $f(x_k)$ + on every $k$th open subinterval of $P$. + Let $t$ be the step function above $f$ with constant value $f(x_{k-1})$ + on every $k$th open subinterval of $P$. + Then, by \eqref{sub:theorem-1.9-eq1}, it follows + \begin{equation} + \hyperlabel{sub:theorem-1.12-eq2} + \int_a^b s(x) \mathop{dx} \leq \ubar{I}(f) + \leq \bar{I}(f) \leq \int_a^b t(x) \mathop{dx}. + \end{equation} + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right] \\ + \int_a^b t(x) \mathop{dx} + & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right]. + \end{align*} + Thus + \begin{align*} + \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] - + \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right] \\ + & = \left[\frac{b - a}{n}\right] \sum_{k=1}^n f(x_{k-1}) - f(x_k) \\ + & = \frac{(b - a)(f(a) - f(b))}{n}. + \end{align*} + By \eqref{sub:theorem-1.12-eq2}, + \begin{align*} + \ubar{I}(f) + & \leq \bar{I}(f) \\ + & \leq \int_a^b t(x) \mathop{dx} \\ + & = \int_a^b s(x) \mathop{dx} + \frac{(b - a)(f(a) - f(b))}{n} \\ + & \leq \ubar{I}(f) + \frac{(b - a)(f(a) - f(b))}{n}. + \end{align*} + Since the above holds for all positive integers $n$, + \nameref{sec:theorem-i.31} indicates $\ubar{I}(f) = \bar{I}(f)$. - \paragraph{Case 2}% - - Suppose $f$ is decreasing. - Let $s$ be the step function below $f$ with constant value $f(x_k)$ - on every $k$th open subinterval of $P$. - Let $t$ be the step function above $f$ with constant value $f(x_{k-1})$ - on every $k$th open subinterval of $P$. - Then, by \eqref{sub:theorem-1.9-eq1}, it follows - \begin{equation} - \hyperlabel{sub:theorem-1.12-eq2} - \int_a^b s(x) \mathop{dx} \leq \ubar{I}(f) - \leq \bar{I}(f) \leq \int_a^b t(x) \mathop{dx}. - \end{equation} - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right] \\ - \int_a^b t(x) \mathop{dx} - & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right]. - \end{align*} - Thus - \begin{align*} - \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] - - \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right] \\ - & = \left[\frac{b - a}{n}\right] \sum_{k=1}^n f(x_{k-1}) - f(x_k) \\ - & = \frac{(b - a)(f(a) - f(b))}{n}. - \end{align*} - By \eqref{sub:theorem-1.12-eq2}, - \begin{align*} - \ubar{I}(f) - & \leq \bar{I}(f) \\ - & \leq \int_a^b t(x) \mathop{dx} \\ - & = \int_a^b s(x) \mathop{dx} + \frac{(b - a)(f(a) - f(b))}{n} \\ - & \leq \ubar{I}(f) + \frac{(b - a)(f(a) - f(b))}{n}. - \end{align*} - Since the above holds for all positive integers $n$, - \nameref{sec:theorem-i.31} indicates $\ubar{I}(f) = \bar{I}(f)$. - -\end{proof} + \end{proof} \subsection{\pending{Theorem 1.13}}% \hyperlabel{sub:theorem-1.13} -\begin{theorem}[1.13] + \begin{theorem}[1.13] + Assume $f$ is increasing on a closed interval $[a, b]$. + Let $x_k = a + k(b - a) / n$ for $k = 0, 1, \ldots, n$. + If $I$ is any number which satisfies the inequalities + \begin{equation} + \hyperlabel{sub:theorem-1.13-eq1} + \frac{b - a}{n} \sum_{k=0}^{n-1} f(x_k) + \leq I \leq + \frac{b - a}{n} \sum_{k=1}^n f(x_k) + \end{equation} + for every integer $n \geq 1$, then $I = \int_a^b f(x) \mathop{dx}$. + \end{theorem} - Assume $f$ is increasing on a closed interval $[a, b]$. - Let $x_k = a + k(b - a) / n$ for $k = 0, 1, \ldots, n$. - If $I$ is any number which satisfies the inequalities - \begin{equation} - \hyperlabel{sub:theorem-1.13-eq1} - \frac{b - a}{n} \sum_{k=0}^{n-1} f(x_k) - \leq I \leq - \frac{b - a}{n} \sum_{k=1}^n f(x_k) - \end{equation} - for every integer $n \geq 1$, then $I = \int_a^b f(x) \mathop{dx}$. - -\end{theorem} - -\begin{proof} - - Let $f$ be increasing on a closed interval $[a, b]$ and $I$ be a number - satisfying \eqref{sub:theorem-1.13-eq1}. - Let $s$ be the step function below $f$ with constant value $f(x_{k-1})$ - on every $k$th open subinterval of $P$. - Let $t$ be the step function above $f$ with constant value $f(x_k)$ - on every $k$th open subinterval of $P$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] \\ - & = \sum_{k=0}^{n-1} f(x_k)\left[\frac{b - a}{n}\right] \\ - \int_a^b t(x) \mathop{dx} - & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right]. - \end{align*} - Therefore \eqref{sub:theorem-1.13-eq1} can alternatively be written as - \begin{equation} - \hyperlabel{sub:theorem-1.13-eq2} - \int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}. - \end{equation} - By \nameref{sub:theorem-1.12}, $f$ is integrable. - Therefore \nameref{sub:theorem-1.9} indicates $f$ satisfies - \begin{equation} - \hyperlabel{sub:theorem-1.13-eq3} - \int_a^b s(x) \mathop{dx} - \leq \int_a^b f(x) \mathop{dx} - \leq \int_a^b t(x) \mathop{dx}. - \end{equation} - Manipulating \eqref{sub:theorem-1.13-eq2} and \eqref{sub:theorem-1.13-eq3} - together yields - \begin{align*} - I - \int_a^b f(x) \mathop{dx} - & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}, \\ - \int_a^b f(x) \mathop{dx} - I - & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}. - \end{align*} - Combining the above inequalities in turn yields - \begin{align*} - 0 - & \leq \abs{\int_a^b f(x) \mathop{dx} - I} \\ - & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} \\ - & = \sum_{k=1}^n f(x_k) \left[ \frac{b - a}{n} \right] - - \sum_{k=1}^n f(x_{k-1}) \left[ \frac{b - a}{n} \right] \\ - & = \frac{b - a}{n} \sum_{k=1}^n f(x_k) - f(x_{k-1}) \\ - & = \frac{(b - a)(f(b) - f(a))}{n}. - \end{align*} - The above chain of inequalities holds for all positive integers $n \geq 1$, - meaning \nameref{sec:theorem-i.31} applies. - Thus $$\abs{\int_a^b f(x) \mathop{dx} - I} = 0,$$ which immediately implies - the desired result. - -\end{proof} + \begin{proof} + Let $f$ be increasing on a closed interval $[a, b]$ and $I$ be a number + satisfying \eqref{sub:theorem-1.13-eq1}. + Let $s$ be the step function below $f$ with constant value $f(x_{k-1})$ + on every $k$th open subinterval of $P$. + Let $t$ be the step function above $f$ with constant value $f(x_k)$ + on every $k$th open subinterval of $P$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n f(x_{k-1})\left[\frac{b - a}{n}\right] \\ + & = \sum_{k=0}^{n-1} f(x_k)\left[\frac{b - a}{n}\right] \\ + \int_a^b t(x) \mathop{dx} + & = \sum_{k=1}^n f(x_k)\left[\frac{b - a}{n}\right]. + \end{align*} + Therefore \eqref{sub:theorem-1.13-eq1} can alternatively be written as + \begin{equation} + \hyperlabel{sub:theorem-1.13-eq2} + \int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}. + \end{equation} + By \nameref{sub:theorem-1.12}, $f$ is integrable. + Therefore \nameref{sub:theorem-1.9} indicates $f$ satisfies + \begin{equation} + \hyperlabel{sub:theorem-1.13-eq3} + \int_a^b s(x) \mathop{dx} + \leq \int_a^b f(x) \mathop{dx} + \leq \int_a^b t(x) \mathop{dx}. + \end{equation} + Manipulating \eqref{sub:theorem-1.13-eq2} and \eqref{sub:theorem-1.13-eq3} + together yields + \begin{align*} + I - \int_a^b f(x) \mathop{dx} + & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}, \\ + \int_a^b f(x) \mathop{dx} - I + & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}. + \end{align*} + Combining the above inequalities in turn yields + \begin{align*} + 0 + & \leq \abs{\int_a^b f(x) \mathop{dx} - I} \\ + & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} \\ + & = \sum_{k=1}^n f(x_k) \left[ \frac{b - a}{n} \right] - + \sum_{k=1}^n f(x_{k-1}) \left[ \frac{b - a}{n} \right] \\ + & = \frac{b - a}{n} \sum_{k=1}^n f(x_k) - f(x_{k-1}) \\ + & = \frac{(b - a)(f(b) - f(a))}{n}. + \end{align*} + The above chain of inequalities holds for all positive integers $n \geq 1$, + meaning \nameref{sec:theorem-i.31} applies. + Thus $$\abs{\int_a^b f(x) \mathop{dx} - I} = 0,$$ which immediately implies + the desired result. + \end{proof} \subsection{\pending{Theorem 1.14}}% \hyperlabel{sub:theorem-1.14} -\begin{theorem}[1.14] + \begin{theorem}[1.14] + Assume $f$ is descreasing on $[a, b]$. + Let $x_k = a + k(b - a) / n$ for $k = 0, 1, \ldots, n$. + If $I$ is any number which satisfies the inequalities + \begin{equation} + \hyperlabel{sub:theorem-1.14-eq1} + \frac{b - a}{n} \sum_{k=1}^n f(x_k) + \leq I \leq + \frac{b - a}{n} \sum_{k=0}^{n-1} f(x_k) + \end{equation} + for every integer $n \geq 1$, then $I = \int_a^b f(x) \mathop{dx}$. + \end{theorem} - Assume $f$ is descreasing on $[a, b]$. - Let $x_k = a + k(b - a) / n$ for $k = 0, 1, \ldots, n$. - If $I$ is any number which satisfies the inequalities - \begin{equation} - \hyperlabel{sub:theorem-1.14-eq1} - \frac{b - a}{n} \sum_{k=1}^n f(x_k) - \leq I \leq - \frac{b - a}{n} \sum_{k=0}^{n-1} f(x_k) - \end{equation} - for every integer $n \geq 1$, then $I = \int_a^b f(x) \mathop{dx}$. - -\end{theorem} - -\begin{proof} - - Let $f$ be decreasing on a closed interval $[a, b]$ and $I$ be a number - satisfying \eqref{sub:theorem-1.14-eq1}. - Let $s$ be the step function below $f$ with constant value $f(x_k)$ - on every $k$th open subinterval of $P$. - Let $t$ be the step function above $f$ with constant value $f(x_{k-1})$ - on every $k$th open subinterval of $P$. - By definition of the \nameref{ref:integral-step-function}, - \begin{align*} - \int_a^b s(x) \mathop{dx} - & = \sum_{k=1}^n f(x_k) \left[\frac{b - a}{n}\right] \\ - \int_a^b t(x) \mathop{dx} - & = \sum_{k=1}^n f(x_{k-1}) \left[\frac{b - a}{n}\right] \\ - & = \sum_{k=0}^{n-1} f(x) \left[\frac{b - a}{n}\right]. - \end{align*} - Therefore \eqref{sub:theorem-1.14-eq1} can alternatively be written as - \begin{equation} - \hyperlabel{sub:theorem-1.14-eq2} - \int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}. - \end{equation} - By \nameref{sub:theorem-1.12}, $f$ is integrable. - Therefore \nameref{sub:theorem-1.9} indicates $f$ satisfies - \begin{equation} - \hyperlabel{sub:theorem-1.14-eq3} - \int_a^b s(x) \mathop{dx} - \leq \int_a^b f(x) \mathop{dx} - \leq \int_a^b t(x) \mathop{dx}. - \end{equation} - Manipulating \eqref{sub:theorem-1.14-eq2} and \eqref{sub:theorem-1.14-eq3} - together yields - \begin{align*} - I - \int_a^b f(x) \mathop{dx} - & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}, \\ - \int_a^b f(x) \mathop{dx} - I - & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}. - \end{align*} - Combining the above inequalities in turn yields - \begin{align*} - 0 - & \leq \abs{\int_a^b f(x) \mathop{dx} - I} \\ - & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} \\ - & = \sum_{k=1}^n f(x_k) \left[ \frac{b - a}{n} \right] - - \sum_{k=1}^n f(x_{k-1}) \left[ \frac{b - a}{n} \right] \\ - & = \frac{b - a}{n} \sum_{k=1}^n f(x_k) - f(x_{k-1}) \\ - & = \frac{(b - a)(f(b) - f(a))}{n}. - \end{align*} - The above chain of inequalities holds for all positive integers $n \geq 1$, - meaning \nameref{sec:theorem-i.31} applies. - Thus $$\abs{\int_a^b f(x) \mathop{dx} - I} = 0,$$ which immediately implies - the desired result. - -\end{proof} + \begin{proof} + Let $f$ be decreasing on a closed interval $[a, b]$ and $I$ be a number + satisfying \eqref{sub:theorem-1.14-eq1}. + Let $s$ be the step function below $f$ with constant value $f(x_k)$ + on every $k$th open subinterval of $P$. + Let $t$ be the step function above $f$ with constant value $f(x_{k-1})$ + on every $k$th open subinterval of $P$. + By definition of the \nameref{ref:integral-step-function}, + \begin{align*} + \int_a^b s(x) \mathop{dx} + & = \sum_{k=1}^n f(x_k) \left[\frac{b - a}{n}\right] \\ + \int_a^b t(x) \mathop{dx} + & = \sum_{k=1}^n f(x_{k-1}) \left[\frac{b - a}{n}\right] \\ + & = \sum_{k=0}^{n-1} f(x) \left[\frac{b - a}{n}\right]. + \end{align*} + Therefore \eqref{sub:theorem-1.14-eq1} can alternatively be written as + \begin{equation} + \hyperlabel{sub:theorem-1.14-eq2} + \int_a^b s(x) \mathop{dx} \leq I \leq \int_a^b t(x) \mathop{dx}. + \end{equation} + By \nameref{sub:theorem-1.12}, $f$ is integrable. + Therefore \nameref{sub:theorem-1.9} indicates $f$ satisfies + \begin{equation} + \hyperlabel{sub:theorem-1.14-eq3} + \int_a^b s(x) \mathop{dx} + \leq \int_a^b f(x) \mathop{dx} + \leq \int_a^b t(x) \mathop{dx}. + \end{equation} + Manipulating \eqref{sub:theorem-1.14-eq2} and \eqref{sub:theorem-1.14-eq3} + together yields + \begin{align*} + I - \int_a^b f(x) \mathop{dx} + & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}, \\ + \int_a^b f(x) \mathop{dx} - I + & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx}. + \end{align*} + Combining the above inequalities in turn yields + \begin{align*} + 0 + & \leq \abs{\int_a^b f(x) \mathop{dx} - I} \\ + & \leq \int_a^b t(x) \mathop{dx} - \int_a^b s(x) \mathop{dx} \\ + & = \sum_{k=1}^n f(x_k) \left[ \frac{b - a}{n} \right] - + \sum_{k=1}^n f(x_{k-1}) \left[ \frac{b - a}{n} \right] \\ + & = \frac{b - a}{n} \sum_{k=1}^n f(x_k) - f(x_{k-1}) \\ + & = \frac{(b - a)(f(b) - f(a))}{n}. + \end{align*} + The above chain of inequalities holds for all positive integers $n \geq 1$, + meaning \nameref{sec:theorem-i.31} applies. + Thus $$\abs{\int_a^b f(x) \mathop{dx} - I} = 0,$$ which immediately implies + the desired result. + \end{proof} \subsection{\sorry{% Integral of \texorpdfstring{$\int_0^b x^p \mathop{dx}$}{int-x-p} when @@ -3003,17 +2857,13 @@ If $s(x) < t(x)$ for each $x$ in $[a, b]$, then $\int_a^b s < \int_a^b t$. \hyperlabel{sub:calculation-integral-int-x-p-p-positive-integer} \hyperlabel{sub:theorem-1.15} -\begin{theorem}[1.15] + \begin{theorem}[1.15] + If $p$ is a positive integer and $b > 0$, we have + $$\int_0^b x^p \mathop{dx} = \frac{b^{p+1}}{p+1}.$$ + \end{theorem} - If $p$ is a positive integer and $b > 0$, we have - $$\int_0^b x^p \mathop{dx} = \frac{b^{p+1}}{p+1}.$$ - -\end{theorem} - -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \end{document} diff --git a/Bookshelf/Enderton/Logic.tex b/Bookshelf/Enderton/Logic.tex index 3ebb186..c7f06b3 100644 --- a/Bookshelf/Enderton/Logic.tex +++ b/Bookshelf/Enderton/Logic.tex @@ -18,41 +18,42 @@ \section{\defined{Construction Sequence}}% \hyperlabel{ref:construction-sequence} -A \textbf{construction sequence} is a finite sequence - $\langle \epsilon_1, \ldots, \epsilon_n \rangle$ of expressions such that for - each $i \leq n$ we have at least one of - \begin{align*} - & \epsilon_i \text{ is a sentence symbol} \\ - & \epsilon_i = \mathcal{E}_\neg(\epsilon_j) \text{ for some } j < i \\ - & \epsilon_i = \mathcal{E}_\square(\epsilon_j, \epsilon_k) - \text{ for some } j < i, k < i - \end{align*} - where $\square$ is one of the binary connectives $\land$, $\lor$, - $\Rightarrow$, $\Leftrightarrow$. + A \textbf{construction sequence} is a finite sequence + $\langle \epsilon_1, \ldots, \epsilon_n \rangle$ of expressions such that + for each $i \leq n$ we have at least one of + \begin{align*} + & \epsilon_i \text{ is a sentence symbol} \\ + & \epsilon_i = \mathcal{E}_\neg(\epsilon_j) \text{ for some } j < i \\ + & \epsilon_i = \mathcal{E}_\square(\epsilon_j, \epsilon_k) + \text{ for some } j < i, k < i + \end{align*} + where $\square$ is one of the binary connectives $\land$, $\lor$, + $\Rightarrow$, $\Leftrightarrow$. \section{\defined{Expression}}% \hyperlabel{ref:expression} -An \textbf{expression} is a finite sequence of symbols. + An \textbf{expression} is a finite sequence of symbols. \section{\defined{Well-Formed Formula}}% \hyperlabel{ref:well-formed-formula} -An \nameref{ref:expression} that can be built up from the sentence symbols by - applying some finite number of times the \textbf{formula-building operations} - (on expressions) defined by the equations: - \begin{align*} - \mathcal{E}_{\neg}(\alpha) - & = (\neg \alpha) \\ - \mathcal{E}_{\land}(\alpha, \beta) - & = (\alpha \land \beta) \\ - \mathcal{E}_{\lor}(\alpha, \beta) - & = (\alpha \lor \beta) \\ - \mathcal{E}_{\Rightarrow}(\alpha, \beta) - & = (\alpha \Rightarrow \beta) \\ - \mathcal{E}_{\Leftrightarrow}(\alpha, \beta) - & = (\alpha \Leftrightarrow \beta) - \end{align*} + An \nameref{ref:expression} that can be built up from the sentence symbols by + applying some finite number of times the + \textbf{formula-building operations} (on expressions) defined by the + equations: + \begin{align*} + \mathcal{E}_{\neg}(\alpha) + & = (\neg \alpha) \\ + \mathcal{E}_{\land}(\alpha, \beta) + & = (\alpha \land \beta) \\ + \mathcal{E}_{\lor}(\alpha, \beta) + & = (\alpha \lor \beta) \\ + \mathcal{E}_{\Rightarrow}(\alpha, \beta) + & = (\alpha \Rightarrow \beta) \\ + \mathcal{E}_{\Leftrightarrow}(\alpha, \beta) + & = (\alpha \Leftrightarrow \beta) + \end{align*} \endgroup @@ -65,19 +66,15 @@ An \nameref{ref:expression} that can be built up from the sentence symbols by \section{\sorry{Lemma 0A}}% \hyperlabel{sec:lemma-0a} -\begin{lemma}[0A] + \begin{lemma}[0A] + Assume that $\langle x_1, \ldots, x_m \rangle = + \langle y_1, \ldots, y_m, \ldots, y_{m+k} \rangle$. + Then $x_1 = \langle y_1, \ldots, y_{k+1} \rangle$. + \end{lemma} -Assume that $\langle x_1, \ldots, x_m \rangle = - \langle y_1, \ldots, y_m, \ldots, y_{m+k} \rangle$. -Then $x_1 = \langle y_1, \ldots, y_{k+1} \rangle$. - -\end{lemma} - -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \chapter{Sentential Logic}% \hyperlabel{chap:sentential-logic} @@ -88,18 +85,15 @@ Then $x_1 = \langle y_1, \ldots, y_{k+1} \rangle$. \subsection{\sorry{Induction Principle}}% \hyperlabel{sub:induction-principle-1} -\begin{theorem} + \begin{theorem} + If $S$ is a set of wffs containing all the sentence symbols and closed under + all five formula-building operations, then $S$ is the set of \textit{all} + wffs. + \end{theorem} -If $S$ is a set of wffs containing all the sentence symbols and closed under all - five formula-building operations, then $S$ is the set of \textit{all} wffs. - -\end{theorem} - -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \section{Exercises 1}% \hyperlabel{sec:exercises-1} @@ -107,92 +101,81 @@ If $S$ is a set of wffs containing all the sentence symbols and closed under all \subsection{\sorry{Exercise 1.1.1}}% \hyperlabel{sub:exercise-1.1.1} -Give three sentences in English together with translations into our formal - language. -The sentences shoudl be chosen so as to have an interesting structure, and the - translations should each contain 15 or more symbols. + Give three sentences in English together with translations into our formal + language. + The sentences shoudl be chosen so as to have an interesting structure, and the + translations should each contain 15 or more symbols. -\begin{answer} - - TODO - -\end{answer} + \begin{answer} + TODO + \end{answer} \subsection{\sorry{Exercise 1.1.2}}% \hyperlabel{sub:exercise-1.1.2} -Show that there are no wffs of length 2, 3, or 6, but that any other positive - length is possible. + Show that there are no wffs of length 2, 3, or 6, but that any other positive + length is possible. -\begin{answer} - - TODO - -\end{answer} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 1.1.3}}% \hyperlabel{sub:exercise-1.1.3} -Let $\alpha$ be a wff; let $c$ be the number of places at which binary - connective symbols $(\land, \lor, \Rightarrow, \Leftrightarrow)$ occur in - $\alpha$; let $s$ be the number of places at which sentence symbols occur in - $\alpha$. -(For exmaple, if $\alpha$ is $(A \Rightarrow (\neg A))$ then $c = 1$ and $s = 2$.) -Show by using the induction principle that $s = c + 1$. + Let $\alpha$ be a wff; let $c$ be the number of places at which binary + connective symbols $(\land, \lor, \Rightarrow, \Leftrightarrow)$ occur in + $\alpha$; let $s$ be the number of places at which sentence symbols occur in + $\alpha$. + (For example, if $\alpha$ is $(A \Rightarrow (\neg A))$ then $c = 1$ and + $s = 2$.) + Show by using the induction principle that $s = c + 1$. -\begin{answer} - - TODO - -\end{answer} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 1.1.4}}% \hyperlabel{sub:exercise-1.1.4} -Assume we have a construction sequence ending in $\phi$, where $\phi$ does not - contain the symbol $A_4$. -Suppose we delete all the expressions in the construction sequence that contain - $A_4$. -Show that the result is still a legal construction sequence. + Assume we have a construction sequence ending in $\phi$, where $\phi$ does not + contain the symbol $A_4$. + Suppose we delete all the expressions in the construction sequence that + contain $A_4$. + Show that the result is still a legal construction sequence. -\begin{answer} - - TODO - -\end{answer} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 1.1.5}}% \hyperlabel{sub:exercise-1.1.5} -Suppose that $\alpha$ is a wff not containing the negation symbol $\neg$. -\begin{enumerate}[(a)] - \item Show that the length of $\alpha$ (i.e., the number of symbols in the - string) is odd. - \item Show that more than a quarter of the symbols are sentence symbols. -\end{enumerate} -\textit{Suggestion}: Apply induction to show that the length is of the form - $4k + 1$ and the number of sentence symbols is $k + 1$. + Suppose that $\alpha$ is a wff not containing the negation symbol $\neg$. + \begin{enumerate}[(a)] + \item Show that the length of $\alpha$ (i.e., the number of symbols in the + string) is odd. + \item Show that more than a quarter of the symbols are sentence symbols. + \end{enumerate} + \textit{Suggestion}: Apply induction to show that the length is of the form + $4k + 1$ and the number of sentence symbols is $k + 1$. -\begin{answer} - - TODO - -\end{answer} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 1.1.6}}% \hyperlabel{sub:exercise-1.1.6} -Suppose that $\alpha$ is a wff not containing the negation symbol $\neg$. -\begin{enumerate}[(a)] - \item Show that the length of $\alpha$ (i.e., the number of symbols in the - string) is odd. - \item Show that more than a quarter of the symbols are sentence symbols. -\end{enumerate} + Suppose that $\alpha$ is a wff not containing the negation symbol $\neg$. + \begin{enumerate}[(a)] + \item Show that the length of $\alpha$ (i.e., the number of symbols in the + string) is odd. + \item Show that more than a quarter of the symbols are sentence symbols. + \end{enumerate} -\begin{answer} - - TODO - -\end{answer} + \begin{proof} + TODO + \end{proof} \end{document} diff --git a/Bookshelf/Enderton/Set.tex b/Bookshelf/Enderton/Set.tex index dd9f7b9..e28c5ec 100644 --- a/Bookshelf/Enderton/Set.tex +++ b/Bookshelf/Enderton/Set.tex @@ -24,735 +24,529 @@ \hyperlabel{chap:reference} \section{\defined{Addition}}% -\label{ref:addition} +\hyperlabel{ref:addition} -For each $m \in \omega$, there exists (by the - \nameref{sub:recursion-theorem-natural-numbers}) a unique - \nameref{ref:function} $A_m \colon \omega \rightarrow \omega$ for which - \begin{align*} - A_m(0) & = m, \\ - A_m(n^+) & = A_m(n)^+ & \text{for } n \text{ in } \omega. - \end{align*} -\textbf{Addition} ($+$) is the \nameref{ref:binary-operation} on $\omega$ such - that for any $m$ and $n$ in $\omega$, $$m + n = A_m(n).$$ + For each $m \in \omega$, there exists (by the + \nameref{sub:recursion-theorem-natural-numbers}) a unique + \nameref{ref:function} $A_m \colon \omega \rightarrow \omega$ for which + \begin{align*} + A_m(0) & = m, \\ + A_m(n^+) & = A_m(n)^+ & \text{for } n \text{ in } \omega. + \end{align*} + \textbf{Addition} ($+$) is the \nameref{ref:binary-operation} on $\omega$ such + that for any $m$ and $n$ in $\omega$, $$m + n = A_m(n).$$ -\begin{definition} - - \lean*{Init/Prelude}{Add.add} - -\end{definition} + \lean{Init/Prelude}{Add.add} \section{\defined{Axiom of Choice, First Form}}% \hyperlabel{ref:axiom-of-choice-1} -For any relation $R$ there is a function $H \subseteq R$ with - $\dom{H} = \dom{R}$. - -\begin{axiom} + For any relation $R$ there is a function $H \subseteq R$ with + $\dom{H} = \dom{R}$. \lean*{Init/Prelude}{Classical.choice} -\end{axiom} - \section{\defined{Axiom of Choice, Second Form}}% \hyperlabel{ref:axiom-of-choice-2} -For any set $I$ and any function $H$ with domain $I$, if $H(i) \neq \emptyset$ - for all $i \in I$, then $$\bigtimes_{i \in I} H(i) \neq \emptyset.$$ + For any set $I$ and any function $H$ with domain $I$, if $H(i) \neq \emptyset$ + for all $i \in I$, then $$\bigtimes_{i \in I} H(i) \neq \emptyset.$$ -\begin{axiom} - - \lean*{Init/Prelude}{Classical.choice} - -\end{axiom} + \lean{Init/Prelude}{Classical.choice} \section{\defined{Binary Operation}}% \hyperlabel{ref:binary-operation} -A \textbf{binary operation} on a set $A$ is a \nameref{ref:function} from - $A \times A$ into $A$. + A \textbf{binary operation} on a set $A$ is a \nameref{ref:function} from + $A \times A$ into $A$. \section{\defined{Cartesian Product}}% \hyperlabel{ref:cartesian-product} -Let $I$ be a set and let $H$ be a \nameref{ref:function} whose domain includes $I$. -Then for each $i$ in $I$ we have the set $H(i)$. -We define the \textbf{cartesian product} of the $H(i)$'s as - $$\bigtimes_{i \in I} H(i) = \{f \mid - f \text{ is a function with domain } I \text{ and } - (\forall i \in I) f(i) \in H(i)\}.$$ + Let $I$ be a set and let $H$ be a \nameref{ref:function} whose domain includes + $I$. + Then for each $i$ in $I$ we have the set $H(i)$. + We define the \textbf{cartesian product} of the $H(i)$'s as + $$\bigtimes_{i \in I} H(i) = \{f \mid + f \text{ is a function with domain } I \text{ and } + (\forall i \in I) f(i) \in H(i)\}.$$ -\begin{definition} - - \lean*{Mathlib/Data/Set/Prod}{Set.prod} - -\end{definition} + \lean{Mathlib/Data/Set/Prod}{Set.prod} \section{\defined{Compatible}}% \hyperlabel{ref:compatible} -A \nameref{ref:function} $F$ is \textbf{compatible} with relation $R$ if and - only if for all $x$ and $y$ in $A$, - $$xRy \Rightarrow F(x)RF(y).$$ + A \nameref{ref:function} $F$ is \textbf{compatible} with relation $R$ if and + only if for all $x$ and $y$ in $A$, + $$xRy \Rightarrow F(x)RF(y).$$ -\begin{definition} - - \lean*{Init/Core}{Quotient.lift} - -\end{definition} + \lean{Init/Core}{Quotient.lift} \section{\defined{Composition}}% \hyperlabel{ref:composition} -The \textbf{composition} of sets $F$ and $G$ is - $$F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}.$$ + The \textbf{composition} of sets $F$ and $G$ is + $$F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}.$$ -\begin{definition} + \lean{Mathlib/Data/Rel}{Rel.comp} - \statementpadding - - \lean*{Mathlib/Data/Rel}{Rel.comp} - - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.comp} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.comp} \section{\defined{Connected}}% \hyperlabel{ref:connected} -A binary relation $R$ on $A$ is \textbf{connected} if for distinct $x, y \in A$, - either $xRy$ or $yRx$. - -\begin{definition} + A binary relation $R$ on $A$ is \textbf{connected} if for distinct + $x, y \in A$, either $xRy$ or $yRx$. \lean*{Common/Algebra/Classes}{IsConnected} -\end{definition} - \section{\defined{Domain}}% \hyperlabel{ref:domain} -The \textbf{domain} of set $R$, denoted $\dom{R}$, is given by - $$x \in \dom{R} \iff \exists y \pair{x, y} \in R.$$ + The \textbf{domain} of set $R$, denoted $\dom{R}$, is given by + $$x \in \dom{R} \iff \exists y \pair{x, y} \in R.$$ -\begin{definition} + \lean{Mathlib/Data/Rel}{Rel.dom} - \statementpadding - - \lean*{Mathlib/Data/Rel}{Rel.dom} - - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.dom} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.dom} \section{\defined{Empty Set Axiom}}% \hyperlabel{ref:empty-set-axiom} -There is a set having no members: - $$\exists B, \forall x, x \not\in B.$$ + There is a set having no members: $$\exists B, \forall x, x \not\in B.$$ -\begin{axiom} - - \lean*{Mathlib/Init/Set}{Set.emptyCollection} - -\end{axiom} + \lean{Mathlib/Init/Set}{Set.emptyCollection} \section{\defined{Equivalence Class}}% \hyperlabel{ref:equivalence-class} -The set $[x]_R$ is defined by $$[x]_R = \{t \mid xRt\}.$$ -If $R$ is an \nameref{ref:equivalence-relation} and $x \in \fld{R}$, then - $[x]_R$ is called the \textbf{equivalence class} of $x$ (\textbf{modulo $R$}). -If the relation $R$ is fixed by the context, we may write just $[x]$. - -\begin{definition} + The set $[x]_R$ is defined by $$[x]_R = \{t \mid xRt\}.$$ + If $R$ is an \nameref{ref:equivalence-relation} and $x \in \fld{R}$, then + $[x]_R$ is called the \textbf{equivalence class} of $x$ + (\textbf{modulo $R$}). + If the relation $R$ is fixed by the context, we may write just $[x]$. \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.modEquiv} -\end{definition} - \section{\defined{Equivalence Relation}}% \hyperlabel{ref:equivalence-relation} -Relation $R$ is an \textbf{equivalence relation} on set $A$ if and only if - $R$ is a binary \nameref{ref:relation} on $A$ that is \nameref{ref:reflexive} - on $A$, \nameref{ref:symmetric}, and \nameref{ref:transitive}. - -\begin{definition} + Relation $R$ is an \textbf{equivalence relation} on set $A$ if and only if + $R$ is a binary \nameref{ref:relation} on $A$ that is \nameref{ref:reflexive} + on $A$, \nameref{ref:symmetric}, and \nameref{ref:transitive}. \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.isEquivalence} -\end{definition} - \section{\defined{Exponentiation}}% \hyperlabel{ref:exponentiation} -For each $m \in \omega$, there exists (by the - \nameref{sub:recursion-theorem-natural-numbers}) a unique - \nameref{ref:function} $E_m \colon \omega \rightarrow \omega$ for which - \begin{align*} - E_m(0) & = 1, \\ - E_m(n^+) & = E_m(n) \cdot m & \text{for } n \text{ in } \omega. - \end{align*} -\textbf{Exponentiation} is the \nameref{ref:binary-operation} on $\omega$ - such that for any $m$ and $n$ in $\omega$, $$m^n = E_m(n).$$ + For each $m \in \omega$, there exists (by the + \nameref{sub:recursion-theorem-natural-numbers}) a unique + \nameref{ref:function} $E_m \colon \omega \rightarrow \omega$ for which + \begin{align*} + E_m(0) & = 1, \\ + E_m(n^+) & = E_m(n) \cdot m & \text{for } n \text{ in } \omega. + \end{align*} + \textbf{Exponentiation} is the \nameref{ref:binary-operation} on $\omega$ + such that for any $m$ and $n$ in $\omega$, $$m^n = E_m(n).$$ -\begin{definition} - - \lean*{Init/Prelude}{Pow.pow} - -\end{definition} + \lean{Init/Prelude}{Pow.pow} \section{\defined{Extensionality Axiom}}% \hyperlabel{ref:extensionality-axiom} -If two sets have exactly the same members, then they are equal: - $$\forall A, \forall B, - \left[\forall x, (x \in A \iff x \in B) \Rightarrow A = B\right].$$ + If two sets have exactly the same members, then they are equal: + $$\forall A, \forall B, + \left[\forall x, (x \in A \iff x \in B) \Rightarrow A = B\right].$$ -\begin{axiom} - - \lean*{Mathlib/Init/Set}{Set.ext} - -\end{axiom} + \lean{Mathlib/Init/Set}{Set.ext} \section{\defined{Field}}% \hyperlabel{ref:field} -Given \nameref{ref:relation} $R$, the \textbf{field} of $R$, denoted $\fld{R}$, - is given by $$\fld{R} = \dom{R} \cup \ran{R}.$$ + Given \nameref{ref:relation} $R$, the \textbf{field} of $R$, denoted $\fld{R}$, + is given by $$\fld{R} = \dom{R} \cup \ran{R}.$$ -\begin{definition} - - \lean*{Bookshelf/Enderton/Set/Relation}{Set.Relation.fld} - -\end{definition} + \lean{Bookshelf/Enderton/Set/Relation}{Set.Relation.fld} \section{\defined{Function}}% \hyperlabel{ref:function} -A \textbf{function} is a relation $F$ such that for each $x$ in $\dom{F}$ there - is only one $y$ such that $xFy$. -In other words, $F$ is \textbf{single-valued}. + A \textbf{function} is a relation $F$ such that for each $x$ in $\dom{F}$ + there is only one $y$ such that $xFy$. + In other words, $F$ is \textbf{single-valued}. -We say that $F$ is a function \textbf{from $A$ into $B$} or that $F$ - \textbf{maps $A$ into $B$} (written $F \colon A \rightarrow B$) iff $F$ is a - function, $\dom{F} = A$, and $\ran{F} \subseteq B$. -If $\ran{F} = B$, then $F$ is a function from \textbf{$A$ onto $B$}. + We say that $F$ is a function \textbf{from $A$ into $B$} or that $F$ + \textbf{maps $A$ into $B$} (written $F \colon A \rightarrow B$) iff $F$ is a + function, $\dom{F} = A$, and $\ran{F} \subseteq B$. + If $\ran{F} = B$, then $F$ is a function from \textbf{$A$ onto $B$}. -A function $F$ is \textbf{one-to-one} iff for each $y \in \ran{F}$ there is only - one $x$ such that $xFy$. -One-to-one functions are sometimes called \textbf{injections}. - -\begin{definition} - - \statementpadding + A function $F$ is \textbf{one-to-one} iff for each $y \in \ran{F}$ there is + only one $x$ such that $xFy$. + One-to-one functions are sometimes called \textbf{injections}. \lean*{Mathlib/Init/Function}{Function.Injective} - \lean*{Mathlib/Init/Function}{Function.Surjective} + \lean{Mathlib/Init/Function}{Function.Surjective} - \lean*{Mathlib/Init/Function}{Function.Bijective} - -\end{definition} + \lean{Mathlib/Init/Function}{Function.Bijective} \section{\defined{Image}}% \hyperlabel{ref:image} -Let $A$ and $F$ be arbitrary sets. -The \textbf{image of $A$ under $F$} is the set - \begin{align*} - \img{F}{A} - & = \ran{(F \restriction A)} \\ - & = \{v \mid (\exists u \in A) uFv\}. - \end{align*} + Let $A$ and $F$ be arbitrary sets. + The \textbf{image of $A$ under $F$} is the set + \begin{align*} + \img{F}{A} + & = \ran{(F \restriction A)} \\ + & = \{v \mid (\exists u \in A) uFv\}. + \end{align*} -\begin{definition} + \lean{Mathlib/Data/Rel}{Rel.image} - \statementpadding - - \lean*{Mathlib/Data/Rel}{Rel.image} - - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.image} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.image} \section{\defined{Inductive Set}}% \hyperlabel{ref:inductive-set} -A set $A$ is said to be \textit{inductive} if and only if $\emptyset \in A$ and - it is "closed under \nameref{ref:successor}", i.e. - $$(\forall a \in A) a^+ \in A.$$ + A set $A$ is said to be \textit{inductive} if and only if $\emptyset \in A$ + and it is "closed under \nameref{ref:successor}", i.e. + $$(\forall a \in A) a^+ \in A.$$ -\begin{note} - Induction is baked into Lean's type system. - In particular, the $\emptyset$ and "closed under successor" properties are - analagous to base and recursive constructors of an inductive data type - respectively. -\end{note} + \begin{note} + Induction is baked into Lean's type system. + In particular, the $\emptyset$ and "closed under successor" properties are + analagous to base and recursive constructors of an inductive data type + respectively. + \end{note} -\begin{definition} + \lean{Prelude}{Nat} - \statementpadding - - \lean*{Prelude}{Nat} - - \lean*{Mathlib/Init/Set}{Set.univ} - -\end{definition} + \lean{Mathlib/Init/Set}{Set.univ} \section{\defined{Infinity Axiom}}% \hyperlabel{ref:infinity-axiom} -There exists an \nameref{ref:inductive-set}: - $$(\exists A)\left[ \emptyset \in A \land (\forall a \in A) a^+ \in A \right].$$ + There exists an \nameref{ref:inductive-set}: + $$(\exists A)\left[ + \emptyset \in A \land (\forall a \in A) a^+ \in A\right].$$ -\begin{note} - Since the definition of natural numbers in Lean satisfies the properties - required by this axiom, there is no need to explicitly state the axiom - separately in Lean. -\end{note} + \begin{note} + Since the definition of natural numbers in Lean satisfies the properties + required by this axiom, there is no need to explicitly state the axiom + separately in Lean. + \end{note} -\begin{axiom} + \lean{Prelude}{Nat} - \statementpadding - - \lean*{Prelude}{Nat} - - \lean*{Mathlib/Init/Set}{Set.univ} - -\end{axiom} + \lean{Mathlib/Init/Set}{Set.univ} \section{\defined{Inverse}}% \hyperlabel{ref:inverse} -The \textbf{inverse} of a set $F$ is the set - $$F^{-1} = \{\pair{u, v} \mid vFu\}.$$ + The \textbf{inverse} of a set $F$ is the set + $$F^{-1} = \{\pair{u, v} \mid vFu\}.$$ -\begin{definition} + \lean{Mathlib/Data/Rel}{Rel.inv} - \statementpadding - - \lean*{Mathlib/Data/Rel}{Rel.inv} - - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.inv} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.inv} \section{\defined{Irreflexive}}% \hyperlabel{ref:irreflexive} -A binary relation $R$ on set $A$ is \textbf{irreflexive} if there is no - $x \in A$ for which $xRx$. - -\begin{definition} + A binary relation $R$ on set $A$ is \textbf{irreflexive} if there is no + $x \in A$ for which $xRx$. \lean*{Mathlib/Init/Algebra/Classes}{IsIrrefl} -\end{definition} - \section{\defined{Linear Ordering}} \hyperlabel{ref:linear-ordering} -Let $A$ be any set. -A \textbf{linear ordering} on $A$ (also called a \textbf{total ordering} on $A$) - is a binary relation $R$ on $A$ (i.e., $R \subseteq A \times A$) meeting the - following two conditions: + Let $A$ be any set. + A \textbf{linear ordering} on $A$ (also called a \textbf{total ordering} on + $A$) is a binary relation $R$ on $A$ (i.e., $R \subseteq A \times A$) + meeting the following two conditions: -\begin{enumerate}[(a)] - \item $R$ is \nameref{ref:transitive}. - \item $R$ is \nameref{ref:trichotomous}. -\end{enumerate} - -\begin{note} - This definition does not agree with how Lean defines a linear order. - - \vspace{6pt} - Trichotomy is equivalent to asymmetry and connectivity and asymmetry is - equivalent to antisymmetry and irreflexivity. - Thus a linear order, as defined by Enderton, is a binary relation with the - following four properties: - - \vspace{6pt} - \begin{enumerate}[(i)] - \item Irreflexivity - \item Antisymmetry - \item Connectivity (i.e. totality) - \item Transitivity + \begin{enumerate}[(a)] + \item $R$ is \nameref{ref:transitive}. + \item $R$ is \nameref{ref:trichotomous}. \end{enumerate} -\end{note} -\begin{definition} + \begin{note} + This definition does not agree with how Lean defines a linear order. - \lean*{Mathlib/Init/Algebra/Classes}{IsStrictTotalOrder} + \vspace{6pt} + Trichotomy is equivalent to asymmetry and connectivity and asymmetry is + equivalent to antisymmetry and irreflexivity. + Thus a linear order, as defined by Enderton, is a binary relation with the + following four properties: -\end{definition} + \vspace{6pt} + \begin{enumerate}[(i)] + \item Irreflexivity + \item Antisymmetry + \item Connectivity (i.e. totality) + \item Transitivity + \end{enumerate} + \end{note} + + \lean{Mathlib/Init/Algebra/Classes}{IsStrictTotalOrder} \section{\defined{Multiplication}}% \hyperlabel{ref:multiplication} -For each $m \in \omega$, there exists (by the - \nameref{sub:recursion-theorem-natural-numbers}) a unique - \nameref{ref:function} $M_m \colon \omega \rightarrow \omega$ for which - \begin{align*} - M_m(0) & = 0, \\ - M_m(n^+) & = M_m(n) + m. - \end{align*} -\textbf{Multiplication} ($\cdot$) is the \nameref{ref:binary-operation} on - $\omega$ such that for any $m$ and $n$ in $\omega$, $$m \cdot n = M_m(n).$$ + For each $m \in \omega$, there exists (by the + \nameref{sub:recursion-theorem-natural-numbers}) a unique + \nameref{ref:function} $M_m \colon \omega \rightarrow \omega$ for which + \begin{align*} + M_m(0) & = 0, \\ + M_m(n^+) & = M_m(n) + m. + \end{align*} + \textbf{Multiplication} ($\cdot$) is the \nameref{ref:binary-operation} on + $\omega$ such that for any $m$ and $n$ in $\omega$, $$m \cdot n = M_m(n).$$ -\begin{definition} - - \lean*{Init/Prelude}{Mul.mul} - -\end{definition} + \lean{Init/Prelude}{Mul.mul} \section{\defined{Natural Number}}% \hyperlabel{ref:natural-number} -A \textbf{natural number} is a set that belongs to every inductive set. -The set of all natural numbers exists by virtue of \nameref{sub:theorem-4a}. -This set is denoted as $\omega$. - -\begin{definition} + A \textbf{natural number} is a set that belongs to every inductive set. + The set of all natural numbers exists by virtue of \nameref{sub:theorem-4a}. + This set is denoted as $\omega$. \lean*{Prelude}{Nat} -\end{definition} - \section{\defined{Ordered Pair}}% \hyperlabel{ref:ordered-pair} -For any sets $u$ and $v$, the \textbf{ordered pair} $\pair{u, v}$ is - the set $\{\{u\}, \{u, v\}\}$. - -\begin{definition} - - \statementpadding + For any sets $u$ and $v$, the \textbf{ordered pair} $\pair{u, v}$ is + the set $\{\{u\}, \{u, v\}\}$. \lean*{Prelude}{Prod} - \code*{Bookshelf/Enderton/Set/OrderedPair}{OrderedPair} - -\end{definition} + \code{Bookshelf/Enderton/Set/OrderedPair}{OrderedPair} \section{\defined{Ordering on \texorpdfstring{$\omega$}{Natural Numbers}}}% \hyperlabel{ref:ordering-natural-numbers} -For \nameref{ref:natural-number}s $m$ and $n$, define $m$ to be - \textbf{less than} $n$ if and only if $m \in n$. -That is, $$m < n \iff m \in n.$$ -Likewise, define $m$ to be \textbf{less than or equal to} $n$ if and only if - $m \in n \lor m = n$. -That is, - \begin{align*} - m \leq n - & \iff m \ineq n \\ - & \iff m < n \lor m = n. - \end{align*} + For \nameref{ref:natural-number}s $m$ and $n$, define $m$ to be + \textbf{less than} $n$ if and only if $m \in n$. + That is, $$m < n \iff m \in n.$$ + Likewise, define $m$ to be \textbf{less than or equal to} $n$ if and only if + $m \in n \lor m = n$. + That is, + \begin{align*} + m \leq n + & \iff m \ineq n \\ + & \iff m < n \lor m = n. + \end{align*} -\begin{definition} - - \lean*{Init/Prelude}{Nat.lt} - -\end{definition} + \lean{Init/Prelude}{Nat.lt} \section{\defined{Pair Set}}% \hyperlabel{ref:pair-set} -For any sets $u$ and $v$, the \textbf{pair set $\{u, v\}$} is the set whose - only members are $u$ and $v$. - -\begin{definition} - - \statementpadding + For any sets $u$ and $v$, the \textbf{pair set $\{u, v\}$} is the set whose + only members are $u$ and $v$. \lean*{Mathlib/Init/Set}{Set.insert} - \lean*{Mathlib/Init/Set}{Set.singleton} - -\end{definition} + \lean{Mathlib/Init/Set}{Set.singleton} \section{\defined{Pairing Axiom}}% \hyperlabel{ref:pairing-axiom} -For any sets $u$ and $v$, there is a set having as members just $u$ and $v$: - $$\forall u, \forall v, \exists B, \forall x, - (x \in B \iff x = u \text{ or } x = v).$$ + For any sets $u$ and $v$, there is a set having as members just $u$ and $v$: + $$\forall u, \forall v, \exists B, \forall x, + (x \in B \iff x = u \text{ or } x = v).$$ -\begin{axiom} + \lean{Mathlib/Init/Set}{Set.insert} - \statementpadding - - \lean*{Mathlib/Init/Set}{Set.insert} - - \lean*{Mathlib/Init/Set}{Set.singleton} - -\end{axiom} + \lean{Mathlib/Init/Set}{Set.singleton} \section{\defined{Partition}}% \hyperlabel{ref:partition} -A \textbf{partition} $\Pi$ of a set $A$ is a set of nonempty subsets of $A$ that - is disjoint and exhaustive, i.e. - \begin{enumerate}[(a)] - \item no two different sets in $\Pi$ have any common elements, and - \item each element of $A$ is in some set in $\Pi$. - \end{enumerate} + A \textbf{partition} $\Pi$ of a set $A$ is a set of nonempty subsets of $A$ + that is disjoint and exhaustive, i.e. + \begin{enumerate}[(a)] + \item no two different sets in $\Pi$ have any common elements, and + \item each element of $A$ is in some set in $\Pi$. + \end{enumerate} -\begin{definition} - - \lean*{Mathlib/Data/Setoid/Partition}{Setoid.IsPartition} - -\end{definition} + \lean{Mathlib/Data/Setoid/Partition}{Setoid.IsPartition} \section{\defined{Peano System}}% \hyperlabel{ref:peano-system} -A \textbf{Peano system} is a triple $\langle N, S, e \rangle$ consisting of a - set $N$, a function $S \colon N \rightarrow N$, and a member $e \in N$ such - that the following three conditions are met: -\begin{enumerate}[(i)] - \item $e \not\in \ran{S}$. - \item $S$ is one-to-one. - \item Every subset $A$ of $N$ containing $e$ and closed under $S$ is $N$ - itself. -\end{enumerate} + A \textbf{Peano system} is a triple $\langle N, S, e \rangle$ consisting of a + set $N$, a function $S \colon N \rightarrow N$, and a member $e \in N$ such + that the following three conditions are met: + \begin{enumerate}[(i)] + \item $e \not\in \ran{S}$. + \item $S$ is one-to-one. + \item Every subset $A$ of $N$ containing $e$ and closed under $S$ is $N$ + itself. + \end{enumerate} -\begin{definition} - - \code*{Common/Set/Peano}{Peano.System} - -\end{definition} + \code{Common/Set/Peano}{Peano.System} \section{\defined{Power Set}}% \hyperlabel{ref:power-set} -For any set $a$, the \textbf{power set $\powerset{a}$} is the set whose members - are exactly the subsets of $a$. - -\begin{definition} + For any set $a$, the \textbf{power set $\powerset{a}$} is the set whose + members are exactly the subsets of $a$. \lean*{Mathlib/Init/Set}{Set.powerset} -\end{definition} - \section{\defined{Power Set Axiom}}% \hyperlabel{ref:power-set-axiom} -For any set $a$, there is a set whose members are exactly the subsets of $a$: - $$\forall a, \exists B, \forall x, (x \in B \iff x \subseteq a).$$ + For any set $a$, there is a set whose members are exactly the subsets of $a$: + $$\forall a, \exists B, \forall x, (x \in B \iff x \subseteq a).$$ -\begin{axiom} - - \lean*{Mathlib/Init/Set}{Set.powerset} - -\end{axiom} + \lean{Mathlib/Init/Set}{Set.powerset} \section{\defined{Proper Subset}}% \hyperlabel{ref:proper-subset} -A set $A$ is said to be a \textbf{proper subset} of $B$ ($A \subset B$) if and - only if it is a subset of $B$ that is unequal to $B$. -$$A \subset B \iff A \subseteq B \land A \neq B.$$ + A set $A$ is said to be a \textbf{proper subset} of $B$ ($A \subset B$) if and + only if it is a subset of $B$ that is unequal to $B$. + $$A \subset B \iff A \subseteq B \land A \neq B.$$ -\begin{definition} - - \lean*{Std/Classes/SetNotation}{HasSSubset} - -\end{definition} + \lean{Std/Classes/SetNotation}{HasSSubset} \section{\defined{Quotient Set}}% \hyperlabel{ref:quotient-set} -If $R$ is an \nameref{ref:equivalence-relation} on set $A$, then we can define - the \textbf{quotient set} $$A / R = \{[x]_R \mid x \in A\}$$ whose members are - the equivalence classes. -The expression $A / R$ is read "$A$ modulo $R$. - -\begin{definition} + If $R$ is an \nameref{ref:equivalence-relation} on set $A$, then we can define + the \textbf{quotient set} $$A / R = \{[x]_R \mid x \in A\}$$ whose members + are the equivalence classes. + The expression $A / R$ is read "$A$ modulo $R$. \lean*{Init/Core}{Quotient} -\end{definition} - \section{\defined{Range}}% \hyperlabel{ref:range} -The \textbf{range} of set $R$, denoted $\ran{R}$, is given by - $$x \in \ran{R} \iff \exists t \pair{t, x} \in R.$$ + The \textbf{range} of set $R$, denoted $\ran{R}$, is given by + $$x \in \ran{R} \iff \exists t \pair{t, x} \in R.$$ -\begin{definition} + \lean{Mathlib/Data/Rel}{Rel.codom} - \statementpadding - - \lean*{Mathlib/Data/Rel}{Rel.codom} - - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.ran} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.ran} \section{\defined{Reflexive}}% \hyperlabel{ref:reflexive} -A binary relation $R$ is \textbf{reflexive} on $A$ if and only if $xRx$ for all - $x \in A$. - -\begin{definition} - - \statementpadding + A binary relation $R$ is \textbf{reflexive} on $A$ if and only if $xRx$ for + all $x \in A$. \lean*{Mathlib/Init/Algebra/Classes}{IsRefl} - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.isReflexive} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.isReflexive} \section{\defined{Relation}}% \hyperlabel{ref:relation} -A \textbf{relation} is a set of \nameref{ref:ordered-pair}s. - -\begin{definition} - - \statementpadding + A \textbf{relation} is a set of \nameref{ref:ordered-pair}s. \lean*{Mathlib/Data/Rel}{Rel} - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation} \section{\defined{Restriction}}% \hyperlabel{ref:restriction} -The \textbf{restriction} of a set $F$ to set $A$ is the set - $$F \restriction A = \{\pair{u, v} \mid uFv \land u \in A\}.$$ + The \textbf{restriction} of a set $F$ to set $A$ is the set + $$F \restriction A = \{\pair{u, v} \mid uFv \land u \in A\}.$$ -\begin{definition} - - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.restriction} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.restriction} \section{\defined{Successor}}% -\label{ref:successor} +\hyperlabel{ref:successor} -For any set $a$, its \textbf{successor} is defined by $$a^+ = a \cup \{a\}.$$ + For any set $a$, its \textbf{successor} is defined by $$a^+ = a \cup \{a\}.$$ -\begin{note} - The corresponding Lean reference refers to the `Nat.succ` constructor. - This is not represented internally as a union of sets, but serves the same - role. -\end{note} + \begin{note} + The corresponding Lean reference refers to the `Nat.succ` constructor. + This is not represented internally as a union of sets, but serves the same + role. + \end{note} -\begin{definition} - - \lean*{Prelude}{Nat.succ} - -\end{definition} + \lean{Prelude}{Nat.succ} \section{\defined{Subset Axioms}}% \hyperlabel{ref:subset-axioms} -For each formula $\phi$ not containing $B$, the following is an axiom: - $$\forall t_1, \cdots \forall t_k, \forall c, - \exists B, \forall x, (x \in B \iff x \in c \land \phi).$$ + For each formula $\phi$ not containing $B$, the following is an axiom: + $$\forall t_1, \cdots \forall t_k, \forall c, + \exists B, \forall x, (x \in B \iff x \in c \land \phi).$$ -\begin{axiom} - - \lean*{Mathlib/Init/Set}{Set.Subset} - -\end{axiom} + \lean{Mathlib/Init/Set}{Set.Subset} \section{\defined{Symmetric}}% \hyperlabel{ref:symmetric} -A binary relation $R$ is \textbf{symmetric} if and only if whenever $xRy$ then - $yRx$. - -\begin{definition} + A binary relation $R$ is \textbf{symmetric} if and only if whenever $xRy$ then + $yRx$. \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.isSymmetric} -\end{definition} - \section{\defined{Symmetric Difference}}% \hyperlabel{ref:symmetric-difference} -The \textbf{symmetric difference} $A + B$ of sets $A$ and $B$ is the set - $(A - B) \cup (B - A)$. - -\begin{definition} + The \textbf{symmetric difference} $A + B$ of sets $A$ and $B$ is the set + $(A - B) \cup (B - A)$. \lean*{Mathlib/Data/Set/Basic}{symmDiff\_def} -\end{definition} - \section{\defined{Transitive}}% \hyperlabel{ref:transitive} -A binary relation $R$ is \textbf{transitive} if and only if whenever $xRy$ and - $yRz$, then $xRz$. - -\begin{definition} - - \statementpadding + A binary relation $R$ is \textbf{transitive} if and only if whenever $xRy$ and + $yRz$, then $xRz$. \lean*{Mathlib/Init/Algebra/Classes}{IsTrans} - \code*{Bookshelf/Enderton/Set/Relation}{Set.Relation.isTransitive} - -\end{definition} + \code{Bookshelf/Enderton/Set/Relation}{Set.Relation.isTransitive} \section{\defined{Transitive Set}}% \hyperlabel{ref:transitive-set} -A set $A$ is said to be \textbf{transitive} if and only if every member of a - member of $A$ is a member of $A$ itself. -That is, $\bigcup A \subseteq A$. + A set $A$ is said to be \textbf{transitive} if and only if every member of a + member of $A$ is a member of $A$ itself. + That is, $\bigcup A \subseteq A$. \section{\defined{Trichotomous}}% \hyperlabel{ref:trichotomous} -A binary relation $R$ on set $A$ is \textbf{trichotomous} if for any - $x, y \in A$, exactly one of the three alternatives - $$xRy, \quad x = y, \quad yRx$$ - holds. - -\begin{definition} + A binary relation $R$ on set $A$ is \textbf{trichotomous} if for any + $x, y \in A$, exactly one of the three alternatives + $$xRy, \quad x = y, \quad yRx$$ + holds. \lean*{Mathlib/Init/Algebra/Classes}{IsTrichotomous} -\end{definition} - \section{\defined{Union Axiom}}% \hyperlabel{ref:union-axiom} -For any set $A$, there exists a set $B$ whose elements are exactly the members - of the members of $A$: - $$\forall A, \exists B, \forall x - \left[ x \in B \iff (\exists b \in A) x \in b \right]$$ + For any set $A$, there exists a set $B$ whose elements are exactly the members + of the members of $A$: + $$\forall A, \exists B, \forall x + \left[ x \in B \iff (\exists b \in A) x \in b \right]$$ -\begin{axiom} - - \lean*{Mathlib/Data/Set/Lattice}{Set.sUnion} - -\end{axiom} + \lean{Mathlib/Data/Set/Lattice}{Set.sUnion} \section{\defined{Union Axiom, Preliminary Form}}% \hyperlabel{ref:union-axiom-preliminary-form} -For any sets $a$ and $b$, there is a set whose members are those sets belonging - either to $a$ or to $b$ (or both): - $$\forall a, \forall b, \exists B, \forall x, - (x \in B \iff x \in a \text{ or } x \in b).$$ + For any sets $a$ and $b$, there is a set whose members are those sets + belonging either to $a$ or to $b$ (or both): + $$\forall a, \forall b, \exists B, \forall x, + (x \in B \iff x \in a \text{ or } x \in b).$$ -\begin{axiom} - - \lean*{Mathlib/Init/Set}{Set.union} - -\end{axiom} + \lean{Mathlib/Init/Set}{Set.union} \endgroup @@ -765,294 +559,277 @@ For any sets $a$ and $b$, there is a set whose members are those sets belonging \subsection{\verified{Exercise 1.1}}% \hyperlabel{sub:exercise-1.1} -Which of the following become true when "$\in$" is inserted in place of the - blank? -Which become true when "$\subseteq$" is inserted? + Which of the following become true when "$\in$" is inserted in place of the + blank? + Which become true when "$\subseteq$" is inserted? \subsubsection{\verified{Exercise 1.1a}}% \hyperlabel{ssub:exercise-1.1a} -$\{\emptyset\} \_\_\_\_ \{\emptyset, \{\emptyset\}\}$. - -\begin{proof} + $$\{\emptyset\} \_\_\_\_ \{\emptyset, \{\emptyset\}\}.$$ \code{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_1a} - Because the \textit{object} $\{\emptyset\}$ is a member of the right-hand set, - the statement is \textbf{true} in the case of "$\in$". + \begin{proof} + Because the \textit{object} $\{\emptyset\}$ is a member of the right-hand + set, the statement is \textbf{true} in the case of "$\in$". - Because the \textit{members} of $\{\emptyset\}$ are all members of the - right-hand set, the statement is also \textbf{true} in the case of - "$\subseteq$". - -\end{proof} + Because the \textit{members} of $\{\emptyset\}$ are all members of the + right-hand set, the statement is also \textbf{true} in the case of + "$\subseteq$". + \end{proof} \subsubsection{\verified{Exercise 1.1b}}% \hyperlabel{ssub:exercise-1.11b} -$\{\emptyset\} \_\_\_\_ \{\emptyset, \{\{\emptyset\}\}\}$. - -\begin{proof} + $$\{\emptyset\} \_\_\_\_ \{\emptyset, \{\{\emptyset\}\}\}.$$ \code{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_1b} - Because the \textit{object} $\{\emptyset\}$ is not a member of the right-hand - set, the statement is \textbf{false} in the case of "$\in$". + \begin{proof} + Because the \textit{object} $\{\emptyset\}$ is not a member of the + right-hand set, the statement is \textbf{false} in the case of "$\in$". - Because the \textit{members} of $\{\emptyset\}$ are all members of the - right-hand set, the statement is \textbf{true} in the case of "$\subseteq$". - -\end{proof} + Because the \textit{members} of $\{\emptyset\}$ are all members of the + right-hand set, the statement is \textbf{true} in the case of + "$\subseteq$". + \end{proof} \subsubsection{\verified{Exercise 1.1c}}% \hyperlabel{ssub:exercise-1.1c} -$\{\{\emptyset\}\} \_\_\_\_ \{\emptyset, \{\emptyset\}\}$. - -\begin{proof} + $$\{\{\emptyset\}\} \_\_\_\_ \{\emptyset, \{\emptyset\}\}.$$ \code{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_1c} - Because the \textit{object} $\{\{\emptyset\}\}$ is not a member of the - right-hand set, the statement is \textbf{false} in the case of "$\in$". + \begin{proof} + Because the \textit{object} $\{\{\emptyset\}\}$ is not a member of the + right-hand set, the statement is \textbf{false} in the case of "$\in$". - Because the \textit{members} of $\{\{\emptyset\}\}$ are all members of the - right-hand set, the statement is \textbf{true} in the case of "$\subseteq$". - -\end{proof} + Because the \textit{members} of $\{\{\emptyset\}\}$ are all members of the + right-hand set, the statement is \textbf{true} in the case of + "$\subseteq$". + \end{proof} \subsubsection{\verified{Exercise 1.1d}}% \hyperlabel{ssub:exercise-1.1d} -$\{\{\emptyset\}\} \_\_\_\_ \{\emptyset, \{\{\emptyset\}\}\}$. - -\begin{proof} + $$\{\{\emptyset\}\} \_\_\_\_ \{\emptyset, \{\{\emptyset\}\}\}.$$ \code{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_1d} - Because the \textit{object} $\{\{\emptyset\}\}$ is a member of the right-hand - set, the statement is \textbf{true} in the case of "$\in$". + \begin{proof} + Because the \textit{object} $\{\{\emptyset\}\}$ is a member of the + right-hand set, the statement is \textbf{true} in the case of "$\in$". - Because the \textit{members} of $\{\{\emptyset\}\}$ are not all members of the - right-hand set, the statement is \textbf{false} in the case of - "$\subseteq$". - -\end{proof} + Because the \textit{members} of $\{\{\emptyset\}\}$ are not all members of + the right-hand set, the statement is \textbf{false} in the case of + "$\subseteq$". + \end{proof} \subsubsection{\verified{Exercise 1.1e}}% \hyperlabel{ssub:exercise-1.1e} -$\{\{\emptyset\}\} \_\_ \{\emptyset, \{\emptyset, \{\emptyset\}\}\}$. - -\begin{proof} + $$\{\{\emptyset\}\} \_\_ \{\emptyset, \{\emptyset, \{\emptyset\}\}\}.$$ \code{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_1e} - Because the \textit{object} $\{\{\emptyset\}\}$ is not a member of the - right-hand set, the statement is \textbf{false} in the case of "$\in$". + \begin{proof} + Because the \textit{object} $\{\{\emptyset\}\}$ is not a member of the + right-hand set, the statement is \textbf{false} in the case of "$\in$". - Because the \textit{members} of $\{\{\emptyset\}\}$ are not all members of the - right-hand set, the statement is \textbf{false} in the case of - "$\subseteq$". - -\end{proof} + Because the \textit{members} of $\{\{\emptyset\}\}$ are not all members of + the right-hand set, the statement is \textbf{false} in the case of + "$\subseteq$". + \end{proof} \subsection{\verified{Exercise 1.2}}% \hyperlabel{sub:exercise-1.2} -Show that no two of the three sets $\emptyset$, $\{\emptyset\}$, and - $\{\{\emptyset\}\}$ are equal to each other. + Show that no two of the three sets $\emptyset$, $\{\emptyset\}$, and + $\{\{\emptyset\}\}$ are equal to each other. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_1} + \code*{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_2} - By the \nameref{ref:extensionality-axiom}, $\emptyset$ is only equal to - $\emptyset$. - This immediately shows it is not equal to the other two. - Now consider object $\emptyset$. - This object is a member of $\{\emptyset\}$ but is not a member of - $\{\{\emptyset\}\}$. - Again, by the \nameref{ref:extensionality-axiom}, these two sets must be - different. - -\end{proof} + \begin{proof} + By the \nameref{ref:extensionality-axiom}, $\emptyset$ is only equal to + $\emptyset$. + This immediately shows it is not equal to the other two. + Now consider object $\emptyset$. + This object is a member of $\{\emptyset\}$ but is not a member of + $\{\{\emptyset\}\}$. + Again, by the \nameref{ref:extensionality-axiom}, these two sets must be + different. + \end{proof} \subsection{\verified{Exercise 1.3}}% \hyperlabel{sub:exercise-1.3} -Show that if $B \subseteq C$, then $\powerset{B} \subseteq \powerset{C}$. + Show that if $B \subseteq C$, then $\powerset{B} \subseteq \powerset{C}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_1} + \code*{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_3} - Let $x \in \powerset{B}$. - By definition of the \nameref{ref:power-set}, $x$ is a subset of $B$. - By hypothesis, $B \subseteq C$. - Then $x \subseteq C$. - Again by definition of the \nameref{ref:power-set}, it follows - $x \in \powerset{C}$. - -\end{proof} + \begin{proof} + Let $x \in \powerset{B}$. + By definition of the \nameref{ref:power-set}, $x$ is a subset of $B$. + By hypothesis, $B \subseteq C$. + Then $x \subseteq C$. + Again by definition of the \nameref{ref:power-set}, it follows + $x \in \powerset{C}$. + \end{proof} \subsection{\verified{Exercise 1.4}}% \hyperlabel{sub:exercise-1.4} -Assume that $x$ and $y$ are members of a set $B$. -Show that $\{\{x\}, \{x, y\}\} \in \powerset{\powerset{B}}.$ + Assume that $x$ and $y$ are members of a set $B$. + Show that $\{\{x\}, \{x, y\}\} \in \powerset{\powerset{B}}.$ -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_1} + \code*{Bookshelf/Enderton/Set/Chapter\_1} {Enderton.Set.Chapter\_1.exercise\_1\_4} - Let $x$ and $y$ be members of set $B$. - Then $\{x\}$ and $\{x, y\}$ are subsets of $B$. - By definition of the \nameref{ref:power-set}, $\{x\}$ and $\{x, y\}$ are - members of $\powerset{B}$. - Then $\{\{x\}, \{x, y\}\}$ is a subset of $\powerset{B}$. - By definition of the \nameref{ref:power-set}, $\{\{x\}, \{x, y\}\}$ is a - member of $\powerset{\powerset{B}}$. - -\end{proof} + \begin{proof} + Let $x$ and $y$ be members of set $B$. + Then $\{x\}$ and $\{x, y\}$ are subsets of $B$. + By definition of the \nameref{ref:power-set}, $\{x\}$ and $\{x, y\}$ are + members of $\powerset{B}$. + Then $\{\{x\}, \{x, y\}\}$ is a subset of $\powerset{B}$. + By definition of the \nameref{ref:power-set}, $\{\{x\}, \{x, y\}\}$ is a + member of $\powerset{\powerset{B}}$. + \end{proof} \subsection{\unverified{Exercise 1.5}}% \hyperlabel{sub:exercise-1.5} -Define the rank of a set $c$ to be the least $\alpha$ such that - $c \subseteq V_\alpha$. -Compute the rank of $\{\{\emptyset\}\}$. -Compute the rank of - $\{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}$. + Define the rank of a set $c$ to be the least $\alpha$ such that + $c \subseteq V_\alpha$. + Compute the rank of $\{\{\emptyset\}\}$. + Compute the rank of + $\{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}$. -\begin{proof} - - We first compute the values of $V_n$ for $0 \leq n \leq 3$ under the - assumption the set of atoms $A$ at the bottom of the hierarchy is empty. - \begin{align*} - V_0 & = \emptyset \\ - V_1 & = V_0 \cup \powerset{V_0} \\ - & = \emptyset \cup \{\emptyset\} \\ - & = \{\emptyset\} \\ - V_2 & = V_1 \cup \powerset{V_1} \\ - & = \{\emptyset\} \cup \powerset{\{\emptyset\}} \\ - & = \{\emptyset\} \cup \{\emptyset, \{\emptyset\}\} \\ - & = \{\emptyset, \{\emptyset\}\} \\ - V_3 & = V_2 \cup \powerset{V_2} \\ - & = \{\emptyset, \{\emptyset\}\} \cup - \powerset{\{\emptyset, \{\emptyset\}\}} \\ - & = \{\emptyset, \{\emptyset\}\} \cup - \{\emptyset, - \{\emptyset\}, - \{\{\emptyset\}\}, - \{\emptyset, \{\emptyset\}\}\} \\ - & = \{\emptyset, - \{\emptyset\}, - \{\{\emptyset\}\}, - \{\emptyset, \{\emptyset\}\}\} - \end{align*} - It then immediately follows $\{\{\emptyset\}\}$ has rank $2$ and - $\{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}$ has rank $3$. - -\end{proof} + \begin{proof} + We first compute the values of $V_n$ for $0 \leq n \leq 3$ under the + assumption the set of atoms $A$ at the bottom of the hierarchy is empty. + \begin{align*} + V_0 & = \emptyset \\ + V_1 & = V_0 \cup \powerset{V_0} \\ + & = \emptyset \cup \{\emptyset\} \\ + & = \{\emptyset\} \\ + V_2 & = V_1 \cup \powerset{V_1} \\ + & = \{\emptyset\} \cup \powerset{\{\emptyset\}} \\ + & = \{\emptyset\} \cup \{\emptyset, \{\emptyset\}\} \\ + & = \{\emptyset, \{\emptyset\}\} \\ + V_3 & = V_2 \cup \powerset{V_2} \\ + & = \{\emptyset, \{\emptyset\}\} \cup + \powerset{\{\emptyset, \{\emptyset\}\}} \\ + & = \{\emptyset, \{\emptyset\}\} \cup + \{\emptyset, + \{\emptyset\}, + \{\{\emptyset\}\}, + \{\emptyset, \{\emptyset\}\}\} \\ + & = \{\emptyset, + \{\emptyset\}, + \{\{\emptyset\}\}, + \{\emptyset, \{\emptyset\}\}\} + \end{align*} + It then immediately follows $\{\{\emptyset\}\}$ has rank $2$ and + $\{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}$ has rank $3$. + \end{proof} \subsection{\unverified{Exercise 1.6}}% \hyperlabel{sub:exercise-1.6} -We have stated that $V_{\alpha + 1} = A \cup \powerset{V_\alpha}$. -Prove this at least for $\alpha < 3$. + We have stated that $V_{\alpha + 1} = A \cup \powerset{V_\alpha}$. + Prove this at least for $\alpha < 3$. -\begin{proof} + \begin{proof} - Let $A$ be the set of atoms in our set hierarchy. - Let $P(n)$ be the predicate, "$V_{n + 1} = A \cup \powerset{V_n}$." - We prove $P(n)$ holds true for all natural numbers $n \geq 1$ via induction. + Let $A$ be the set of atoms in our set hierarchy. + Let $P(n)$ be the predicate, "$V_{n + 1} = A \cup \powerset{V_n}$." + We prove $P(n)$ holds true for all natural numbers $n \geq 1$ via induction. - \paragraph{Base Case}% + \paragraph{Base Case}% - Let $n = 1$. - By definition, $V_1 = V_0 \cup \powerset{V_0}$. - By definition, $V_0 = A$. - Therefore $V_1 = A \cup \powerset{V_0}$. - This proves $P(1)$ holds true. + Let $n = 1$. + By definition, $V_1 = V_0 \cup \powerset{V_0}$. + By definition, $V_0 = A$. + Therefore $V_1 = A \cup \powerset{V_0}$. + This proves $P(1)$ holds true. - \paragraph{Induction Step}% + \paragraph{Induction Step}% - Suppose $P(n)$ holds true for some $n \geq 1$. - Consider $V_{n+1}$. - By definition, $V_{n+1} = V_n \cup \powerset{V_n}$. - Therefore, by the induction hypothesis, - \begin{align} - V_{n+1} - & = V_n \cup \powerset{V_n} - \nonumber \\ - & = (A \cup \powerset{V_{n-1}}) \cup \powerset{V_n} - \nonumber \\ - & = A \cup (\powerset{V_{n-1}} \cup \powerset{V_n}) - \hyperlabel{sub:exercise-1.6-eq1} - \end{align} - But $V_{n-1}$ is a subset of $V_n$. - \nameref{sub:exercise-1.3} then implies - $\powerset{V_{n-1}} \subseteq \powerset{V_n}$. - This means \eqref{sub:exercise-1.6-eq1} can be simplified to - $$V_{n+1} = A \cup \powerset{V_n},$$ - proving $P(n+1)$ holds true. + Suppose $P(n)$ holds true for some $n \geq 1$. + Consider $V_{n+1}$. + By definition, $V_{n+1} = V_n \cup \powerset{V_n}$. + Therefore, by the induction hypothesis, + \begin{align} + V_{n+1} + & = V_n \cup \powerset{V_n} + \nonumber \\ + & = (A \cup \powerset{V_{n-1}}) \cup \powerset{V_n} + \nonumber \\ + & = A \cup (\powerset{V_{n-1}} \cup \powerset{V_n}) + \hyperlabel{sub:exercise-1.6-eq1} + \end{align} + But $V_{n-1}$ is a subset of $V_n$. + \nameref{sub:exercise-1.3} then implies + $\powerset{V_{n-1}} \subseteq \powerset{V_n}$. + This means \eqref{sub:exercise-1.6-eq1} can be simplified to + $$V_{n+1} = A \cup \powerset{V_n},$$ + proving $P(n+1)$ holds true. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - By mathematical induction, it follows for all $n \geq 1$, $P(n)$ is true. + By mathematical induction, it follows for all $n \geq 1$, $P(n)$ is true. -\end{proof} + \end{proof} \subsection{\unverified{Exercise 1.7}}% \hyperlabel{sub:exercise-1.7} -List all the members of $V_3$. -List all the members of $V_4$. -(It is to be assumed here that there are no atoms.) + List all the members of $V_3$. + List all the members of $V_4$. + (It is to be assumed here that there are no atoms.) -\begin{proof} + \begin{proof} - As seen in the proof of \nameref{sub:exercise-1.5}, - $$V_3 = \{ - \emptyset, - \{\emptyset\}, - \{\{\emptyset\}\}, - \{\emptyset, \{\emptyset\}\} - \}.$$ - By \nameref{sub:exercise-1.6}, $V_4 = \powerset{V_3}$ (since it is assumed - there are no atoms). - Thus - \begin{align*} - & V_4 = \{ \\ - & \qquad \emptyset, \\ - & \qquad \{\emptyset\}, \\ - & \qquad \{\{\emptyset\}\}, \\ - & \qquad \{\{\{\emptyset\}\}\}, \\ - & \qquad \{\{\emptyset, \{\emptyset\}\}\}, \\ - & \qquad \{\emptyset, \{\emptyset\}\}, \\ - & \qquad \{\emptyset, \{\{\emptyset\}\}\}, \\ - & \qquad \{\emptyset, \{\emptyset, \{\emptyset\}\}\}, \\ - & \qquad \{\{\emptyset\}, \{\{\emptyset\}\}\}, \\ - & \qquad \{\{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}, \\ - & \qquad \{\{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\}, \\ - & \qquad \{\emptyset, \{\emptyset\}, \{\{\emptyset\}\}\}, \\ - & \qquad \{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}, \\ - & \qquad \{\emptyset, \{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\} \\ - & \qquad \{\{\emptyset\}, \{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\}, \\ - & \qquad \{\emptyset, \{\emptyset\}, \{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\} \\ - & \}. - \end{align*} - -\end{proof} + As seen in the proof of \nameref{sub:exercise-1.5}, + $$V_3 = \{ + \emptyset, + \{\emptyset\}, + \{\{\emptyset\}\}, + \{\emptyset, \{\emptyset\}\} + \}.$$ + By \nameref{sub:exercise-1.6}, $V_4 = \powerset{V_3}$ (since it is assumed + there are no atoms). + Thus + \begin{align*} + & V_4 = \{ \\ + & \qquad \emptyset, \\ + & \qquad \{\emptyset\}, \\ + & \qquad \{\{\emptyset\}\}, \\ + & \qquad \{\{\{\emptyset\}\}\}, \\ + & \qquad \{\{\emptyset, \{\emptyset\}\}\}, \\ + & \qquad \{\emptyset, \{\emptyset\}\}, \\ + & \qquad \{\emptyset, \{\{\emptyset\}\}\}, \\ + & \qquad \{\emptyset, \{\emptyset, \{\emptyset\}\}\}, \\ + & \qquad \{\{\emptyset\}, \{\{\emptyset\}\}\}, \\ + & \qquad \{\{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}, \\ + & \qquad \{\{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\}, \\ + & \qquad \{\emptyset, \{\emptyset\}, \{\{\emptyset\}\}\}, \\ + & \qquad \{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}, \\ + & \qquad \{\emptyset, \{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\} \\ + & \qquad \{\{\emptyset\}, \{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\}, \\ + & \qquad \{\emptyset, \{\emptyset\}, \{\{\emptyset\}\}, \{\emptyset, \{\emptyset\}\}\} \\ + & \}. + \end{align*} + \end{proof} \chapter{Axioms and Operations}% \hyperlabel{chap:axioms-operations} @@ -1063,53 +840,45 @@ List all the members of $V_4$. \subsection{\unverified{Theorem 2A}}% \hyperlabel{sub:theorem-2a} -\begin{theorem}[2A] - - There is no set to which every set belongs. + \begin{theorem}[2A] + There is no set to which every set belongs. + \end{theorem} \begin{note} This was revisited after reading Enderton's proof prior. \end{note} -\end{theorem} - -\begin{proof} - - Let $A$ be an arbitrary set. - Define $B = \{ x \in A \mid x \not\in x \}$. - By the \nameref{ref:subset-axioms}, $B$ is a set. - Then $$B \in B \iff B \in A \land B \not\in B.$$ - If $B \in A$, then $B \in B \iff B \not\in B$, a contradiction. - Thus $B \not\in A$. - Since this process holds for any set $A$, there must exist no set to which - every set belongs. - -\end{proof} + \begin{proof} + Let $A$ be an arbitrary set. + Define $B = \{ x \in A \mid x \not\in x \}$. + By the \nameref{ref:subset-axioms}, $B$ is a set. + Then $$B \in B \iff B \in A \land B \not\in B.$$ + If $B \in A$, then $B \in B \iff B \not\in B$, a contradiction. + Thus $B \not\in A$. + Since this process holds for any set $A$, there must exist no set to which + every set belongs. + \end{proof} \subsection{\unverified{Theorem 2B}}% \hyperlabel{sub:theorem-2b} -\begin{theorem}[2B] + \begin{theorem}[2B] + For any nonempty set $A$, there exists a unique set $B$ such that for any + $x$, $$x \in B \iff x \text{ belongs to every member of } A.$$ + \end{theorem} - For any nonempty set $A$, there exists a unique set $B$ such that for any - $x$, $$x \in B \iff x \text{ belongs to every member of } A.$$ - -\end{theorem} - -\begin{proof} - - Suppose $A$ is a nonempty set. - This ensures the statement we are trying to prove does not vacuously hold for - all sets $x$ (which would yield a contradiction due to - \nameref{sub:theorem-2b}). - By the \nameref{ref:union-axiom}, $\bigcup A$ is a set. - Define $$B = \{ x \in \bigcup A \mid (\forall b \in A), x \in b \}.$$ - By the \nameref{ref:subset-axioms}, $B$ is indeed a set. - By construction, - $$\forall x, x \in B \iff x \text{ belongs to every member of } A.$$ - By the \nameref{ref:extensionality-axiom}, $B$ is unique. - -\end{proof} + \begin{proof} + Suppose $A$ is a nonempty set. + This ensures the statement we are trying to prove does not vacuously hold for + all sets $x$ (which would yield a contradiction due to + \nameref{sub:theorem-2b}). + By the \nameref{ref:union-axiom}, $\bigcup A$ is a set. + Define $$B = \{ x \in \bigcup A \mid (\forall b \in A), x \in b \}.$$ + By the \nameref{ref:subset-axioms}, $B$ is indeed a set. + By construction, + $$\forall x, x \in B \iff x \text{ belongs to every member of } A.$$ + By the \nameref{ref:extensionality-axiom}, $B$ is unique. + \end{proof} \section{Algebra of Sets}% \hyperlabel{sec:algebra-sets} @@ -1117,593 +886,574 @@ List all the members of $V_4$. \subsection{\verified{Commutative Laws}}% \hyperlabel{sub:commutative-laws} -For any sets $A$ and $B$, - \begin{align*} - A \cup B = B \cup A \\ - A \cap B = B \cap A - \end{align*} + For any sets $A$ and $B$, + \begin{align*} + A \cup B = B \cup A \\ + A \cap B = B \cap A + \end{align*} -\begin{proof} + \lean{Mathlib/Data/Set/Basic}{Set.union\_comm} - \statementpadding - - \lean*{Mathlib/Data/Set/Basic}{Set.union\_comm} - - \lean*{Mathlib/Data/Set/Basic}{Set.inter\_comm} - - \code*{Bookshelf/Enderton/Set/Chapter\_2} + \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.commutative\_law\_i} + \lean{Mathlib/Data/Set/Basic}{Set.inter\_comm} + \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.commutative\_law\_ii} - \noindent Let $A$ and $B$ be sets. - We prove that - \begin{enumerate}[(i)] - \item $A \cup B = B \cup A$ - \item $A \cap B = B \cap A$. - \end{enumerate} + \begin{proof} - \paragraph{(i)}% + Let $A$ and $B$ be sets. + We prove that + \begin{enumerate}[(i)] + \item $A \cup B = B \cup A$ + \item $A \cap B = B \cap A$. + \end{enumerate} - By the definition of the union of sets, - \begin{align*} - A \cup B - & = \{ x \mid x \in A \lor x \in B \} \\ - & = \{ x \mid x \in B \lor x \in A \} \\ - & = B \cup A. - \end{align*} + \paragraph{(i)}% - \paragraph{(ii)}% + By the definition of the union of sets, + \begin{align*} + A \cup B + & = \{ x \mid x \in A \lor x \in B \} \\ + & = \{ x \mid x \in B \lor x \in A \} \\ + & = B \cup A. + \end{align*} - By the definition of the intersection of sets, - \begin{align*} - A \cap B - & = \{ x \mid x \in A \land x \in B \} \\ - & = \{ x \mid x \in B \land x \in A \} \\ - & = B \land A. - \end{align*} + \paragraph{(ii)}% -\end{proof} + By the definition of the intersection of sets, + \begin{align*} + A \cap B + & = \{ x \mid x \in A \land x \in B \} \\ + & = \{ x \mid x \in B \land x \in A \} \\ + & = B \land A. + \end{align*} -\subsection{\pending{Associative Laws}}% + \end{proof} + +\subsection{\verified{Associative Laws}}% \hyperlabel{sub:associative-laws} -For any sets $A$, $B$ and $C$, - \begin{align*} - A \cup (B \cup C) & = (A \cup B) \cup C \\ - A \cap (B \cap C) & = (A \cap B) \cap C - \end{align*} + For any sets $A$, $B$ and $C$, + \begin{align*} + A \cup (B \cup C) & = (A \cup B) \cup C \\ + A \cap (B \cap C) & = (A \cap B) \cap C + \end{align*} -\begin{proof} + \lean{Mathlib/Data/Set/Basic}{Set.union\_assoc} - \statementpadding - - \lean*{Mathlib/Data/Set/Basic}{Set.union\_assoc} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.associative\_law\_i} \lean{Mathlib/Data/Set/Basic}{Set.inter\_assoc} - \noindent Let $A$, $B$, and $C$ be sets. - We prove that - \begin{enumerate}[(i)] - \item $A \cup (B \cup C) = (A \cup B) \cup C$ - \item $A \cap (B \cap C) = (A \cap B) \cap C$ - \end{enumerate} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.associative\_law\_ii} - \paragraph{(i)}% + \begin{proof} - By the definition of the union of sets, - \begin{align*} - A \cup (B \cup C) - & = \{ x \mid x \in A \lor x \in (B \cup C) \} \\ - & = \{ x \mid x \in A \lor x \in \{ y \mid y \in B \lor C \}\} \\ - & = \{ x \mid x \in A \lor (x \in B \lor x \in C) \} \\ - & = \{ x \mid (x \in A \lor x \in B) \lor x \in C \} \\ - & = \{ x \mid x \in \{ y \mid y \in A \lor y \in B \} \lor - x \in C \} \\ - & = \{ x \mid x \in (A \cup B) \lor x \in C \} \\ - & = (A \cup B) \cup C. - \end{align*} + Let $A$, $B$, and $C$ be sets. + We prove that + \begin{enumerate}[(i)] + \item $A \cup (B \cup C) = (A \cup B) \cup C$ + \item $A \cap (B \cap C) = (A \cap B) \cap C$ + \end{enumerate} - \paragraph{(ii)}% + \paragraph{(i)}% - By the definition of the intersection of sets, - \begin{align*} - A \cap (B \cap C) - & = \{ x \mid x \in A \land x \in (B \cap C) \} \\ - & = \{ x \mid x \in A \land - x \in \{ y \mid y \in B \land y \in C \}\} \\ - & = \{ x \mid x \in A \land (x \in B \land x \in C) \} \\ - & = \{ x \mid (x \in A \land x \in B) \land x \in C \} \\ - & = \{ x \mid x \in \{ y \mid y \in A \land y \in B \} \land - x \in C \} \\ - & = \{ x \mid x \in (A \cap B) \land x \in C \} \\ - & = (A \cap B) \cap C. - \end{align*} + By the definition of the union of sets, + \begin{align*} + A \cup (B \cup C) + & = \{ x \mid x \in A \lor x \in (B \cup C) \} \\ + & = \{ x \mid x \in A \lor (x \in B \lor x \in C) \} \\ + & = \{ x \mid (x \in A \lor x \in B) \lor x \in C \} \\ + & = \{ x \mid x \in (A \cup B) \lor x \in C \} \\ + & = (A \cup B) \cup C. + \end{align*} -\end{proof} + \paragraph{(ii)}% -\subsection{\pending{Distributive Laws}}% + By the definition of the intersection of sets, + \begin{align*} + A \cap (B \cap C) + & = \{ x \mid x \in A \land x \in (B \cap C) \} \\ + & = \{ x \mid x \in A \land (x \in B \land x \in C) \} \\ + & = \{ x \mid (x \in A \land x \in B) \land x \in C \} \\ + & = \{ x \mid x \in (A \cap B) \land x \in C \} \\ + & = (A \cap B) \cap C. + \end{align*} + + \end{proof} + +\subsection{\verified{Distributive Laws}}% \hyperlabel{sub:distributive-laws} -For any sets $A$, $B$, and $C$, - \begin{align*} - A \cap (B \cup C) & = (A \cap B) \cup (A \cap C) \\ - A \cup (B \cap C) & = (A \cup B) \cap (A \cup C) - \end{align*} + For any sets $A$, $B$, and $C$, + \begin{align*} + A \cap (B \cup C) & = (A \cap B) \cup (A \cap C) \\ + A \cup (B \cap C) & = (A \cup B) \cap (A \cup C) + \end{align*} -\begin{proof} + \lean{Mathlib/Data/Set/Basic}{Set.inter\_distrib\_left} - \statementpadding - - \lean*{Mathlib/Data/Set/Basic}{Set.inter\_distrib\_left} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.distributive\_law\_i} \lean{Mathlib/Data/Set/Basic}{Set.union\_distrib\_left} - \noindent Let $A$, $B$, and $C$ be sets. - We prove that - \begin{enumerate}[(i)] - \item $A \cap (B \cup C) = (A \cap B) \cup (A \cap C)$ - \item $A \cup (B \cap C) = (A \cup B) \cap (A \cup C)$ - \end{enumerate} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.distributive\_law\_ii} - \paragraph{(i)}% + \begin{proof} - By the definition of the union and intersection of sets, - \begin{align*} - A \cap (B \cup C) - & = \{ x \mid x \in A \land x \in B \cup C \} \\ - & = \{ x \mid x \in A \land - x \in \{ y \mid y \in B \lor y \in C \}\} \\ - & = \{ x \mid x \in A \land (x \in B \lor x \in C) \} \\ - & = \{ x \mid (x \in A \land x \in B) \lor - (x \in A \land x \in C) \} \\ - & = \{ x \mid x \in A \cap B \lor x \in A \cap C \} \\ - & = (A \cap B) \cup (A \cap C). - \end{align*} + Let $A$, $B$, and $C$ be sets. + We prove that + \begin{enumerate}[(i)] + \item $A \cap (B \cup C) = (A \cap B) \cup (A \cap C)$ + \item $A \cup (B \cap C) = (A \cup B) \cap (A \cup C)$ + \end{enumerate} - \paragraph{(ii)}% + \paragraph{(i)}% - By the definition of the union and intersection of sets, - \begin{align*} - A \cup (B \cap C) - & = \{ x \mid x \in A \lor x \in B \cap C \} \\ - & = \{ x \mid x \in A \lor - x \in \{ y \mid y \in B \land y \in C \}\} \\ - & = \{ x \mid x \in A \lor (x \in B \land x \in C) \} \\ - & = \{ x \mid (x \in A \lor x \in B) \land - (x \in A \lor x \in C) \} \\ - & = \{ x \mid x \in A \cup B \land x \in A \cup C \} \\ - & = (A \cup B) \cap (A \cup C). - \end{align*} + By the definition of the union and intersection of sets, + \begin{align*} + A \cap (B \cup C) + & = \{ x \mid x \in A \land x \in B \cup C \} \\ + & = \{ x \mid x \in A \land (x \in B \lor x \in C) \} \\ + & = \{ x \mid (x \in A \land x \in B) \lor + (x \in A \land x \in C) \} \\ + & = \{ x \mid x \in A \cap B \lor x \in A \cap C \} \\ + & = (A \cap B) \cup (A \cap C). + \end{align*} -\end{proof} + \paragraph{(ii)}% -\subsection{\pending{De Morgan's Laws}}% + By the definition of the union and intersection of sets, + \begin{align*} + A \cup (B \cap C) + & = \{ x \mid x \in A \lor x \in B \cap C \} \\ + & = \{ x \mid x \in A \lor (x \in B \land x \in C) \} \\ + & = \{ x \mid (x \in A \lor x \in B) \land + (x \in A \lor x \in C) \} \\ + & = \{ x \mid x \in A \cup B \land x \in A \cup C \} \\ + & = (A \cup B) \cap (A \cup C). + \end{align*} + + \end{proof} + +\subsection{\verified{De Morgan's Laws}}% \hyperlabel{sub:de-morgans-laws} -For any sets $A$, $B$, and $C$, - \begin{align*} - C - (A \cup B) & = (C - A) \cap (C - B) \\ - C - (A \cap B) & = (C - A) \cup (C - B) - \end{align*} - -\begin{proof} - - \statementpadding - - \lean*{Mathlib/Data/Set/Basic}{Set.diff\_inter\_diff} - - \lean{Mathlib/Data/Set/Basic}{Set.diff\_inter} - - \noindent Let $A$, $B$, and $C$ be sets. - We prove that + For any sets $A$, $B$, and $C$, \begin{enumerate}[(i)] \item $C - (A \cup B) = (C - A) \cap (C - B)$ \item $C - (A \cap B) = (C - A) \cup (C - B)$ \end{enumerate} - \paragraph{(i)}% + \lean{Mathlib/Data/Set/Basic}{Set.diff\_inter\_diff} - By definition of the union, intersection, and relative complements of sets, - \begin{align*} - C - (A \cup B) - & = \{ x \mid x \in C \land x \not\in A \cup B \} \\ - & = \{ x \mid x \in C \land - x \not\in \{ y \mid y \in A \lor y \in B \}\} \\ - & = \{ x \mid x \in C \land \neg(x \in A \lor x \in B) \} \\ - & = \{ x \mid x \in C \land (x \not\in A \land x \not\in B) \} \\ - & = \{ x \mid (x \in C \land x \not\in A) \land - (x \in C \land x \not\in B) \} \\ - & = \{ x \mid x \in (C - A) \land x \in (C - B) \} \\ - & = (C - A) \cap (C - B). - \end{align*} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.de\_morgans\_law\_i} - \paragraph{(ii)}% + \lean{Mathlib/Data/Set/Basic}{Set.diff\_inter} - By definition of the union, intersection, and relative complements of sets, - \begin{align*} - C - (A \cap B) - & = \{ x \mid x \in C \land x \not\in A \cap B \} \\ - & = \{ x \mid x \in C \land - x \not\in \{ y \mid y \in A \land y \in B \}\} \\ - & = \{ x \mid x \in C \land \neg(x \in A \land x \in B) \} \\ - & = \{ x \mid x \in C \land (x \not\in A \lor x \not\in B) \} \\ - & = \{ x \mid (x \in C \land x \not\in A) \lor - (x \in C \land x \not\in B) \} \\ - & = \{ x \mid x \in (C - A) \lor x \in (C - B) \} \\ - & = (C - A) \cup (C - B). - \end{align*} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.de\_morgans\_law\_ii} -\end{proof} + \begin{proof} -\subsection{\pending{% + Let $A$, $B$, and $C$ be sets. + + \paragraph{(i)}% + + By definition of the union, intersection, and relative complements of + sets, + \begin{align*} + C - (A \cup B) + & = \{ x \mid x \in C \land x \not\in A \cup B \} \\ + & = \{ x \mid x \in C \land \neg(x \in A \lor x \in B) \} \\ + & = \{ x \mid x \in C \land (x \not\in A \land x \not\in B) \} \\ + & = \{ x \mid (x \in C \land x \not\in A) \land + (x \in C \land x \not\in B) \} \\ + & = \{ x \mid x \in (C - A) \land x \in (C - B) \} \\ + & = (C - A) \cap (C - B). + \end{align*} + + \paragraph{(ii)}% + + By definition of the union, intersection, and relative complements of + sets, + \begin{align*} + C - (A \cap B) + & = \{ x \mid x \in C \land x \not\in A \cap B \} \\ + & = \{ x \mid x \in C \land \neg(x \in A \land x \in B) \} \\ + & = \{ x \mid x \in C \land (x \not\in A \lor x \not\in B) \} \\ + & = \{ x \mid (x \in C \land x \not\in A) \lor + (x \in C \land x \not\in B) \} \\ + & = \{ x \mid x \in C - A \lor x \in C - B \} \\ + & = (C - A) \cup (C - B). + \end{align*} + + \end{proof} + +\subsection{\verified{% Identities Involving \texorpdfstring{$\emptyset$}{the Empty Set}}}% \hyperlabel{sub:identitives-involving-empty-set} -For any set $A$, - \begin{align*} - A \cup \emptyset & = A \\ - A \cap \emptyset & = \emptyset \\ - A \cap (C - A) & = \emptyset - \end{align*} - -\begin{proof} - - \statementpadding - - \lean*{Mathlib/Data/Set/Basic}{Set.union\_empty} - - \lean*{Mathlib/Data/Set/Basic}{Set.inter\_empty} - - \lean{Mathlib/Data/Set/Basic}{Set.inter\_diff\_self} - - \noindent Let $A$ be an arbitrary set. - We prove that + For any set $A$, \begin{enumerate}[(i)] \item $A \cup \emptyset = A$ \item $A \cap \emptyset = \emptyset$ \item $A \cap (C - A) = \emptyset$ \end{enumerate} - \paragraph{(i)}% + \lean{Mathlib/Data/Set/Basic}{Set.union\_empty} - By definition of the emptyset and union of sets, - \begin{align*} - A \cup \emptyset - & = \{ x \mid x \in A \lor x \in \emptyset \} \\ - & = \{ x \mid x \in A \lor F \} \\ - & = \{ x \mid x \in A \} \\ - & = A. - \end{align*} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.emptyset\_identity\_i} - \paragraph{(ii)}% + \lean{Mathlib/Data/Set/Basic}{Set.inter\_empty} - By definition of the emptyset and intersection of sets, - \begin{align*} - A \cap \emptyset - & = \{ x \mid x \in A \land x \in \emptyset \} \\ - & = \{ x \mid x \in A \land F \} \\ - & = \{ x \mid F \} \\ - & = \{ x \mid x \neq x \} \\ - & = \emptyset. - \end{align*} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.emptyset\_identity\_ii} - \paragraph{(iii)}% + \lean{Mathlib/Data/Set/Basic}{Set.inter\_diff\_self} - By definition of the emptyset, and the intersection and relative complement - of sets, - \begin{align*} - A \cap (C - A) - & = \{ x \mid x \in A \land x \in C - A \} \\ - & = \{ x \mid x \in A \land - x \in \{ y \mid y \in C \land y \not\in A \}\} \\ - & = \{ x \mid x \in A \land (x \in C \land x \not\in A) \} \\ - & = \{ x \mid x \in C \land F \} \\ - & = \{ x \mid F \} \\ - & = \{ x \mid x \neq x \} \\ - & = \emptyset. - \end{align*} + \code{Bookshelf/Enderton/Set/Chapter\_2} + {Enderton.Set.Chapter\_2.emptyset\_identity\_iii} -\end{proof} + \begin{proof} + + Let $A$ be an arbitrary set. + + \paragraph{(i)}% + + By definition of the emptyset and union of sets, + \begin{align*} + A \cup \emptyset + & = \{ x \mid x \in A \lor x \in \emptyset \} \\ + & = \{ x \mid x \in A \lor F \} \\ + & = \{ x \mid x \in A \} \\ + & = A. + \end{align*} + + \paragraph{(ii)}% + + By definition of the emptyset and intersection of sets, + \begin{align*} + A \cap \emptyset + & = \{ x \mid x \in A \land x \in \emptyset \} \\ + & = \{ x \mid x \in A \land F \} \\ + & = \{ x \mid F \} \\ + & = \emptyset. + \end{align*} + + \paragraph{(iii)}% + + By definition of the emptyset, and the intersection and relative + complement of sets, + \begin{align*} + A \cap (C - A) + & = \{ x \mid x \in A \land x \in C - A \} \\ + & = \{ x \mid x \in A \land (x \in C \land x \not\in A) \} \\ + & = \{ x \mid x \in C \land F \} \\ + & = \{ x \mid F \} \\ + & = \emptyset. + \end{align*} + + \end{proof} \subsection{\pending{Monotonicity}}% \hyperlabel{sub:monotonicity} -For any sets $A$, $B$, and $C$, - \begin{align*} - A \subseteq B & \Rightarrow A \cup C \subseteq B \cup C \\ - A \subseteq B & \Rightarrow A \cap C \subseteq B \cap C \\ - A \subseteq B & \Rightarrow \bigcup A \subseteq \bigcup B - \end{align*} + For any sets $A$, $B$, and $C$, + \begin{align*} + A \subseteq B & \Rightarrow A \cup C \subseteq B \cup C \\ + A \subseteq B & \Rightarrow A \cap C \subseteq B \cap C \\ + A \subseteq B & \Rightarrow \bigcup A \subseteq \bigcup B + \end{align*} -\begin{proof} + \lean{Mathlib/Data/Set/Basic}{Set.union\_subset\_union\_left} - \statementpadding - - \lean*{Mathlib/Data/Set/Basic}{Set.union\_subset\_union\_left} - - \lean*{Mathlib/Data/Set/Basic}{Set.inter\_subset\_inter\_left} + \lean{Mathlib/Data/Set/Basic}{Set.inter\_subset\_inter\_left} \lean{Mathlib/Data/Set/Lattice}{Set.sUnion\_mono} - \noindent Let $A$, $B$, and $C$ be arbitrary sets. - We prove that - \begin{enumerate}[(i)] - \item $A \subseteq B \Rightarrow A \cup C \subseteq B \cup C$ - \item $A \subseteq B \Rightarrow A \cap C \subseteq B \cap C$ - \item $A \subseteq B \Rightarrow \bigcup A \subseteq \bigcup B$ - \end{enumerate} + \begin{proof} - \paragraph{(i)}% + Let $A$, $B$, and $C$ be arbitrary sets. + We prove that + \begin{enumerate}[(i)] + \item $A \subseteq B \Rightarrow A \cup C \subseteq B \cup C$ + \item $A \subseteq B \Rightarrow A \cap C \subseteq B \cap C$ + \item $A \subseteq B \Rightarrow \bigcup A \subseteq \bigcup B$ + \end{enumerate} - Suppose $A \subseteq B$. - Let $x \in A \cup C$. - There are two cases to consider. + \paragraph{(i)}% - \subparagraph{Case 1}% + Suppose $A \subseteq B$. + Let $x \in A \cup C$. + There are two cases to consider. - Suppose $x \in A$. - Then, by definition of the subset, $x \in B$. - Therefore $x \in B \cup C$. + \subparagraph{Case 1}% - \subparagraph{Case 2}% + Suppose $x \in A$. + Then, by definition of the subset, $x \in B$. + Therefore $x \in B \cup C$. - Suppose $x \in C$. - Then $x$ is trivially a member of $B \cup C$. + \subparagraph{Case 2}% - \subparagraph{Conclusion}% + Suppose $x \in C$. + Then $x$ is trivially a member of $B \cup C$. - Since these cases are exhaustive and both imply $x \in B \cup C$, it - follows $A \cup C \subseteq B \cup C$. + \subparagraph{Conclusion}% - \paragraph{(ii)}% + Since these cases are exhaustive and both imply $x \in B \cup C$, it + follows $A \cup C \subseteq B \cup C$. - Suppose $A \subseteq B$. - Let $x \in A \cap C$. - Then, by definition of the intersection of sets, $x \in A$ and $x \in C$. - By definition of the subset, $x \in A$ implies $x \in B$. - Therefore $x \in B$ and $x \in C$. - That is, $x \in B \cap C$. - Since this holds for arbitrary $x \in A \cap C$, it follows - $A \cap C \subseteq B \cap C$. + \paragraph{(ii)}% - \paragraph{(iii)}% + Suppose $A \subseteq B$. + Let $x \in A \cap C$. + Then, by definition of the intersection of sets, $x \in A$ and $x \in C$. + By definition of the subset, $x \in A$ implies $x \in B$. + Therefore $x \in B$ and $x \in C$. + That is, $x \in B \cap C$. + Since this holds for arbitrary $x \in A \cap C$, it follows + $A \cap C \subseteq B \cap C$. - Suppose $A \subseteq B$. - Let $x \in \bigcup A$. - Then, by definition of the union of sets, there exists some $b \in A$ such - that $x \in b$. - By definition of the subset, $b \in B$ as well. - Another application of the definition of the union of sets immediately - implies that $x$ is a member of $\bigcup B$. + \paragraph{(iii)}% -\end{proof} + Suppose $A \subseteq B$. + Let $x \in \bigcup A$. + Then, by definition of the union of sets, there exists some $b \in A$ such + that $x \in b$. + By definition of the subset, $b \in B$ as well. + Another application of the definition of the union of sets immediately + implies that $x$ is a member of $\bigcup B$. + + \end{proof} \subsection{\pending{Anti-monotonicity}}% \hyperlabel{sub:anti-monotonicity} -For any sets $A$, $B$, and $C$, - \begin{align*} - A \subseteq B & \Rightarrow C - B \subseteq C - A \\ - \emptyset \neq A \subseteq B & \Rightarrow \bigcap B \subseteq \bigcap A. - \end{align*} + For any sets $A$, $B$, and $C$, + \begin{align*} + A \subseteq B & \Rightarrow C - B \subseteq C - A \\ + \emptyset \neq A \subseteq B & \Rightarrow \bigcap B \subseteq \bigcap A. + \end{align*} -\begin{proof} - - \statementpadding - - \lean*{Mathlib/Data/Set/Basic}{Set.diff\_subset\_diff\_right} + \lean{Mathlib/Data/Set/Basic}{Set.diff\_subset\_diff\_right} \lean{Mathlib/Data/Set/Lattice}{Set.sInter\_subset\_sInter} - \noindent Let $A$, $B$, and $C$ be arbitrary sets. - We prove that - \begin{enumerate}[(i)] - \item $A \subseteq B \Rightarrow C - B \subseteq C - A$ - \item $\emptyset \neq A \subseteq B \Rightarrow - \bigcap B \subseteq \bigcap A$ - \end{enumerate} + \begin{proof} - \paragraph{(i)}% + Let $A$, $B$, and $C$ be arbitrary sets. + We prove that + \begin{enumerate}[(i)] + \item $A \subseteq B \Rightarrow C - B \subseteq C - A$ + \item $\emptyset \neq A \subseteq B \Rightarrow + \bigcap B \subseteq \bigcap A$ + \end{enumerate} - Suppose $A \subseteq B$. - Let $x \in C - B$. - By definition of the relative complement, $x \in C$ and $x \not\in B$. - Then $x$ cannot be a member of $A$, since otherwise this would contradict - our subset hypothesis. - That is, $x \in C$ and $x \not\in A$. - Therefore $x \in C - A$. - Since this holds for arbitrary $x \in C - B$, it follows that - $C - B \subseteq C - A$. + \paragraph{(i)}% - \paragraph{(ii)}% + Suppose $A \subseteq B$. + Let $x \in C - B$. + By definition of the relative complement, $x \in C$ and $x \not\in B$. + Then $x$ cannot be a member of $A$, since otherwise this would contradict + our subset hypothesis. + That is, $x \in C$ and $x \not\in A$. + Therefore $x \in C - A$. + Since this holds for arbitrary $x \in C - B$, it follows that + $C - B \subseteq C - A$. - Suppose $A \neq \emptyset$ and $A \subseteq B$. - Then $B \neq \emptyset$. - Let $x \in \bigcap B$. - By definition of the intersection of sets, for all $b \in B$, $x \in b$. - But then, by definition of the subset, for all $a \in A$, $x \in a$. - Therefore $x \in \bigcap A$. - Since this holds for arbitrary $x \in \bigcap B$, it follows that - $\bigcap B \subseteq \bigcap A$. + \paragraph{(ii)}% -\end{proof} + Suppose $A \neq \emptyset$ and $A \subseteq B$. + Then $B \neq \emptyset$. + Let $x \in \bigcap B$. + By definition of the intersection of sets, for all $b \in B$, $x \in b$. + But then, by definition of the subset, for all $a \in A$, $x \in a$. + Therefore $x \in \bigcap A$. + Since this holds for arbitrary $x \in \bigcap B$, it follows that + $\bigcap B \subseteq \bigcap A$. + + \end{proof} \subsection{\unverified{General Distributive Laws}}% \hyperlabel{sub:general-distributive-laws} -For any sets $A$ and $\mathscr{B}$, - \begin{align*} - A \cup \bigcap \mathscr{B} & = - \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \} - \quad\text{for}\quad \mathscr{B} \neq \emptyset \\ - A \cap \bigcup \mathscr{B} & = - \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \} - \end{align*} + For any sets $A$ and $\mathscr{B}$, + \begin{align*} + A \cup \bigcap \mathscr{B} & = + \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \} + \quad\text{for}\quad \mathscr{B} \neq \emptyset \\ + A \cap \bigcup \mathscr{B} & = + \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \} + \end{align*} -\begin{proof} + \begin{proof} - Let $A$ and $\mathscr{B}$ be sets. - We prove that - \begin{enumerate}[(i)] - \item For $\mathscr{B} \neq \emptyset$, - $A \cup \bigcap \mathscr{B} = - \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \}$. - \item $A \cap \bigcup \mathscr{B} = - \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \}$ - \end{enumerate} + Let $A$ and $\mathscr{B}$ be sets. + We prove that + \begin{enumerate}[(i)] + \item For $\mathscr{B} \neq \emptyset$, + $A \cup \bigcap \mathscr{B} = + \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \}$. + \item $A \cap \bigcup \mathscr{B} = + \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \}$ + \end{enumerate} - \paragraph{(i)}% + \paragraph{(i)}% - Suppose $\mathscr{B}$ is nonempty. - Then $\bigcap \mathscr{B}$ is defined. - By definition of the union and intersection of sets, - \begin{align*} - A \cup \bigcap \mathscr{B} - & = \{ x \mid x \in A \lor x \in \bigcap \mathscr{B} \} \\ - & = \{ x \mid x \in A \lor - x \in \{ y \mid (\forall b \in \mathscr{B}), y \in b \}\} \\ - & = \{ x \mid x \in A \lor (\forall b \in \mathscr{B}), x \in b \} \\ - & = \{ x \mid \forall b \in \mathscr{B}, x \in A \lor x \in b \} \\ - & = \{ x \mid \forall b \in \mathscr{B}, x \in A \cup b \} \\ - & = \{ x \mid - x \in \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \}\} \\ - & = \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \}. - \end{align*} + Suppose $\mathscr{B}$ is nonempty. + Then $\bigcap \mathscr{B}$ is defined. + By definition of the union and intersection of sets, + \begin{align*} + A \cup \bigcap \mathscr{B} + & = \{ x \mid x \in A \lor x \in \bigcap \mathscr{B} \} \\ + & = \{ x \mid x \in A \lor + x \in \{ y \mid (\forall b \in \mathscr{B}), y \in b \}\} \\ + & = \{ x \mid x \in A \lor (\forall b \in \mathscr{B}), x \in b \} \\ + & = \{ x \mid \forall b \in \mathscr{B}, x \in A \lor x \in b \} \\ + & = \{ x \mid \forall b \in \mathscr{B}, x \in A \cup b \} \\ + & = \{ x \mid + x \in \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \}\} \\ + & = \bigcap\; \{ A \cup X \mid X \in \mathscr{B} \}. + \end{align*} - \paragraph{(ii)}% + \paragraph{(ii)}% - By definition of the intersection and union of sets, - \begin{align*} - A \cap \bigcup \mathscr{B} - & = \{ x \mid x \in A \land x \in \bigcup \mathscr{B} \} \\ - & = \{ x \mid x \in A \land - x \in \{ y \mid (\exists b \in \mathscr{B}), y \in b \}\} \\ - & = \{ x \mid x \in A \land (\exists b \in \mathscr{B}), x \in b \} \\ - & = \{ x \mid \exists b \in \mathscr{B}, x \in A \land x \in b \} \\ - & = \{ x \mid \exists b \in \mathscr{B} x \in A \cap b \} \\ - & = \{ x \mid - x \in \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \}\} \\ - & = \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \}. - \end{align*} + By definition of the intersection and union of sets, + \begin{align*} + A \cap \bigcup \mathscr{B} + & = \{ x \mid x \in A \land x \in \bigcup \mathscr{B} \} \\ + & = \{ x \mid x \in A \land + x \in \{ y \mid (\exists b \in \mathscr{B}), y \in b \}\} \\ + & = \{ x \mid x \in A \land (\exists b \in \mathscr{B}), x \in b \} \\ + & = \{ x \mid \exists b \in \mathscr{B}, x \in A \land x \in b \} \\ + & = \{ x \mid \exists b \in \mathscr{B} x \in A \cap b \} \\ + & = \{ x \mid + x \in \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \}\} \\ + & = \bigcup\; \{ A \cap X \mid X \in \mathscr{B} \}. + \end{align*} -\end{proof} + \end{proof} \subsection{\unverified{General De Morgan's Laws}}% \hyperlabel{sub:general-de-morgans-laws} -For any set $C$ and $\mathscr{A} \neq \emptyset$, - \begin{align*} - C - \bigcup \mathscr{A} & = \bigcap\; \{ C - X \mid X \in \mathscr{A} \} \\ - C - \bigcap \mathscr{A} & = \bigcup\; \{ C - X \mid X \in \mathscr{A} \} - \end{align*} + For any set $C$ and $\mathscr{A} \neq \emptyset$, + \begin{align*} + C - \bigcup \mathscr{A} & = \bigcap\; \{ C - X \mid X \in \mathscr{A} \} \\ + C - \bigcap \mathscr{A} & = \bigcup\; \{ C - X \mid X \in \mathscr{A} \} + \end{align*} -\begin{proof} + \begin{proof} - Let $C$ and $\mathscr{A}$ be sets such that $\mathscr{A} \neq \emptyset$. - We prove that - \begin{enumerate}[(i)] - \item $C - \bigcup \mathscr{A} = - \bigcap\; \{ C - X \mid X \in \mathscr{A} \}$ - \item $C - \bigcap \mathscr{A} = - \bigcup\; \{ C - X \mid X \in \mathscr{A} \}$ - \end{enumerate} + Let $C$ and $\mathscr{A}$ be sets such that $\mathscr{A} \neq \emptyset$. + We prove that + \begin{enumerate}[(i)] + \item $C - \bigcup \mathscr{A} = + \bigcap\; \{ C - X \mid X \in \mathscr{A} \}$ + \item $C - \bigcap \mathscr{A} = + \bigcup\; \{ C - X \mid X \in \mathscr{A} \}$ + \end{enumerate} - \paragraph{(i)}% + \paragraph{(i)}% - By definition of the relative complement, union, and intersection of sets, - \begin{align*} - C - \bigcup \mathscr{A} - & = \{ x \mid x \in C \land x \not\in \bigcup \mathscr{A} \} \\ - & = \{ x \mid x \in C \land - x \not\in \{ y \mid (\exists b \in \mathscr{A}) y \in b \}\} \\ - & = \{ x \mid x \in C \land - \neg(\exists b \in \mathscr{A}, x \in b) \} \\ - & = \{ x \mid x \in C \land - (\forall b \in \mathscr{A}, x \not\in b) \} \\ - & = \{ x \mid - \forall b \in \mathscr{A}, x \in C \land x \not\in b \} \\ - & = \{ x \mid \forall b \in \mathscr{A}, x \in C - b \} \\ - & = \{ x \mid x \in \bigcap\; \{ C - X \mid X \in \mathscr{A} \} \\ - & = \bigcap\; \{ C - X \mid X \in \mathscr{A} \}. - \end{align*} + By definition of the relative complement, union, and intersection of sets, + \begin{align*} + C - \bigcup \mathscr{A} + & = \{ x \mid x \in C \land x \not\in \bigcup \mathscr{A} \} \\ + & = \{ x \mid x \in C \land + x \not\in \{ y \mid (\exists b \in \mathscr{A}) y \in b \}\} \\ + & = \{ x \mid x \in C \land + \neg(\exists b \in \mathscr{A}, x \in b) \} \\ + & = \{ x \mid x \in C \land + (\forall b \in \mathscr{A}, x \not\in b) \} \\ + & = \{ x \mid + \forall b \in \mathscr{A}, x \in C \land x \not\in b \} \\ + & = \{ x \mid \forall b \in \mathscr{A}, x \in C - b \} \\ + & = \{ x \mid x \in \bigcap\; \{ C - X \mid X \in \mathscr{A} \} \\ + & = \bigcap\; \{ C - X \mid X \in \mathscr{A} \}. + \end{align*} - \paragraph{(ii)}% + \paragraph{(ii)}% - By definition of the relative complement, union, and intersection of sets, - \begin{align*} - C - \bigcap \mathscr{A} - & = \{ x \mid x \in C \land x \not\in \bigcap \mathscr{A} \} \\ - & = \{ x \mid x \in C \land - x \not\in \{ y \mid (\forall b \in \mathscr{A}) y \in b \}\} \\ - & = \{ x \mid x \in C \land - \neg(\forall b \in \mathscr{A}, x \in b) \} \\ - & = \{ x \mid x \in C \land - \exists b \in \mathscr{A}, x \not\in b \} \\ - & = \{ x \mid - \exists b \in \mathscr{A}, x \in C \land x \not\in b \} \\ - & = \{ x \mid \exists b \in \mathscr{A}, x \in C - b \} \\ - & = \{ x \mid x \in \bigcup\; \{ C - X \mid X \in \mathscr{A} \} \} \\ - & = \bigcup\; \{ C - X \mid X \in \mathscr{A} \}. - \end{align*} + By definition of the relative complement, union, and intersection of sets, + \begin{align*} + C - \bigcap \mathscr{A} + & = \{ x \mid x \in C \land x \not\in \bigcap \mathscr{A} \} \\ + & = \{ x \mid x \in C \land + x \not\in \{ y \mid (\forall b \in \mathscr{A}) y \in b \}\} \\ + & = \{ x \mid x \in C \land + \neg(\forall b \in \mathscr{A}, x \in b) \} \\ + & = \{ x \mid x \in C \land + \exists b \in \mathscr{A}, x \not\in b \} \\ + & = \{ x \mid + \exists b \in \mathscr{A}, x \in C \land x \not\in b \} \\ + & = \{ x \mid \exists b \in \mathscr{A}, x \in C - b \} \\ + & = \{ x \mid x \in \bigcup\; \{ C - X \mid X \in \mathscr{A} \} \} \\ + & = \bigcup\; \{ C - X \mid X \in \mathscr{A} \}. + \end{align*} -\end{proof} + \end{proof} \subsection{\pending{% \texorpdfstring{$\cap$/$-$}{Intersection/Difference} Associativity}}% \hyperlabel{sub:intersection-difference-associativity} -Let $A$, $B$, and $C$ be sets. -Then $A \cap (B - C) = (A \cap B) - C$. - -\begin{proof} - - \lean{Mathlib/Data/Set/Basic}{Set.inter\_diff\_assoc} - Let $A$, $B$, and $C$ be sets. - By definition of the intersection and relative complement of sets, - \begin{align*} - A \cap (B - C) - & = \{ x \mid x \in A \land x \in B - C \} \\ - & = \{ x \mid x \in A \land (x \in B \land x \not\in C) \} \\ - & = \{ x \mid (x \in A \land x \in B) \land x \not\in C \} \\ - & = \{ x \mid x \in A \cap B \land x \not \in C \} \\ - & = (A \cap B) - C. - \end{align*} + Then $A \cap (B - C) = (A \cap B) - C$. -\end{proof} + \lean*{Mathlib/Data/Set/Basic}{Set.inter\_diff\_assoc} + + \begin{proof} + Let $A$, $B$, and $C$ be sets. + By definition of the intersection and relative complement of sets, + \begin{align*} + A \cap (B - C) + & = \{ x \mid x \in A \land x \in B - C \} \\ + & = \{ x \mid x \in A \land (x \in B \land x \not\in C) \} \\ + & = \{ x \mid (x \in A \land x \in B) \land x \not\in C \} \\ + & = \{ x \mid x \in A \cap B \land x \not \in C \} \\ + & = (A \cap B) - C. + \end{align*} + \end{proof} \subsection{\verified{Nonmembership of Symmetric Difference}} \hyperlabel{sub:nonmembership-symmetric-difference} -Let $A$ and $B$ be sets. $x \not\in A + B$ if and only if either - $x \in A \cap B$ or $x \not\in A \cup B$. + Let $A$ and $B$ be sets. $x \not\in A + B$ if and only if either + $x \in A \cap B$ or $x \not\in A \cup B$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Basic} + \code*{Bookshelf/Enderton/Set/Basic} {Set.not\_mem\_symm\_diff\_inter\_or\_not\_union} - By definition of the \nameref{ref:symmetric-difference}, - \begin{align*} - x \not\in A + B - & = \neg(x \in A + B) \\ - & = \neg[x \in (A - B) \cup (B - A)] \\ - & = \neg[x \in (A - B) \lor x \in (B - A)] \\ - & = \neg[(x \in A \land x \not\in B) \lor - (x \in B \land x \not\in A)] \\ - & = \neg(x \in A \land x \not\in B) \land - \neg(x \in B \land x \not\in A) \\ - & = (x \not\in A \lor x \in B) \land (x \not\in B \lor x \in A) \\ - & = ((x \not\in A \lor x \in B) \land x \not\in B) \lor - ((x \not\in A \lor x \in B) \land x \in A) \\ - & = (x \not\in A \land x \not\in B) \lor (x \in B \land x \in A) \\ - & = \neg(x \in A \lor x \in B) \lor (x \in B \land x \in A) \\ - & = x \not\in A \cup B \text{ or } x \in A \cap B. - \end{align*} - -\end{proof} + \begin{proof} + By definition of the \nameref{ref:symmetric-difference}, + \begin{align*} + x \not\in A + B + & = \neg(x \in A + B) \\ + & = \neg[x \in (A - B) \cup (B - A)] \\ + & = \neg[x \in (A - B) \lor x \in (B - A)] \\ + & = \neg[(x \in A \land x \not\in B) \lor + (x \in B \land x \not\in A)] \\ + & = \neg(x \in A \land x \not\in B) \land + \neg(x \in B \land x \not\in A) \\ + & = (x \not\in A \lor x \in B) \land (x \not\in B \lor x \in A) \\ + & = ((x \not\in A \lor x \in B) \land x \not\in B) \lor + ((x \not\in A \lor x \in B) \land x \in A) \\ + & = (x \not\in A \land x \not\in B) \lor (x \in B \land x \in A) \\ + & = \neg(x \in A \lor x \in B) \lor (x \in B \land x \in A) \\ + & = x \not\in A \cup B \text{ or } x \in A \cap B. + \end{align*} + \end{proof} \section{Exercises 2}% \hyperlabel{sec:exercises-2} @@ -1711,243 +1461,231 @@ Let $A$ and $B$ be sets. $x \not\in A + B$ if and only if either \subsection{\verified{Exercise 2.1}}% \hyperlabel{sub:exercise-2.1} -Assume that $A$ is the set of integers divisible by $4$. -Similarly assume that $B$ and $C$ are the sets of integers divisible by $9$ and - $10$, respectively. -What is in $A \cap B \cap C$? + Assume that $A$ is the set of integers divisible by $4$. + Similarly assume that $B$ and $C$ are the sets of integers divisible by $9$ and + $10$, respectively. + What is in $A \cap B \cap C$? -\begin{answer} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_1} - The set of integers divisible by $4$, $9$, and $10$. - -\end{answer} + \begin{answer} + The set of integers divisible by $4$, $9$, and $10$. + \end{answer} \subsection{\verified{Exercise 2.2}}% \hyperlabel{sub:exercise-2.2} -Give an example of sets $A$ and $B$ for which $\bigcup A = \bigcup B$ but - $A \neq B$. + Give an example of sets $A$ and $B$ for which $\bigcup A = \bigcup B$ but + $A \neq B$. -\begin{answer} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_2} - Let $A = \{\{1\}, \{2\}\}$ and $B = \{\{1, 2\}\}$. - -\end{answer} + \begin{answer} + Let $A = \{\{1\}, \{2\}\}$ and $B = \{\{1, 2\}\}$. + \end{answer} \subsection{\verified{Exercise 2.3}}% \hyperlabel{sub:exercise-2.3} -Show that every member of a set $A$ is a subset of $\bigcup A$. -(This was stated as an example in this section.) + Show that every member of a set $A$ is a subset of $\bigcup A$. + (This was stated as an example in this section.) -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_3} - Let $x \in A$. - By definition, $$\bigcup A = \{ y \mid (\exists b \in A) y \in b\}.$$ - Then $\{ y \mid y \in x\} \subseteq \bigcup A$. - But $\{ y \mid y \in x\} = x$. - Thus $x \subseteq \bigcup A$. - -\end{proof} + \begin{proof} + Let $x \in A$. + By definition, $$\bigcup A = \{ y \mid (\exists b \in A) y \in b\}.$$ + Then $\{ y \mid y \in x\} \subseteq \bigcup A$. + But $\{ y \mid y \in x\} = x$. + Thus $x \subseteq \bigcup A$. + \end{proof} \subsection{\verified{Exercise 2.4}}% \hyperlabel{sub:exercise-2.4} -Show that if $A \subseteq B$, then $\bigcup A \subseteq \bigcup B$. + Show that if $A \subseteq B$, then $\bigcup A \subseteq \bigcup B$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_4} - Let $A$ and $B$ be sets such that $A \subseteq B$. - Let $x \in \bigcup A$. - By definition of the union, there exists some $b \in A$ such that $x \in b$. - By definition of the subset, $b \in B$. - This immediatley implies $x \in \bigcup B$. - Since this holds for all $x \in \bigcup A$, it follows - $\bigcup A \subseteq \bigcup B$. - -\end{proof} + \begin{proof} + Let $A$ and $B$ be sets such that $A \subseteq B$. + Let $x \in \bigcup A$. + By definition of the union, there exists some $b \in A$ such that $x \in b$. + By definition of the subset, $b \in B$. + This immediatley implies $x \in \bigcup B$. + Since this holds for all $x \in \bigcup A$, it follows + $\bigcup A \subseteq \bigcup B$. + \end{proof} \subsection{\verified{Exercise 2.5}}% \hyperlabel{sub:exercise-2.5} -Assume that every member of $\mathscr{A}$ is a subset of $B$. -Show that $\bigcup \mathscr{A} \subseteq B$. + Assume that every member of $\mathscr{A}$ is a subset of $B$. + Show that $\bigcup \mathscr{A} \subseteq B$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_5} - Let $x \in \bigcup \mathscr{A}$. - By definition, - $$\bigcup \mathscr{A} = \{ y \mid (\exists b \in A)y \in b \}.$$ - Then there exists some $b \in A$ such that $x \in b$. - By hypothesis, $b \subseteq B$. - Thus $x$ must also be a member of $B$. - Since this holds for all $x \in \bigcup \mathscr{A}$, it follows - $\bigcup \mathscr{A} \subseteq B$. - -\end{proof} + \begin{proof} + Let $x \in \bigcup \mathscr{A}$. + By definition, + $$\bigcup \mathscr{A} = \{ y \mid (\exists b \in A)y \in b \}.$$ + Then there exists some $b \in A$ such that $x \in b$. + By hypothesis, $b \subseteq B$. + Thus $x$ must also be a member of $B$. + Since this holds for all $x \in \bigcup \mathscr{A}$, it follows + $\bigcup \mathscr{A} \subseteq B$. + \end{proof} \subsection{\verified{Exercise 2.6a}}% \hyperlabel{sub:exercise-2.6a} -Show that for any set $A$, $\bigcup \powerset{A} = A$. + Show that for any set $A$, $\bigcup \powerset{A} = A$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_6a} - We prove that (i) $\bigcup \powerset{A} \subseteq A$ and (ii) - $A \subseteq \bigcup \powerset{A}$. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:exercise-2.6a-i} + We prove that (i) $\bigcup \powerset{A} \subseteq A$ and (ii) + $A \subseteq \bigcup \powerset{A}$. - By definition, the \nameref{ref:power-set} of $A$ is the set of all subsets - of $A$. - In other words, every member of $\powerset{A}$ is a subset of $A$. - By \nameref{sub:exercise-2.5}, $\bigcup \powerset{A} \subseteq A$. + \paragraph{(i)}% + \hyperlabel{par:exercise-2.6a-i} - \paragraph{(ii)}% - \hyperlabel{par:exercise-2.6a-ii} + By definition, the \nameref{ref:power-set} of $A$ is the set of all + subsets of $A$. + In other words, every member of $\powerset{A}$ is a subset of $A$. + By \nameref{sub:exercise-2.5}, $\bigcup \powerset{A} \subseteq A$. - Let $x \in A$. - By definition of the power set of $A$, $\{x\} \in \powerset{A}$. - By definition of the union, - $$\bigcup \powerset{A} = - \{ y \mid (\exists b \in \powerset{A}), y \in b).$$ - Since $x \in \{x\}$ and $\{x\} \in \powerset{A}$, it follows - $x \in \bigcup \powerset{A}$. - Thus $A \subseteq \bigcup \powerset{A}$. + \paragraph{(ii)}% + \hyperlabel{par:exercise-2.6a-ii} - \paragraph{Conclusion}% + Let $x \in A$. + By definition of the power set of $A$, $\{x\} \in \powerset{A}$. + By definition of the union, + $$\bigcup \powerset{A} = + \{ y \mid (\exists b \in \powerset{A}), y \in b).$$ + Since $x \in \{x\}$ and $\{x\} \in \powerset{A}$, it follows + $x \in \bigcup \powerset{A}$. + Thus $A \subseteq \bigcup \powerset{A}$. - By \nameref{par:exercise-2.6a-i} and \nameref{par:exercise-2.6a-ii}, - $\bigcup \powerset{A} = A$. + \paragraph{Conclusion}% -\end{proof} + By \nameref{par:exercise-2.6a-i} and \nameref{par:exercise-2.6a-ii}, + $\bigcup \powerset{A} = A$. + + \end{proof} \subsection{\verified{Exercise 2.6b}}% \hyperlabel{sub:exercise-2.6b} -Show that $A \subseteq \powerset{\bigcup A}$. -Under what conditions does equality hold? + Show that $A \subseteq \powerset{\bigcup A}$. + Under what conditions does equality hold? -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_6b} - Let $x \in A$. - By \nameref{sub:exercise-2.3}, $x$ is a subset of $\bigcup A$. - By the definition of the \nameref{ref:power-set}, - $$\powerset{\bigcup A} = \{ y \mid y \subseteq \bigcup A \}.$$ - Therefore $x \in \powerset{\bigcup A}$. - Since this holds for all $x \in A$, $A \subseteq \powerset{\bigcup A}$. + \begin{proof} - \suitdivider + Let $x \in A$. + By \nameref{sub:exercise-2.3}, $x$ is a subset of $\bigcup A$. + By the definition of the \nameref{ref:power-set}, + $$\powerset{\bigcup A} = \{ y \mid y \subseteq \bigcup A \}.$$ + Therefore $x \in \powerset{\bigcup A}$. + Since this holds for all $x \in A$, $A \subseteq \powerset{\bigcup A}$. - We show equality holds if and only if there exists some set $B$ such that - $A = \powerset{B}$. + \suitdivider - \paragraph{($\Rightarrow$)}% - \hyperlabel{par:exercise-2.6b-right} + We show equality holds if and only if there exists some set $B$ such that + $A = \powerset{B}$. - Suppose $A = \powerset{\bigcup A}$. - Then our statement immediately follows by settings $B = \bigcup A$. + \paragraph{($\Rightarrow$)}% + \hyperlabel{par:exercise-2.6b-right} - \paragraph{($\Leftarrow$)}% - \hyperlabel{par:exercise-2.6b-left} + Suppose $A = \powerset{\bigcup A}$. + Then our statement immediately follows by settings $B = \bigcup A$. - Suppose there exists some set $B$ such that $A = \powerset{B}$. - Therefore - \begin{align*} - \powerset{\bigcup A} - & = \powerset{\left(\bigcup {\powerset {B}}\right)} \\ - & = \powerset{B} & \textref{sub:exercise-2.6a} \\ - & = A. - \end{align*} + \paragraph{($\Leftarrow$)}% + \hyperlabel{par:exercise-2.6b-left} - \paragraph{Conclusion}% + Suppose there exists some set $B$ such that $A = \powerset{B}$. + Therefore + \begin{align*} + \powerset{\bigcup A} + & = \powerset{\left(\bigcup {\powerset {B}}\right)} \\ + & = \powerset{B} & \textref{sub:exercise-2.6a} \\ + & = A. + \end{align*} - By \nameref{par:exercise-2.6b-right} and \nameref{par:exercise-2.6b-left}, - $A = \powerset{\bigcup A}$ if and only if there exists some set $B$ such - that $A = \powerset{B}$. + \paragraph{Conclusion}% -\end{proof} + By \nameref{par:exercise-2.6b-right} and \nameref{par:exercise-2.6b-left}, + $A = \powerset{\bigcup A}$ if and only if there exists some set $B$ such + that $A = \powerset{B}$. + + \end{proof} \subsection{\verified{Exercise 2.7a}}% \hyperlabel{sub:exercise-2.7a} -Show that for any sets $A$ and $B$, - $$\powerset{A} \cap \powerset{B} = \powerset{(A \cap B)}.$$ + Show that for any sets $A$ and $B$, + $$\powerset{A} \cap \powerset{B} = \powerset{(A \cap B)}.$$ -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_7a} - Let $A$ and $B$ be arbitrary sets. We show that - $\powerset{A} \cap \powerset{B} \subseteq \powerset{(A \cap B)}$ and then - show that $\powerset{A} \cap \powerset{B} \supseteq \powerset{(A \cap B)}$. + \begin{proof} - \paragraph{($\subseteq$)}% + Let $A$ and $B$ be arbitrary sets. We show that + $\powerset{A} \cap \powerset{B} \subseteq \powerset{(A \cap B)}$ and then + show that + $\powerset{A} \cap \powerset{B} \supseteq \powerset{(A \cap B)}$. - Let $x \in \powerset{A} \cap \powerset{B}$. - That is, $x \in \powerset{A}$ and $x \in \powerset{B}$. - By the definition of the \nameref{ref:power-set}, - \begin{align*} - \powerset{A} & = \{ y \mid y \subseteq A \} \\ - \powerset{B} & = \{ y \mid y \subseteq B \} - \end{align*} - Thus $x \subseteq A$ and $x \subseteq B$, meaning $x \subseteq A \cap B$. - But then $x \in \powerset{(A \cap B)}$, the set of all subsets of - $A \cap B$. - Since this holds for all $x \in \powerset{A} \cap \powerset{B}$, it follows - $$\powerset{A} \cap \powerset{B} \subseteq \powerset{(A \cap B)}.$$ + \paragraph{($\subseteq$)}% - \paragraph{($\supseteq$)}% + Let $x \in \powerset{A} \cap \powerset{B}$. + That is, $x \in \powerset{A}$ and $x \in \powerset{B}$. + By the definition of the \nameref{ref:power-set}, + \begin{align*} + \powerset{A} & = \{ y \mid y \subseteq A \} \\ + \powerset{B} & = \{ y \mid y \subseteq B \} + \end{align*} + Thus $x \subseteq A$ and $x \subseteq B$, meaning $x \subseteq A \cap B$. + But then $x \in \powerset{(A \cap B)}$, the set of all subsets of + $A \cap B$. + Since this holds for all $x \in \powerset{A} \cap \powerset{B}$, it + follows + $$\powerset{A} \cap \powerset{B} \subseteq \powerset{(A \cap B)}.$$ - Let $x \in \powerset{(A \cap B)}$. - By the definition of the \nameref{ref:power-set}, - $$\powerset{(A \cap B)} = \{ y \mid y \subseteq A \cap B \}.$$ - Thus $x \subseteq A \cap B$, meaning $x \subseteq A$ and $x \subseteq B$. - But this implies $x \in \powerset{A}$, the set of all subsets of $A$. - Likewise $x \in \powerset{B}$, the set of all subsets of $B$. - Thus $x \in \powerset{A} \cap \powerset{B}$. - Since this holds for all $x \in \powerset{(A \cap B)}$, it follows - $$\powerset{(A \cap B)} \subseteq \powerset{A} \cap \powerset{B}.$$ + \paragraph{($\supseteq$)}% - \paragraph{Conclusion}% + Let $x \in \powerset{(A \cap B)}$. + By the definition of the \nameref{ref:power-set}, + $$\powerset{(A \cap B)} = \{ y \mid y \subseteq A \cap B \}.$$ + Thus $x \subseteq A \cap B$, meaning $x \subseteq A$ and $x \subseteq B$. + But this implies $x \in \powerset{A}$, the set of all subsets of $A$. + Likewise $x \in \powerset{B}$, the set of all subsets of $B$. + Thus $x \in \powerset{A} \cap \powerset{B}$. + Since this holds for all $x \in \powerset{(A \cap B)}$, it follows + $$\powerset{(A \cap B)} \subseteq \powerset{A} \cap \powerset{B}.$$ - Since each side of our identity is a subset of the other, - $$\powerset{(A \cap B)} = \powerset{A} \cap \powerset{B}.$$ + \paragraph{Conclusion}% -\end{proof} + Since each side of our identity is a subset of the other, + $$\powerset{(A \cap B)} = \powerset{A} \cap \powerset{B}.$$ + + \end{proof} \subsection{\verified{Exercise 2.7b}}% \hyperlabel{sub:exercise-2.7b} -Show that $\powerset{A} \cup \powerset{B} \subseteq \powerset{(A \cup B)}$. -Under what conditions does equality hold? - -\begin{proof} - - \statementpadding + Show that $\powerset{A} \cup \powerset{B} \subseteq \powerset{(A \cup B)}$. + Under what conditions does equality hold? \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_7b\_i} @@ -1955,864 +1693,839 @@ Under what conditions does equality hold? \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_7b\_ii} - Let $x \in \powerset{A} \cup \powerset{B}$. - By definition, $x \in \powerset{A}$ or $x \in \powerset{B}$ (or both). - By the definition of the \nameref{ref:power-set}, - \begin{align*} - \powerset{A} &= \{ y \mid y \subseteq A \} \\ - \powerset{B} &= \{ y \mid y \subseteq B \}. - \end{align*} - Thus $x \subseteq A$ or $x \subseteq B$. - Therefore $x \subseteq A \cup B$. - But then $x \in \powerset{(A \cup B)}$, the set of all subsets of $A \cup B$. + \begin{proof} - \suitdivider - - We show equality holds if and only if one of $A$ or $B$ is a subset of the - other. - - \paragraph{($\Rightarrow$)}% - \hyperlabel{par:exercise-2.7b-right} - - Suppose - \begin{equation} - \hyperlabel{sub:exercise-2.7b-eq1} - \powerset{A} \cup \powerset{B} = \powerset{(A \cup B)}. - \end{equation} + Let $x \in \powerset{A} \cup \powerset{B}$. + By definition, $x \in \powerset{A}$ or $x \in \powerset{B}$ (or both). By the definition of the \nameref{ref:power-set}, - $A \cup B \in \powerset{(A \cup B)}$. - Then \eqref{sub:exercise-2.7b-eq1} implies - $A \cup B \in \powerset{A} \cup \powerset{B}$. - That is, $A \cup B \in \powerset{A}$ or $A \cup B \in \powerset{B}$ (or - both). - - For the sake of contradiction, suppose $A \not\subseteq B$ and - $B \not\subseteq A$. - Then there exists an element $x \in A$ such that $x \not\in B$ and there - exists an element $y \in B$ such that $y \not\in A$. - But then $A \cup B \not\in \powerset{A}$ since $y$ cannot be a member of a - member of $\powerset{A}$. - Likewise, $A \cup B \not\in \powerset{B}$ since $x$ cannot be a member of a - member of $\powerset{B}$. - Therefore our assumption is incorrect. - In other words, $A \subseteq B$ or $B \subseteq A$. - - \paragraph{($\Leftarrow$)}% - \hyperlabel{par:exercise-2.7b-left} - - WLOG, suppose $A \subseteq B$. - Then, by \nameref{sub:exercise-1.3}, $\powerset{A} \subseteq \powerset{B}$. - Thus \begin{align*} - \powerset{A} \cup \powerset{B} - & = \powerset{B} \\ - & = \powerset{A \cup B}. + \powerset{A} &= \{ y \mid y \subseteq A \} \\ + \powerset{B} &= \{ y \mid y \subseteq B \}. \end{align*} + Thus $x \subseteq A$ or $x \subseteq B$. + Therefore $x \subseteq A \cup B$. + But then $x \in \powerset{(A \cup B)}$, the set of all subsets of + $A \cup B$. - \paragraph{Conclusion}% + \suitdivider - By \nameref{par:exercise-2.7b-right} and \nameref{par:exercise-2.7b-left}, - it follows - $\powerset{A} \cup \powerset{B} \subseteq \powerset{(A \cup B)}$ if and - only if $A \subseteq B$ or $B \subseteq A$. + We show equality holds if and only if one of $A$ or $B$ is a subset of the + other. -\end{proof} + \paragraph{($\Rightarrow$)}% + \hyperlabel{par:exercise-2.7b-right} + + Suppose + \begin{equation} + \hyperlabel{sub:exercise-2.7b-eq1} + \powerset{A} \cup \powerset{B} = \powerset{(A \cup B)}. + \end{equation} + By the definition of the \nameref{ref:power-set}, + $A \cup B \in \powerset{(A \cup B)}$. + Then \eqref{sub:exercise-2.7b-eq1} implies + $A \cup B \in \powerset{A} \cup \powerset{B}$. + That is, $A \cup B \in \powerset{A}$ or $A \cup B \in \powerset{B}$ (or + both). + + For the sake of contradiction, suppose $A \not\subseteq B$ and + $B \not\subseteq A$. + Then there exists an element $x \in A$ such that $x \not\in B$ and there + exists an element $y \in B$ such that $y \not\in A$. + But then $A \cup B \not\in \powerset{A}$ since $y$ cannot be a member of a + member of $\powerset{A}$. + Likewise, $A \cup B \not\in \powerset{B}$ since $x$ cannot be a member of + a member of $\powerset{B}$. + Therefore our assumption is incorrect. + In other words, $A \subseteq B$ or $B \subseteq A$. + + \paragraph{($\Leftarrow$)}% + \hyperlabel{par:exercise-2.7b-left} + + WLOG, suppose $A \subseteq B$. + Then, by \nameref{sub:exercise-1.3}, + $\powerset{A} \subseteq \powerset{B}$. + Thus + \begin{align*} + \powerset{A} \cup \powerset{B} + & = \powerset{B} \\ + & = \powerset{A \cup B}. + \end{align*} + + \paragraph{Conclusion}% + + By \nameref{par:exercise-2.7b-right} and \nameref{par:exercise-2.7b-left}, + it follows + $\powerset{A} \cup \powerset{B} \subseteq \powerset{(A \cup B)}$ if and + only if $A \subseteq B$ or $B \subseteq A$. + + \end{proof} \subsection{\unverified{Exercise 2.8}}% \hyperlabel{sub:exercise-2.8} -Show that there is no set to which every singleton (that is, every set of the - form $\{x\}$) belongs. -[\textit{Suggestion}: Show that from such a set, we could construct a set to - which every set belonged.] + Show that there is no set to which every singleton (that is, every set of the + form $\{x\}$) belongs. + [\textit{Suggestion}: Show that from such a set, we could construct a set to + which every set belonged.] -\begin{proof} - - We proceed by contradiction. - Suppose there existed a set $A$ consisting of every singleton. - Then the \nameref{ref:union-axiom} suggests $\bigcup A$ is a set. - But this set is precisely the class of all sets, which is \textit{not} a set. - Thus our original assumption was incorrect. - That is, there is no set to which every singleton belongs. - -\end{proof} + \begin{proof} + We proceed by contradiction. + Suppose there existed a set $A$ consisting of every singleton. + Then the \nameref{ref:union-axiom} suggests $\bigcup A$ is a set. + But this set is precisely the class of all sets, which is \textit{not} a + set. + Thus our original assumption was incorrect. + That is, there is no set to which every singleton belongs. + \end{proof} \subsection{\verified{Exercise 2.9}}% \hyperlabel{sub:exercise-2.9} -Give an example of sets $a$ and $B$ for which $a \in B$ but - $\powerset{a} \not\in \powerset{B}$. + Give an example of sets $a$ and $B$ for which $a \in B$ but + $\powerset{a} \not\in \powerset{B}$. -\begin{answer} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_9} - Let $a = \{1\}$ and $B = \{\{1\}\}$. - Then - \begin{align*} - \powerset{a} & = \{\emptyset, \{1\}\} \\ - \powerset{B} & = \{\emptyset, \{\{1\}\}\}. - \end{align*} - It immediately follows that $\powerset{a} \not\in \powerset{B}$. - -\end{answer} + \begin{answer} + Let $a = \{1\}$ and $B = \{\{1\}\}$. + Then + \begin{align*} + \powerset{a} & = \{\emptyset, \{1\}\} \\ + \powerset{B} & = \{\emptyset, \{\{1\}\}\}. + \end{align*} + It immediately follows that $\powerset{a} \not\in \powerset{B}$. + \end{answer} \subsection{\verified{Exercise 2.10}}% \hyperlabel{sub:exercise-2.10} -Show that if $a \in B$, then $\powerset{a} \in \powerset{\powerset{\bigcup B}}$. -[\textit{Suggestion}: If you need help, look in the Appendix.] + Show that if $a \in B$, then + $\powerset{a} \in \powerset{\powerset{\bigcup B}}$. + [\textit{Suggestion}: If you need help, look in the Appendix.] -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_10} - Suppose $a \in B$. - By \nameref{sub:exercise-2.3}, $a \subseteq \bigcup B$. - By \nameref{sub:exercise-1.3}, $\powerset{a} \subseteq \powerset{\bigcup B}$. - By the definition of the \nameref{ref:power-set}, - $$\powerset{\powerset{\bigcup B}} = - \{ y \mid y \subseteq \powerset{\bigcup B} \}.$$ - Therefore $\powerset{a} \in \powerset{\powerset{\bigcup B}}$. - -\end{proof} + \begin{proof} + Suppose $a \in B$. + By \nameref{sub:exercise-2.3}, $a \subseteq \bigcup B$. + By \nameref{sub:exercise-1.3}, + $\powerset{a} \subseteq \powerset{\bigcup B}$. + By the definition of the \nameref{ref:power-set}, + $$\powerset{\powerset{\bigcup B}} = + \{ y \mid y \subseteq \powerset{\bigcup B} \}.$$ + Therefore $\powerset{a} \in \powerset{\powerset{\bigcup B}}$. + \end{proof} \subsection{\verified{Exercise 2.11}}% \hyperlabel{sub:exercise-2.11} -Show that for any sets $A$ and $B$, - $$A = (A \cap B) \cup (A - B) \quad\text{and}\quad - A \cup (B - A) = A \cup B.$$ + Show that for any sets $A$ and $B$, + $$A = (A \cap B) \cup (A - B) \quad\text{and}\quad + A \cup (B - A) = A \cup B.$$ -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_2} + \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_11\_i} \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_11\_ii} - \noindent Let $A$ and $B$ be sets. - We prove that - \begin{enumerate}[(i)] - \item $A = (A \cap B) \cup (A - B)$ - \item $A \cup (B - A) = A \cup B$ - \end{enumerate} + \begin{proof} + Let $A$ and $B$ be sets. + We prove that + \begin{enumerate}[(i)] + \item $A = (A \cap B) \cup (A - B)$ + \item $A \cup (B - A) = A \cup B$ + \end{enumerate} - \paragraph{(i)}% + \paragraph{(i)}% - By definition of the intersection, union, and relative complements of sets, - \begin{align*} - (A \cap B) \cup (A - B) - & = \{ x \mid x \in A \cap B \lor x \in A - B \} \\ - & = \{ x \mid x \in \{ y \mid y \in A \land y \in B \} \lor - x \in A - B \} \\ - & = \{ x \mid (x \in A \land x \in B) \lor x \in A - B \} \\ - & = \{ x \mid (x \in A \land x \in B) \lor - x \in \{ y \mid y \in A \land y \not\in B \} \} \\ - & = \{ x \mid (x \in A \land x \in B) \lor - (x \in A \land x \not\in B) \} \\ - & = \{ x \mid x \in A \lor (x \in B \land x \not\in B) \} \\ - & = \{ x \mid x \in A \lor F \} \\ - & = \{ x \mid x \in A \} \\ - & = A. - \end{align*} + By definition of the intersection, union, and relative complements of + sets, + \begin{align*} + (A \cap B) \cup (A - B) + & = \{ x \mid x \in A \cap B \lor x \in A - B \} \\ + & = \{ x \mid x \in \{ y \mid y \in A \land y \in B \} \lor + x \in A - B \} \\ + & = \{ x \mid (x \in A \land x \in B) \lor x \in A - B \} \\ + & = \{ x \mid (x \in A \land x \in B) \lor + x \in \{ y \mid y \in A \land y \not\in B \} \} \\ + & = \{ x \mid (x \in A \land x \in B) \lor + (x \in A \land x \not\in B) \} \\ + & = \{ x \mid x \in A \lor (x \in B \land x \not\in B) \} \\ + & = \{ x \mid x \in A \lor F \} \\ + & = \{ x \mid x \in A \} \\ + & = A. + \end{align*} - \paragraph{(ii)}% + \paragraph{(ii)}% - By definition of the union and relative complements of sets, - \begin{align*} - A \cup (B - A) - & = \{ x \mid x \in A \lor x \in B - A \} \\ - & = \{ x \mid x \in A \lor - x \in \{ y \mid y \in B \land y \not\in A \} \} \\ - & = \{ x \mid x \in A \lor (x \in B \land x \not\in A) \} \\ - & = \{ x \mid (x \in A \lor x \in B) \land - (x \in A \lor x \not\in A) \} \\ - & = \{ x \mid (x \in A \lor x \in B) \land T \} \\ - & = \{ x \mid x \in A \lor x \in B \} \\ - & = \{ x \mid x \in A \cup B \} \\ - & = A \cup B. - \end{align*} + By definition of the union and relative complements of sets, + \begin{align*} + A \cup (B - A) + & = \{ x \mid x \in A \lor x \in B - A \} \\ + & = \{ x \mid x \in A \lor + x \in \{ y \mid y \in B \land y \not\in A \} \} \\ + & = \{ x \mid x \in A \lor (x \in B \land x \not\in A) \} \\ + & = \{ x \mid (x \in A \lor x \in B) \land + (x \in A \lor x \not\in A) \} \\ + & = \{ x \mid (x \in A \lor x \in B) \land T \} \\ + & = \{ x \mid x \in A \lor x \in B \} \\ + & = \{ x \mid x \in A \cup B \} \\ + & = A \cup B. + \end{align*} -\end{proof} + \end{proof} \subsection{\verified{Exercise 2.12}}% \hyperlabel{sub:exercise-2.12} -Verify the following identity (one of De Morgan's laws): - $$C - (A \cap B) = (C - A) \cup (C - B).$$ + Verify the following identity (one of De Morgan's laws): + $$C - (A \cap B) = (C - A) \cup (C - B).$$ -\begin{proof} - - Refer to \nameref{sub:de-morgans-laws}. - -\end{proof} + \begin{proof} + Refer to \nameref{sub:de-morgans-laws}. + \end{proof} \subsection{\verified{Exercise 2.13}}% \hyperlabel{sub:exercise-2.13} -Show that if $A \subseteq B$, then $C - B \subseteq C - A$. + Show that if $A \subseteq B$, then $C - B \subseteq C - A$. -\begin{proof} - - Refer to \nameref{sub:anti-monotonicity}. - -\end{proof} + \begin{proof} + Refer to \nameref{sub:anti-monotonicity}. + \end{proof} \subsection{\verified{Exercise 2.14}}% \hyperlabel{sub:exercise-2.14} -Show by example that for some sets $A$, $B$, and $C$, the set $A - (B - C)$ is - different from $(A - B) - C$. + Show by example that for some sets $A$, $B$, and $C$, the set $A - (B - C)$ is + different from $(A - B) - C$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_14} - Let $A = \{1, 2, 3\}$, $B = \{2, 3, 4\}$, and $C = \{3, 4, 5\}$. - Then - \begin{align*} - A - (B - C) - & = \{1, 2, 3\} - (\{2, 3, 4\} - \{3, 4, 5\}) \\ - & = \{1, 2, 3\} - \{2\} \\ - & = \{1, 3\} - \end{align*} - but - \begin{align*} - (A - B) - C - & = (\{1, 2, 3\} - \{2, 3, 4\}) - \{3, 4, 5\} \\ - & = \{1\} - \{3, 4, 5\} \\ - & = \{1\}. - \end{align*} - -\end{proof} + \begin{proof} + Let $A = \{1, 2, 3\}$, $B = \{2, 3, 4\}$, and $C = \{3, 4, 5\}$. + Then + \begin{align*} + A - (B - C) + & = \{1, 2, 3\} - (\{2, 3, 4\} - \{3, 4, 5\}) \\ + & = \{1, 2, 3\} - \{2\} \\ + & = \{1, 3\} + \end{align*} + but + \begin{align*} + (A - B) - C + & = (\{1, 2, 3\} - \{2, 3, 4\}) - \{3, 4, 5\} \\ + & = \{1\} - \{3, 4, 5\} \\ + & = \{1\}. + \end{align*} + \end{proof} \subsection{\pending{Exercise 2.15a}}% \hyperlabel{sub:exercise-2.15a} -Show that $A \cap (B + C) = (A \cap B) + (A \cap C)$. + Show that $A \cap (B + C) = (A \cap B) + (A \cap C)$. -\begin{proof} + \lean*{Mathlib/Data/Set/Basic} + {Set.inter\_symmDiff\_distrib\_left} - \lean{Mathlib/Data/Set/Basic}{Set.inter\_symmDiff\_distrib\_left} - - By definition of the intersection, \nameref{ref:symmetric-difference}, and - relative complement of sets, - \begin{align*} - (A & \cap B) + (A \cap C) \\ - & = [(A \cap B) - (A \cap C)] \cup [(A \cap C) - (A \cap B)] \\ - & = [(A \cap B) - A] \\ - & \qquad \cup [(A \cap B) - C] \\ - & \qquad \cup [(A \cap C) - A] \\ - & \qquad \cup [(A \cap C) - B] - & \textref{sub:de-morgans-laws} \\ - & = [A \cap (B - A)] \\ - & \qquad \cup [A \cap (B - C)] \\ - & \qquad \cup [A \cap (C - A)] \\ - & \qquad \cup [A \cap (C - B)] - & \textref{sub:intersection-difference-associativity} \\ - & = \emptyset \\ - & \qquad \cup [A \cap (B - C)] \\ - & \qquad \cup \emptyset \\ - & \qquad \cup [A \cap (C - B)] - & \textref{sub:identitives-involving-empty-set} \\ - & = [A \cap (B - C)] \cup [A \cap (C - B)] \\ - & = A \cap [(B - C) \cup (C - B)] - & \textref{sub:distributive-laws} \\ - & = A \cap (B + C). - \end{align*} - -\end{proof} + \begin{proof} + By definition of the intersection, \nameref{ref:symmetric-difference}, and + relative complement of sets, + \begin{align*} + (A & \cap B) + (A \cap C) \\ + & = [(A \cap B) - (A \cap C)] \cup [(A \cap C) - (A \cap B)] \\ + & = [(A \cap B) - A] \\ + & \qquad \cup [(A \cap B) - C] \\ + & \qquad \cup [(A \cap C) - A] \\ + & \qquad \cup [(A \cap C) - B] + & \textref{sub:de-morgans-laws} \\ + & = [A \cap (B - A)] \\ + & \qquad \cup [A \cap (B - C)] \\ + & \qquad \cup [A \cap (C - A)] \\ + & \qquad \cup [A \cap (C - B)] + & \textref{sub:intersection-difference-associativity} \\ + & = \emptyset \\ + & \qquad \cup [A \cap (B - C)] \\ + & \qquad \cup \emptyset \\ + & \qquad \cup [A \cap (C - B)] + & \textref{sub:identitives-involving-empty-set} \\ + & = [A \cap (B - C)] \cup [A \cap (C - B)] \\ + & = A \cap [(B - C) \cup (C - B)] + & \textref{sub:distributive-laws} \\ + & = A \cap (B + C). + \end{align*} + \end{proof} \subsection{\pending{Exercise 2.15b}}% \hyperlabel{sub:exercise-2.15b} -Show that $A + (B + C) = (A + B) + C$. + Show that $A + (B + C) = (A + B) + C$. -\begin{proof} + \lean*{Mathlib/Data/Set/Basic} + {Set.symmDiff\_assoc} - \lean{Mathlib/Data/Set/Basic}{Set.symmDiff\_assoc} + \begin{proof} + Let $A$, $B$, and $C$ be sets. + We prove that + \begin{enumerate}[(i)] + \item $A + (B + C) \subseteq (A + B) + C$ + \item $(A + B) + C \subseteq A + (B + C)$ + \end{enumerate} - \noindent Let $A$, $B$, and $C$ be sets. - We prove that - \begin{enumerate}[(i)] - \item $A + (B + C) \subseteq (A + B) + C$ - \item $(A + B) + C \subseteq A + (B + C)$ - \end{enumerate} + \paragraph{(i)}% + \hyperlabel{par:exercise-2.15b-i} - \paragraph{(i)}% - \hyperlabel{par:exercise-2.15b-i} + Let $x \in A + (B + C)$. + Then $x$ is in $A$ or in $B + C$, but not both. + There are two cases to consider: - Let $x \in A + (B + C)$. - Then $x$ is in $A$ or in $B + C$, but not both. - There are two cases to consider: + \subparagraph{Case 1}% - \subparagraph{Case 1}% + Suppose $x \in A$ and $x \not\in B + C$. + Then, by \nameref{sub:nonmembership-symmetric-difference}, + (a) $x \in B \cap C$ or (b) $x \not\in B \cup C$. + Suppose (a) was true. + That is, $x \in B$ and $x \in C$. + Since $x$ is a member of $A$ and $B$, $x \not\in (A + B)$. + Since $x$ is not a member of $A + B$ but is a member of $C$, + $x \in (A + B) + C$. + Now suppose (b) was true. + That is, $x \not\in B$ and $x \not\in C$. + Since $x$ is a member of $A$ but not $B$, $x \in (A + B)$. + Since $x$ is a member of $A + B$ but not $C$, $x \in (A + B) + C$. - Suppose $x \in A$ and $x \not\in B + C$. - Then, by \nameref{sub:nonmembership-symmetric-difference}, - (a) $x \in B \cap C$ or (b) $x \not\in B \cup C$. - Suppose (a) was true. - That is, $x \in B$ and $x \in C$. - Since $x$ is a member of $A$ and $B$, $x \not\in (A + B)$. - Since $x$ is not a member of $A + B$ but is a member of $C$, - $x \in (A + B) + C$. - Now suppose (b) was true. - That is, $x \not\in B$ and $x \not\in C$. - Since $x$ is a member of $A$ but not $B$, $x \in (A + B)$. - Since $x$ is a member of $A + B$ but not $C$, $x \in (A + B) + C$. + \subparagraph{Case 2}% - \subparagraph{Case 2}% + Suppose $x \in B + C$ and $x \not\in A$. + Then (a) $x \in B$ or (b) $x \in C$ but not both. + Suppose (a) was true. + That is, $x \in B$ and $x \not\in C$. + Since $x$ is not a member of $A$ and is a member of $B$, $x \in A + B$. + Since $x$ is a member of $A + B$ but not $C$, $x \in (A + B) + C$. + Now suppose (b) was true. + That is, $x \not\in B$ and $x \in C$. + Since $x$ is not a member of $A$ nor a member of $B$, $x \not\in A + B$. + Since $x$ is not a member of $A + B$ but is a member of $C$, + $x \in (A + B) + C$. - Suppose $x \in B + C$ and $x \not\in A$. - Then (a) $x \in B$ or (b) $x \in C$ but not both. - Suppose (a) was true. - That is, $x \in B$ and $x \not\in C$. - Since $x$ is not a member of $A$ and is a member of $B$, $x \in A + B$. - Since $x$ is a member of $A + B$ but not $C$, $x \in (A + B) + C$. - Now suppose (b) was true. - That is, $x \not\in B$ and $x \in C$. - Since $x$ is not a member of $A$ nor a member of $B$, $x \not\in A + B$. - Since $x$ is not a member of $A + B$ but is a member of $C$, - $x \in (A + B) + C$. + \paragraph{(ii)}% + \hyperlabel{par:exercise-2.15b-ii} - \paragraph{(ii)}% - \hyperlabel{par:exercise-2.15b-ii} + Let $x \in (A + B) + C$. + Then $x$ is in $A + B$ or in $C$, but not both. + There are two cases to consider: - Let $x \in (A + B) + C$. - Then $x$ is in $A + B$ or in $C$, but not both. - There are two cases to consider: + \subparagraph{Case 1}% - \subparagraph{Case 1}% + Suppose $x \in A + B$ and $x \not\in C$. + Then (a) $x \in A$ or (b) $x \in B$ but not both. + Suppose (a) was true. + That is, $x \in A$ and $x \not\in B$. + Since $x$ is not a member of $B$ nor $C$, $x \not\in B + C$. + Since $x$ is not a member of $B + C$ but is a member of $A$, + $x \in A + (B + C)$. + Now Suppose (b) was true. + That is, $x \not\in A$ and $x \in B$. + Since $x$ is a member of $B$ and not of $C$, then $x \in B + C$. + Since $x$ is a member of $B + C$ and not of $A$, $x \in A + (B + C)$. - Suppose $x \in A + B$ and $x \not\in C$. - Then (a) $x \in A$ or (b) $x \in B$ but not both. - Suppose (a) was true. - That is, $x \in A$ and $x \not\in B$. - Since $x$ is not a member of $B$ nor $C$, $x \not\in B + C$. - Since $x$ is not a member of $B + C$ but is a member of $A$, - $x \in A + (B + C)$. - Now Suppose (b) was true. - That is, $x \not\in A$ and $x \in B$. - Since $x$ is a member of $B$ and not of $C$, then $x \in B + C$. - Since $x$ is a member of $B + C$ and not of $A$, $x \in A + (B + C)$. + \subparagraph{Case 2}% - \subparagraph{Case 2}% + Suppose $x \not\in A + B$ and $x \in C$. + Then, by \nameref{sub:nonmembership-symmetric-difference}, + (a) $x \in A \cap B$ or (b) $x \not\in A \cup B$. + Suppose (a) was true. + That is, $x \in A \land x \in B$. + Since $x$ is a member of $B$ and $C$, $x \not\in B + C$. + Since $x$ is not a member of $B + C$ but is a member of $A$, + $x \in A + (B + C)$. + Now suppose (b) was true. + That is, $x \not\in A$ and $x \not\in B$. + Since $x$ is not a member of $B$ but is a member of $C$, $x \in B + C$. + Since $x$ is a member of $B + C$ but not of $A$, $x \in A + (B + C)$. - Suppose $x \not\in A + B$ and $x \in C$. - Then, by \nameref{sub:nonmembership-symmetric-difference}, - (a) $x \in A \cap B$ or (b) $x \not\in A \cup B$. - Suppose (a) was true. - That is, $x \in A \land x \in B$. - Since $x$ is a member of $B$ and $C$, $x \not\in B + C$. - Since $x$ is not a member of $B + C$ but is a member of $A$, - $x \in A + (B + C)$. - Now suppose (b) was true. - That is, $x \not\in A$ and $x \not\in B$. - Since $x$ is not a member of $B$ but is a member of $C$, $x \in B + C$. - Since $x$ is a member of $B + C$ but not of $A$, $x \in A + (B + C)$. + \paragraph{Conclusion}% - \paragraph{Conclusion}% + In both \nameref{par:exercise-2.15b-i} and + \nameref{par:exercise-2.15b-ii}, the subcases are exhaustive and prove + the desired subset relation. + Therefore $A + (B + C) = (A + B) + C$. - In both \nameref{par:exercise-2.15b-i} and \nameref{par:exercise-2.15b-ii}, - the subcases are exhaustive and prove the desired subset relation. - Therefore $A + (B + C) = (A + B) + C$. - -\end{proof} + \end{proof} \subsection{\verified{Exercise 2.16}}% \hyperlabel{sub:exercise-2.16} -Simplify: - $$[(A \cup B \cup C) \cap (A \cup B)] - [(A \cup (B - C)) \cap A].$$ + Simplify: $$[(A \cup B \cup C) \cap (A \cup B)] - [(A \cup (B - C)) \cap A].$$ -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_16} - Let $A$, $B$, and $C$ be arbitrary sets. - Then - \begin{align*} - [(A \cup B \cup C) \cap (A \cup B)] & - [(A \cup (B - C)) \cap A] \\ - & = [A \cup B] - [A] \\ - & = \{ x \mid x \in (A \cup B) \land x \not\in A \} \\ - & = \{ x \mid x \in \{ y \mid y \in A \lor y \in B \} \land x \not\in A \} \\ - & = \{ x \mid (x \in A \lor x \in B) \land x \not\in A \} \\\ - & = \{ x \mid (x \in A \land x \not\in A) \lor (x \in B \land x \not\in A) \} \\ - & = \{ x \mid F \lor (X \in B \land x \not\in A) \} \\ - & = \{ x \mid x \in B \land x \not\in A \} \\ - & = B - A. - \end{align*} - -\end{proof} + \begin{proof} + Let $A$, $B$, and $C$ be arbitrary sets. + Then + \begin{align*} + [(A \cup B \cup C) \cap (A \cup B)] & - [(A \cup (B - C)) \cap A] \\ + & = [A \cup B] - [A] \\ + & = \{ x \mid x \in (A \cup B) \land x \not\in A \} \\ + & = \{ x \mid x \in \{ y \mid y \in A \lor y \in B \} \land x \not\in A \} \\ + & = \{ x \mid (x \in A \lor x \in B) \land x \not\in A \} \\\ + & = \{ x \mid (x \in A \land x \not\in A) \lor (x \in B \land x \not\in A) \} \\ + & = \{ x \mid F \lor (X \in B \land x \not\in A) \} \\ + & = \{ x \mid x \in B \land x \not\in A \} \\ + & = B - A. + \end{align*} + \end{proof} \subsection{\verified{Exercise 2.17}}% \hyperlabel{sub:exercise-2.17} -Show that the following four conditions are equivalent. + Show that the following four conditions are equivalent. + \begin{enumerate}[(a)] + \item $A \subseteq B$, + \item $A - B = \emptyset$, + \item $A \cup B = B$, + \item $A \cap B = A$. + \end{enumerate} -\begin{enumerate}[(a)] - \item $A \subseteq B$, - \item $A - B = \emptyset$, - \item $A \cup B = B$, - \item $A \cap B = A$. -\end{enumerate} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_2} + \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_17\_i} - \code*{Bookshelf/Enderton/Set/Chapter\_2} + \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_17\_ii} - \code*{Bookshelf/Enderton/Set/Chapter\_2} + \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_17\_iii} \code{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_17\_iv} - Let $A$ and $B$ be arbitrary sets. - We show that (i) $(a) \Rightarrow (b)$, (ii) $(b) \Rightarrow (c)$, (iii) - $(c) \Rightarrow (d)$, and (iv) $(d) \Rightarrow (a)$. + \begin{proof} + Let $A$ and $B$ be arbitrary sets. + We show that (i) $(a) \Rightarrow (b)$, (ii) $(b) \Rightarrow (c)$, (iii) + $(c) \Rightarrow (d)$, and (iv) $(d) \Rightarrow (a)$. - \paragraph{(i)}% + \paragraph{(i)}% - Suppose $A \subseteq B$. - That is, $\forall t, t \in A \Rightarrow t \in B$. - Then there is no element such that $t \in A$ and $t \not\in B$. - By definition of the relative complement, this immediately implies - $A - B = \emptyset$. + Suppose $A \subseteq B$. + That is, $\forall t, t \in A \Rightarrow t \in B$. + Then there is no element such that $t \in A$ and $t \not\in B$. + By definition of the relative complement, this immediately implies + $A - B = \emptyset$. - \paragraph{(ii)}% + \paragraph{(ii)}% - Suppose $A - B = \emptyset$. - By definition of the relative complement, - $$A - B = \emptyset = \{ x \mid x \in A \land x \not\in B \}.$$ - Then, for all $t$, - $\neg(t \in A \land t \not\in B) = t \not\in A \lor t \in B$. - This implies, by definition of the subset, that $A \subseteq B$. - It then immediately follows that $A \cup B = B$. + Suppose $A - B = \emptyset$. + By definition of the relative complement, + $$A - B = \emptyset = \{ x \mid x \in A \land x \not\in B \}.$$ + Then, for all $t$, + $\neg(t \in A \land t \not\in B) = t \not\in A \lor t \in B$. + This implies, by definition of the subset, that $A \subseteq B$. + It then immediately follows that $A \cup B = B$. - \paragraph{(iii)}% + \paragraph{(iii)}% - Suppose $A \cup B = B$. - Then there is no member of $A$ that is not a member of $B$. - In other words, $A \subseteq B$. - This immediately implies $A \cap B = A$. + Suppose $A \cup B = B$. + Then there is no member of $A$ that is not a member of $B$. + In other words, $A \subseteq B$. + This immediately implies $A \cap B = A$. - \paragraph{(iv)}% + \paragraph{(iv)}% - Suppose $A \cap B = A$. - Then every member of $A$ is a member of $B$. - This immediately implies $A \subseteq B$. + Suppose $A \cap B = A$. + Then every member of $A$ is a member of $B$. + This immediately implies $A \subseteq B$. -\end{proof} + \end{proof} \subsection{\unverified{Exercise 2.18}}% \hyperlabel{sub:exercise-2.18} -Assume that $A$ and $B$ are subsets of $S$. -List all of the different sets that can be made from these three by use of the - binary operations $\cup$, $\cap$, and $-$. + Assume that $A$ and $B$ are subsets of $S$. + List all of the different sets that can be made from these three by use of the + binary operations $\cup$, $\cap$, and $-$. -\begin{proof} + \begin{proof} + We can reason about this diagrammatically: - We can reason about this diagrammatically: + \begin{figure}[ht] + \includegraphics[width=0.6\textwidth]{venn-diagram} + \centering + \end{figure} - \begin{figure}[ht] - \includegraphics[width=0.6\textwidth]{venn-diagram} - \centering - \end{figure} + In the above diagram, we assume the left circle corresponds to set $A$ and the + right circle corresponds to $B$. + The the possible sets we can make via the specified operators are: - In the above diagram, we assume the left circle corresponds to set $A$ and the - right circle corresponds to $B$. - The the possible sets we can make via the specified operators are: - - \begin{itemize} - \item $A - B$, the left circle excluding the overlapping region. - \item $A \cap B$, the overlapping region. - \item $B - A$, the right circle excluding the overlapping region. - \item $(A \cup B) \cap A$, the left circle. - \item $(A \cup B) \cap B$, the right circle. - \item $(A - B) \cup (B - A)$, the symmetric difference. - \item $A \cup B$, the entire diagram. - \end{itemize} - -\end{proof} + \begin{itemize} + \item $A - B$, the left circle excluding the overlapping region. + \item $A \cap B$, the overlapping region. + \item $B - A$, the right circle excluding the overlapping region. + \item $(A \cup B) \cap A$, the left circle. + \item $(A \cup B) \cap B$, the right circle. + \item $(A - B) \cup (B - A)$, the symmetric difference. + \item $A \cup B$, the entire diagram. + \end{itemize} + \end{proof} \subsection{\verified{Exercise 2.19}}% \hyperlabel{sub:exercise-2.19} -Is $\powerset{(A - B)}$ always equal to $\powerset{A} - \powerset{B}$? -Is it ever equal to $\powerset{A} - \powerset{B}$? + Is $\powerset{(A - B)}$ always equal to $\powerset{A} - \powerset{B}$? + Is it ever equal to $\powerset{A} - \powerset{B}$? -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_19} - Let $A$ and $B$ be arbitrary sets. - We show (i) that $\emptyset \in \powerset{(A - B})$ and (ii) - $\emptyset \not\in \powerset{A} - \powerset{B}$. - - \paragraph{(i)}% - \hyperlabel{par:exercise-2.19-i} - - By definition of the \nameref{ref:power-set}, - $$\powerset{(A - B)} = \{ x \mid x \subseteq A - B \}.$$ - But $\emptyset$ is a subset of \textit{every} set. - Thus $\emptyset \in \powerset{(A - B)}$. - - \paragraph{(ii)}% - - By the same reasoning found in \nameref{par:exercise-2.19-i}, - $\emptyset \in \powerset{A}$ and $\emptyset \in \powerset{B}$. - But then, by definition of the relative complement, + \begin{proof} + Let $A$ and $B$ be arbitrary sets. + We show (i) that $\emptyset \in \powerset{(A - B})$ and (ii) $\emptyset \not\in \powerset{A} - \powerset{B}$. - \paragraph{Conclusion}% + \paragraph{(i)}% + \hyperlabel{par:exercise-2.19-i} - By the \nameref{ref:extensionality-axiom}, the two sets are never equal. + By definition of the \nameref{ref:power-set}, + $$\powerset{(A - B)} = \{ x \mid x \subseteq A - B \}.$$ + But $\emptyset$ is a subset of \textit{every} set. + Thus $\emptyset \in \powerset{(A - B)}$. -\end{proof} + \paragraph{(ii)}% + + By the same reasoning found in \nameref{par:exercise-2.19-i}, + $\emptyset \in \powerset{A}$ and $\emptyset \in \powerset{B}$. + But then, by definition of the relative complement, + $\emptyset \not\in \powerset{A} - \powerset{B}$. + + \paragraph{Conclusion}% + + By the \nameref{ref:extensionality-axiom}, the two sets are never equal. + + \end{proof} \subsection{\verified{Exercise 2.20}}% \hyperlabel{sub:exercise-2.20} -Let $A$, $B$, and $C$ be sets such that $A \cup B = A \cup C$ and - $A \cap B = A \cap C$. -Show that $B = C$. + Let $A$, $B$, and $C$ be sets such that $A \cup B = A \cup C$ and + $A \cap B = A \cap C$. + Show that $B = C$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_20} - Let $A$, $B$, and $C$ be arbitrary sets. - By the \nameref{ref:extensionality-axiom}, $B = C$ if and only if for all sets - $x$, $x \in B \iff x \in C$. - We prove both directions of this biconditional. + \begin{proof} + Let $A$, $B$, and $C$ be arbitrary sets. + By the \nameref{ref:extensionality-axiom}, $B = C$ if and only if for all + sets $x$, $x \in B \iff x \in C$. + We prove both directions of this biconditional. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $x \in B$. - Then there are two cases to consider: + Suppose $x \in B$. + Then there are two cases to consider: - \subparagraph{Case 1}% + \subparagraph{Case 1}% - Assume $x \in A$. - Then $x \in A \cap B$. - By hypothesis, $A \cap B = A \cap C$. - Thus $x \in A \cap C$ immediately implying $x \in C$. + Assume $x \in A$. + Then $x \in A \cap B$. + By hypothesis, $A \cap B = A \cap C$. + Thus $x \in A \cap C$ immediately implying $x \in C$. - \subparagraph{Case 2}% + \subparagraph{Case 2}% - Assume $x \not\in A$. - Then $x \in A \cup B$. - By hypothesis, $A \cup B = A \cup C$. - Thus $x \in A \cup C$. - Since $x \not\in A$, it follows $x \in C$. + Assume $x \not\in A$. + Then $x \in A \cup B$. + By hypothesis, $A \cup B = A \cup C$. + Thus $x \in A \cup C$. + Since $x \not\in A$, it follows $x \in C$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $x \in C$. - Then there are two cases to consider: + Suppose $x \in C$. + Then there are two cases to consider: - \subparagraph{Case 1}% + \subparagraph{Case 1}% - Assume $x \in A$. - Then $x \in A \cap C$. - By hypothesis, $A \cap B = A \cap C$. - Thus $x \in A \cap B$, immediately implying $x \in B$. + Assume $x \in A$. + Then $x \in A \cap C$. + By hypothesis, $A \cap B = A \cap C$. + Thus $x \in A \cap B$, immediately implying $x \in B$. - \subparagraph{Case 2}% + \subparagraph{Case 2}% - Assume $x \not\in A$. - Then $x \in A \cup C$. - By hypothesis, $A \cup B = A \cup C$. - Thus $x \in A \cup B$. - Since $x \not\in A$, it follows $x \in B$. + Assume $x \not\in A$. + Then $x \in A \cup C$. + By hypothesis, $A \cup B = A \cup C$. + Thus $x \in A \cup B$. + Since $x \not\in A$, it follows $x \in B$. -\end{proof} + \end{proof} \subsection{\verified{Exercise 2.21}}% \hyperlabel{sub:exercise-2.21} -Show that $\bigcup (A \cup B) = \bigcup A \cup \bigcup B$. + Show that $\bigcup\; (A \cup B) = \bigcup A \cup \bigcup B$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_21} - Let $A$ and $B$ be arbitrary sets. - By the \nameref{ref:extensionality-axiom}, the specified equality holds if and - only if for all sets $x$, - $$x \in \bigcup (A \cup B) \iff x \in \bigcup A \cup \bigcup B.$$ - We prove both directions of this biconditional. + \begin{proof} + Let $A$ and $B$ be arbitrary sets. + By the \nameref{ref:extensionality-axiom}, the specified equality holds if + and only if for all sets $x$, + $$x \in \bigcup (A \cup B) \iff x \in \bigcup A \cup \bigcup B.$$ + We prove both directions of this biconditional. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $x \in \bigcup (A \cup B)$. - By definition of the union of sets, there exists some $b \in A \cup B$ such - that $x \in b$. - If $b \in A$, then $x \in \bigcup A$ and $x \in \bigcup A \cup \bigcup B$. - Alternatively, if $b \in B$, then $x \in \bigcup B$ and - $x \in \bigcup A \cup \bigcup B$. - Regardless, $x$ is in the target set. + Suppose $x \in \bigcup (A \cup B)$. + By definition of the union of sets, there exists some $b \in A \cup B$ + such that $x \in b$. + If $b \in A$, then $x \in \bigcup A$ and $x \in \bigcup A \cup \bigcup B$. + Alternatively, if $b \in B$, then $x \in \bigcup B$ and + $x \in \bigcup A \cup \bigcup B$. + Regardless, $x$ is in the target set. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $x \in \bigcup A \cup \bigcup B$. - Then $x \in \bigcup A$ or $x \in \bigcup B$. - WLOG, suppose $x \in \bigcup A$. - By definition of the union of sets, there exists some $b \in A$ such that - $x \in b$. - But then $b \in A \cup B$ meaning $x$ is also a member of - $\bigcup (A \cup B)$. + Suppose $x \in \bigcup A \cup \bigcup B$. + Then $x \in \bigcup A$ or $x \in \bigcup B$. + WLOG, suppose $x \in \bigcup A$. + By definition of the union of sets, there exists some $b \in A$ such that + $x \in b$. + But then $b \in A \cup B$ meaning $x$ is also a member of + $\bigcup (A \cup B)$. -\end{proof} + \end{proof} \subsection{\verified{Exercise 2.22}}% \hyperlabel{sub:exercise-2.22} -Show that if $A$ and $B$ are nonempty sets, then - $\bigcap (A \cup B) = \bigcap A \cap \bigcap B$. + Show that if $A$ and $B$ are nonempty sets, then + $\bigcap (A \cup B) = \bigcap A \cap \bigcap B$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_22} - Let $A$ and $B$ be arbitrary, nonempty sets. - By the \nameref{ref:extensionality-axiom}, the specified equality holds if and - only if for all sets $x$, - \begin{equation} - \hyperlabel{sub:exercise-2.22-eq1} - x \in \bigcap (A \cup B) \iff x \in \bigcap A \cap \bigcap B. - \end{equation} - We prove both directions of this biconditional. + \begin{proof} + Let $A$ and $B$ be arbitrary, nonempty sets. + By the \nameref{ref:extensionality-axiom}, the specified equality holds if + and only if for all sets $x$, + \begin{equation} + \hyperlabel{sub:exercise-2.22-eq1} + x \in \bigcap (A \cup B) \iff x \in \bigcap A \cap \bigcap B. + \end{equation} + We prove both directions of this biconditional. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $x \in \bigcap (A \cup B)$. - Then for all $b \in A \cup B$, $x \in B$. - In other words, for every member $b_1$ of $A$ and every member $b_2$ of $B$, - $x$ is a member of both $b_1$ and $b_2$. - But that implies $x \in \bigcap A$ and $x \in \bigcap B$. + Suppose $x \in \bigcap (A \cup B)$. + Then for all $b \in A \cup B$, $x \in B$. + In other words, for every member $b_1$ of $A$ and every member $b_2$ of + $B$, $x$ is a member of both $b_1$ and $b_2$. + But that implies $x \in \bigcap A$ and $x \in \bigcap B$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $x \in \bigcap A \cap \bigcap B$. - That is, $x \in \bigcap A$ and $x \in \bigcap B$. - By definition of the intersection of sets, forall sets $b$, if $b \in A$, - then $x \in b$. - Likewise, if $b \in B$, then $x \in b$. - In other words, if $b$ is a member of either $A$ or $B$, $x \in b$. - That immediately implies $x \in \bigcap (A \cup B$. + Suppose $x \in \bigcap A \cap \bigcap B$. + That is, $x \in \bigcap A$ and $x \in \bigcap B$. + By definition of the intersection of sets, forall sets $b$, if $b \in A$, + then $x \in b$. + Likewise, if $b \in B$, then $x \in b$. + In other words, if $b$ is a member of either $A$ or $B$, $x \in b$. + That immediately implies $x \in \bigcap (A \cup B$. -\end{proof} + \end{proof} \subsection{\unverified{Exercise 2.23}}% \hyperlabel{sub:exercise-2.23} -Show that if $\mathscr{B}$ is nonempty, then - $A \cup \bigcap \mathscr{B} = \bigcap\; \{A \cup X \mid X \in \mathscr{B} \}$. + Show that if $\mathscr{B}$ is nonempty, then + $A \cup \bigcap \mathscr{B} = + \bigcap\; \{A \cup X \mid X \in \mathscr{B} \}$. -\begin{proof} - - Refer to \nameref{sub:general-distributive-laws}. - -\end{proof} + \begin{proof} + Refer to \nameref{sub:general-distributive-laws}. + \end{proof} \subsection{\verified{Exercise 2.24a}}% \hyperlabel{sub:exercise-2.24a} -Show that if $\mathscr{A}$ is nonempty, then - $\powerset{\bigcap\mathscr{A}} = - \bigcap\; \{\powerset{X} \mid X \in \mathscr{A} \}$. + Show that if $\mathscr{A}$ is nonempty, then + $\powerset{\bigcap\mathscr{A}} = + \bigcap\; \{\powerset{X} \mid X \in \mathscr{A} \}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_24a} - Suppose $\mathscr{A}$ is a nonempty set. - Then $\bigcap \mathscr{A}$ is well-defined. - Therefore - \begin{align*} - \powerset{\bigcap\mathscr{A}} - & = \{ x \mid x \subseteq \bigcap \mathscr{A} \} - & \textref{ref:power-set} \\ - & = \{ x \mid x \subseteq - \{ y \mid \forall X \in \mathscr{A}, y \in X \} \} - & \text{def'n intersection} \\ - & = \{ x \mid \forall t \in x, - t \in \{ y \mid \forall X \in \mathscr{A}, y \in X \} \} - & \text{def'n subset} \\ - & = \{ x \mid \forall t \in x, - (\forall X \in \mathscr{A}, t \in X) \} \\ - & = \{ x \mid \forall X \in \mathscr{A}, - (\forall t \in x, t \in X) \} \\ - & = \{ x \mid \forall X \in \mathscr{A}, x \subseteq X \} \\ - & = \{ x \mid \forall X \in \mathscr{A}, x \in \powerset{X} \} - & \textref{ref:power-set-axiom} \\ - & = \{ x \mid - \forall t \in \{ \powerset{X} \mid X \in \mathscr{A} \}, x \in t \} \\ - & = \bigcap\; \{\powerset{X} \mid X \in \mathscr{A}\}. - \end{align*} - -\end{proof} + \begin{proof} + Suppose $\mathscr{A}$ is a nonempty set. + Then $\bigcap \mathscr{A}$ is well-defined. + Therefore + \begin{align*} + \powerset{\bigcap\mathscr{A}} + & = \{ x \mid x \subseteq \bigcap \mathscr{A} \} + & \textref{ref:power-set} \\ + & = \{ x \mid x \subseteq + \{ y \mid \forall X \in \mathscr{A}, y \in X \} \} + & \text{def'n intersection} \\ + & = \{ x \mid \forall t \in x, + t \in \{ y \mid \forall X \in \mathscr{A}, y \in X \} \} + & \text{def'n subset} \\ + & = \{ x \mid \forall t \in x, + (\forall X \in \mathscr{A}, t \in X) \} \\ + & = \{ x \mid \forall X \in \mathscr{A}, + (\forall t \in x, t \in X) \} \\ + & = \{ x \mid \forall X \in \mathscr{A}, x \subseteq X \} \\ + & = \{ x \mid \forall X \in \mathscr{A}, x \in \powerset{X} \} + & \textref{ref:power-set-axiom} \\ + & = \{ x \mid + \forall t \in \{ \powerset{X} \mid X \in \mathscr{A} \}, x \in t \} \\ + & = \bigcap\; \{\powerset{X} \mid X \in \mathscr{A}\}. + \end{align*} + \end{proof} \subsection{\verified{Exercise 2.24b}}% \hyperlabel{sub:exercise-2.24b} -Show that - \begin{equation} - \hyperlabel{sub:exercise-2.24b-eq1} - \bigcup\; \{ \powerset{X} \mid X \in \mathscr{A} \} \subseteq - \powerset{\bigcup\mathscr{A}}. - \end{equation} -Under what conditions does equality hold? + Show that + \begin{equation} + \hyperlabel{sub:exercise-2.24b-eq1} + \bigcup\; \{ \powerset{X} \mid X \in \mathscr{A} \} \subseteq + \powerset{\bigcup\mathscr{A}}. + \end{equation} + Under what conditions does equality hold? -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_24b} - We first prove \eqref{sub:exercise-2.24b-eq1}. - Let $x \in \bigcup\; \{ \powerset{X} \mid X \in \mathscr{A} \}$. - By definition of the union of sets, - $(\exists X \in \mathscr{A}), x \in \powerset{X}$. - By definition of the \nameref{ref:power-set}, $x \subseteq X$. - By \nameref{sub:exercise-2.3}, $X \subseteq \bigcup \mathscr{A}$. - Therefore $x \subseteq \bigcup \mathscr{A}$, proving - $x \in \powerset{\mathscr{A}}$ as expected. + \begin{proof} + We first prove \eqref{sub:exercise-2.24b-eq1}. + Let $x \in \bigcup\; \{ \powerset{X} \mid X \in \mathscr{A} \}$. + By definition of the union of sets, + $(\exists X \in \mathscr{A}), x \in \powerset{X}$. + By definition of the \nameref{ref:power-set}, $x \subseteq X$. + By \nameref{sub:exercise-2.3}, $X \subseteq \bigcup \mathscr{A}$. + Therefore $x \subseteq \bigcup \mathscr{A}$, proving + $x \in \powerset{\mathscr{A}}$ as expected. - \suitdivider + \suitdivider - \noindent - We show $\powerset{\bigcup A} \subseteq - \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$ if and only if - $\bigcup\mathscr{A} \in \mathscr{A}$. + \noindent + We show $\powerset{\bigcup A} \subseteq + \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$ if and only if + $\bigcup\mathscr{A} \in \mathscr{A}$. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $\powerset{\bigcup\mathscr{A}} \subseteq - \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$. - By definition of the \nameref{ref:power-set}, - $\bigcup\mathscr{A} \in \powerset{\bigcup\mathscr{A}}$. - By hypothesis, $\bigcup\mathscr{A} \in - \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$. - By definition of the union of sets, there exists some $X \in \mathscr{A}$ - such that $\bigcup\mathscr{A} \in \powerset{X}$. - That is, $\bigcup\mathscr{A} \subseteq X$. - But $\bigcup\mathscr{A}$ cannot be a proper subset of $X$ since - $X \in \mathscr{A}$. - Thus $\bigcup\mathscr{A} = X$. - This proves $\bigcup\mathscr{A} \in - \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$. + Suppose $\powerset{\bigcup\mathscr{A}} \subseteq + \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$. + By definition of the \nameref{ref:power-set}, + $\bigcup\mathscr{A} \in \powerset{\bigcup\mathscr{A}}$. + By hypothesis, $\bigcup\mathscr{A} \in + \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$. + By definition of the union of sets, there exists some $X \in \mathscr{A}$ + such that $\bigcup\mathscr{A} \in \powerset{X}$. + That is, $\bigcup\mathscr{A} \subseteq X$. + But $\bigcup\mathscr{A}$ cannot be a proper subset of $X$ since + $X \in \mathscr{A}$. + Thus $\bigcup\mathscr{A} = X$. + This proves $\bigcup\mathscr{A} \in + \bigcup\;\{ \powerset{X} \mid X \in \mathscr{A} \}$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $\bigcup\mathscr{A} \in A$. - Let $x \in \powerset{\bigcup\mathscr{A}}$. - Since $\bigcup\mathscr{A} \in \mathscr{A}$, it immediately follows that - $x \in \{\powerset{X} \mid X \in \mathscr{A}\}$. + Suppose $\bigcup\mathscr{A} \in A$. + Let $x \in \powerset{\bigcup\mathscr{A}}$. + Since $\bigcup\mathscr{A} \in \mathscr{A}$, it immediately follows that + $x \in \{\powerset{X} \mid X \in \mathscr{A}\}$. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - Equality follows immediately from this fact in conjunction with the proof - of \eqref{sub:exercise-2.24b-eq1}. + Equality follows immediately from this fact in conjunction with the proof + of \eqref{sub:exercise-2.24b-eq1}. -\end{proof} + \end{proof} \subsection{\verified{Exercise 2.25}}% \hyperlabel{sub:exercise-2.25} -Is $A \cup \bigcup \mathscr{B}$ always the same as - $\bigcup\;\{ A \cup X \mid X \in \mathscr{B} \}$? -If not, then under what conditions does equality hold? + Is $A \cup \bigcup \mathscr{B}$ always the same as + $\bigcup\;\{ A \cup X \mid X \in \mathscr{B} \}$? + If not, then under what conditions does equality hold? -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_2} + \code*{Bookshelf/Enderton/Set/Chapter\_2} {Enderton.Set.Chapter\_2.exercise\_2\_25} - We prove that - \begin{equation} - \hyperlabel{sub:exercise-2.25-eq1} - A \cup \bigcup \mathscr{B} = - \bigcup\;\{ A \cup X \mid X \in \mathscr{B} \} - \end{equation} - if and only if $A = \emptyset$ or $\mathscr{B} \neq \emptyset$. - We prove both directions of this biconditional. - - \paragraph{($\Rightarrow$)}% - - Suppose \eqref{sub:exercise-2.25-eq1} holds true. - There are two cases to consider: - - \subparagraph{Case 1}% - - Suppose $B \neq \emptyset$. - Then $A = \emptyset \lor \mathscr{B} \neq \emptyset$ holds trivially. - - \subparagraph{Case 2}% - - Suppose $B = \emptyset$. - Then $$A \cup \bigcup \mathscr{B} = A \cup \bigcup \emptyset = A$$ and - $$ + \begin{proof} + We prove that + \begin{equation} + \hyperlabel{sub:exercise-2.25-eq1} + A \cup \bigcup \mathscr{B} = \bigcup\;\{ A \cup X \mid X \in \mathscr{B} \} - = \bigcup \emptyset \\ - = \emptyset. - $$ - Then by hypothesis \eqref{sub:exercise-2.25-eq1}, $A = \emptyset$. - Then $A = \emptyset \lor \mathscr{B} \neq \emptyset$ holds trivially. + \end{equation} + if and only if $A = \emptyset$ or $\mathscr{B} \neq \emptyset$. + We prove both directions of this biconditional. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $A = \emptyset$ or $\mathscr{B} \neq \emptyset$. - There are two cases to consider: + Suppose \eqref{sub:exercise-2.25-eq1} holds true. + There are two cases to consider: - \paragraph{Case 1}% + \subparagraph{Case 1}% - Suppose $A = \emptyset$. - Then $A \cup \bigcup \mathscr{B} = \bigcup{\mathscr{B}}$. - Likewise, - $$ - \bigcup \{ A \cup X \mid X \in \mathscr{B} \} - = \bigcup \{ X \mid X \in \mathscr{B} \} \\ - = \bigcup \mathscr{B}. - $$ - Therefore \eqref{sub:exercise-2.25-eq1} holds. + Suppose $B \neq \emptyset$. + Then $A = \emptyset \lor \mathscr{B} \neq \emptyset$ holds trivially. - \paragraph{Case 2}% + \subparagraph{Case 2}% - Suppose $B \neq \emptyset$. - Then - \begin{align*} - A \cup \bigcup\mathscr{B} - & = \{ x \mid x \in A \lor x \in \bigcup\mathscr{B} \} \\ - & = \{ x \mid x \in A \lor (\exists b \in \mathscr{B}) x \in b \} \\ - & = \{ x \mid (\exists b \in \mathscr{B}) x \in A \lor x \in b \} \\ - & = \{ x \mid (\exists b \in \mathscr{B}) x \in A \cup b \} \\ - & = \{ x \mid x \in \bigcup \{ A \cup X \mid X \in \mathscr{B} \} \\ - & = \bigcup \{ A \cup X \mid X \in \mathscr{B} \}. - \end{align*} - Therefore \eqref{sub:exercise-2.25-eq1} holds. + Suppose $B = \emptyset$. + Then $$A \cup \bigcup \mathscr{B} = A \cup \bigcup \emptyset = A$$ and + $$ + \bigcup\;\{ A \cup X \mid X \in \mathscr{B} \} + = \bigcup \emptyset \\ + = \emptyset. + $$ + Then by hypothesis \eqref{sub:exercise-2.25-eq1}, $A = \emptyset$. + Then $A = \emptyset \lor \mathscr{B} \neq \emptyset$ holds trivially. -\end{proof} + \paragraph{($\Leftarrow$)}% + + Suppose $A = \emptyset$ or $\mathscr{B} \neq \emptyset$. + There are two cases to consider: + + \paragraph{Case 1}% + + Suppose $A = \emptyset$. + Then $A \cup \bigcup \mathscr{B} = \bigcup{\mathscr{B}}$. + Likewise, + $$ + \bigcup \{ A \cup X \mid X \in \mathscr{B} \} + = \bigcup \{ X \mid X \in \mathscr{B} \} \\ + = \bigcup \mathscr{B}. + $$ + Therefore \eqref{sub:exercise-2.25-eq1} holds. + + \paragraph{Case 2}% + + Suppose $B \neq \emptyset$. + Then + \begin{align*} + A \cup \bigcup\mathscr{B} + & = \{ x \mid x \in A \lor x \in \bigcup\mathscr{B} \} \\ + & = \{ x \mid x \in A \lor (\exists b \in \mathscr{B}) x \in b \} \\ + & = \{ x \mid (\exists b \in \mathscr{B}) x \in A \lor x \in b \} \\ + & = \{ x \mid (\exists b \in \mathscr{B}) x \in A \cup b \} \\ + & = \{ x \mid x \in \bigcup \{ A \cup X \mid X \in \mathscr{B} \} \\ + & = \bigcup \{ A \cup X \mid X \in \mathscr{B} \}. + \end{align*} + Therefore \eqref{sub:exercise-2.25-eq1} holds. + + \end{proof} \chapter{Relations and Functions}% \hyperlabel{chap:relations-functions} @@ -2823,137 +2536,125 @@ If not, then under what conditions does equality hold? \subsection{\verified{Theorem 3A}}% \hyperlabel{sub:theorem-3a} -\begin{theorem}[3A] - - For any sets $x$, $y$, $u$, and $v$, - \begin{equation} - \hyperlabel{sub:theorem-3a-eq1} - \pair{u, v} = \pair{x, y} \iff u = x \land v = y. - \end{equation} - -\end{theorem} - -\begin{proof} + \begin{theorem}[3A] + For any sets $x$, $y$, $u$, and $v$, + \begin{equation} + \hyperlabel{sub:theorem-3a-eq1} + \pair{u, v} = \pair{x, y} \iff u = x \land v = y. + \end{equation} + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.OrderedPair.ext\_iff} - Let $x$, $y$, $u$, and $v$ be arbitrary sets. + \begin{proof} + Let $x$, $y$, $u$, and $v$ be arbitrary sets. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - This follows trivially. + This follows trivially. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $\pair{u, v} = \pair{x, y}$. - Then, by definition of an \nameref{ref:ordered-pair}, - \begin{equation} - \hyperlabel{sub:theorem-3a-eq2} - \{\{u\}, \{u, v\}\} = \{\{x\}, \{x, y\}\}. - \end{equation} - By the \nameref{ref:extensionality-axiom}, it follows - $\{u\} \in \{\{x\}, \{x, y\}\}$ and - $\{u, v\} \in \{\{x\}, \{x, y\}\}$. - That is, - $$\{u\} = \{x\} \quad\text{or}\quad \{u\} = \{x, y\}$$ - and - $$\{u, v\} = \{x\} \quad\text{or}\quad \{u, v\} = \{x, y\}.$$ - There are 4 cases to consider: + Suppose $\pair{u, v} = \pair{x, y}$. + Then, by definition of an \nameref{ref:ordered-pair}, + \begin{equation} + \hyperlabel{sub:theorem-3a-eq2} + \{\{u\}, \{u, v\}\} = \{\{x\}, \{x, y\}\}. + \end{equation} + By the \nameref{ref:extensionality-axiom}, it follows + $\{u\} \in \{\{x\}, \{x, y\}\}$ and + $\{u, v\} \in \{\{x\}, \{x, y\}\}$. + That is, + $$\{u\} = \{x\} \quad\text{or}\quad \{u\} = \{x, y\}$$ + and + $$\{u, v\} = \{x\} \quad\text{or}\quad \{u, v\} = \{x, y\}.$$ + There are 4 cases to consider: - \paragraph{Case 1}% + \paragraph{Case 1}% - Suppose $\{u\} = \{x\}$ and $\{u, v\} = \{x\}$. - The former identity implies $u = x$. - The latter identity implies $u = v = x$. - Then \eqref{sub:theorem-3a-eq2} simplifies to - $$\{\{u\}\} = \{\{x\}, \{x, y\}\},$$ meaning $x = y$. - Thus $v = y$ as well. + Suppose $\{u\} = \{x\}$ and $\{u, v\} = \{x\}$. + The former identity implies $u = x$. + The latter identity implies $u = v = x$. + Then \eqref{sub:theorem-3a-eq2} simplifies to + $$\{\{u\}\} = \{\{x\}, \{x, y\}\},$$ meaning $x = y$. + Thus $v = y$ as well. - \paragraph{Case 2}% + \paragraph{Case 2}% - Suppose $\{u\} = \{x\}$ and $\{u, v\} = \{x, y\}$. - The former identity implies $u = x$. - Substituting into the latter identity yields $\{u, v\} = \{u, y\}$. - This holds if and only if $v = y$. + Suppose $\{u\} = \{x\}$ and $\{u, v\} = \{x, y\}$. + The former identity implies $u = x$. + Substituting into the latter identity yields $\{u, v\} = \{u, y\}$. + This holds if and only if $v = y$. - \paragraph{Case 3}% + \paragraph{Case 3}% - Suppose $\{u\} = \{x, y\}$ and $\{u, v\} = \{x\}$. - The former identity implies $x = y = u$. - Substituting into the latter yields $\{u, v\} = \{u\}$. - Thus $u = v$ which in turn implies $v = y$. + Suppose $\{u\} = \{x, y\}$ and $\{u, v\} = \{x\}$. + The former identity implies $x = y = u$. + Substituting into the latter yields $\{u, v\} = \{u\}$. + Thus $u = v$ which in turn implies $v = y$. - \paragraph{Case 4}% - Suppose $\{u\} = \{x, y\}$ and $\{u, v\} = \{x, y\}$. - The former identity implies $x = y = u$. - Substituting into the latter yields $\{u, v\} = \{u\}$. - This implies $v = u$ which in turn implies $v = y$. + \paragraph{Case 4}% + Suppose $\{u\} = \{x, y\}$ and $\{u, v\} = \{x, y\}$. + The former identity implies $x = y = u$. + Substituting into the latter yields $\{u, v\} = \{u\}$. + This implies $v = u$ which in turn implies $v = y$. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - These cases are exhaustive and each implies that $u = x$ and $v = y$. + These cases are exhaustive and each implies that $u = x$ and $v = y$. -\end{proof} + \end{proof} \subsection{\verified{Lemma 3B}}% \hyperlabel{sub:lemma-3b} -\begin{lemma}[3B] - - If $x \in C$ and $y \in C$, then $\pair{x, y} \in \powerset{\powerset{C}}$. - -\end{lemma} - -\begin{proof} + \begin{lemma}[3B] + If $x \in C$ and $y \in C$, then $\pair{x, y} \in \powerset{\powerset{C}}$. + \end{lemma} \code{Bookshelf/Enderton/Set/Chapter\_3} - {Enderton.Set.Chapter\_3.theorem\_3b} + {Enderton.Set.Chapter\_3.lemma\_3b} - Let $C$ be an arbitrary set and $x, y \in C$. - Then, by definition of the \nameref{ref:power-set}, - $\{x\}$ and $\{x, y\}$ are members of $\powerset{C}$. - Likewise, $\{\{x\}, \{x, y\}\}$ is a member of $\powerset{\powerset{C}}$. - By definition of an \nameref{ref:ordered-pair}, - $\pair{x, y} = \{\{x\}, \{x, y\}\}$. - This concludes our proof. - -\end{proof} + \begin{proof} + Let $C$ be an arbitrary set and $x, y \in C$. + Then, by definition of the \nameref{ref:power-set}, + $\{x\}$ and $\{x, y\}$ are members of $\powerset{C}$. + Likewise, $\{\{x\}, \{x, y\}\}$ is a member of $\powerset{\powerset{C}}$. + By definition of an \nameref{ref:ordered-pair}, + $\pair{x, y} = \{\{x\}, \{x, y\}\}$. + This concludes our proof. + \end{proof} \subsection{\pending{Corollary 3C}}% \hyperlabel{sub:corollary-3c} -\begin{theorem}[3C] + \begin{theorem}[3C] + For any sets $A$ and $B$, there is a set whose members are exactly the + pairs $\pair{x, y}$ with $x \in A$ and $y \in B$. + \end{theorem} - For any sets $A$ and $B$, there is a set whose members are exactly the - pairs $\pair{x, y}$ with $x \in A$ and $y \in B$. + \lean{Mathlib/SetTheory/ZFC/Basic}{Set.prod} -\end{theorem} - -\begin{proof} - - \lean*{Mathlib/SetTheory/ZFC/Basic}{Set.prod} - - \begin{note} - The above Lean proof is a definition (i.e. an axiom). - It does not prove such a set's existence from first principles. - \end{note} - - Define $C = A \cup B$. - Then for all $x \in A$ and for all $y \in B$, $x$ and $y$ are both in $C$. - By \nameref{sub:lemma-3b}, it follows that - $\pair{x, y} \in \powerset{\powerset{C}}$. - The \nameref{ref:power-set-axiom} indicates $\powerset{\powerset{C}}$ is - indeed a set. - Therefore the \nameref{ref:subset-axioms} are applicable. - This implies the existence of a set $D$ such that - $$\forall z, (z \in D \iff z \in \powerset{\powerset{C}} \land - (\exists x, \exists y, x \in A \land y \in B \land - z = \pair{x, y})).$$ - By construction $D$ is the set whose members are exactly the pairs - $\pair{x, y}$ with $x \in A$ and $y \in B$. - -\end{proof} + \begin{proof} + \begin{note} + The above Lean proof is a definition (i.e. an axiom). + It does not prove such a set's existence from first principles. + \end{note} + Define $C = A \cup B$. + Then for all $x \in A$ and for all $y \in B$, $x$ and $y$ are both in $C$. + By \nameref{sub:lemma-3b}, it follows that + $\pair{x, y} \in \powerset{\powerset{C}}$. + The \nameref{ref:power-set-axiom} indicates $\powerset{\powerset{C}}$ is + indeed a set. + Therefore the \nameref{ref:subset-axioms} are applicable. + This implies the existence of a set $D$ such that + $$\forall z, (z \in D \iff z \in \powerset{\powerset{C}} \land + (\exists x, \exists y, x \in A \land y \in B \land + z = \pair{x, y})).$$ + By construction $D$ is the set whose members are exactly the pairs + $\pair{x, y}$ with $x \in A$ and $y \in B$. + \end{proof} \section{Relations}% \hyperlabel{sec:relations} @@ -2961,27 +2662,23 @@ If not, then under what conditions does equality hold? \subsection{\verified{Theorem 3D}}% \hyperlabel{sub:theorem-3d} -\begin{theorem}[3D] - - If $\pair{x, y} \in A$, then $x$ and $y$ belong to $\bigcup\bigcup A$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[3D] + If $\pair{x, y} \in A$, then $x$ and $y$ belong to $\bigcup\bigcup A$. + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3d} - Let $A$ be a set and $\pair{x, y} \in A$. - By definition of an \nameref{ref:ordered-pair}, - $$\pair{x, y} = \{\{x\}, \{x, y\}\}.$$ - By \nameref{sub:exercise-2.3}, $\{\{x\}, \{x, y\}\} \subseteq \bigcup A$. - Then $\{x, y\} \in \bigcup A$. - Another application of \nameref{sub:exercise-2.3} implies - $\{x, y\} \subseteq \bigcup\bigcup A$. - Therefore $x, y \in \bigcup\bigcup A$. - -\end{proof} + \begin{proof} + Let $A$ be a set and $\pair{x, y} \in A$. + By definition of an \nameref{ref:ordered-pair}, + $$\pair{x, y} = \{\{x\}, \{x, y\}\}.$$ + By \nameref{sub:exercise-2.3}, $\{\{x\}, \{x, y\}\} \subseteq \bigcup A$. + Then $\{x, y\} \in \bigcup A$. + Another application of \nameref{sub:exercise-2.3} implies + $\{x, y\} \subseteq \bigcup\bigcup A$. + Therefore $x, y \in \bigcup\bigcup A$. + \end{proof} \section{Functions}% \hyperlabel{sec:functions} @@ -2989,651 +2686,598 @@ If not, then under what conditions does equality hold? \subsection{\verified{Theorem 3E}}% \hyperlabel{sub:theorem-3e} -\begin{theorem}[3E] + \begin{theorem}[3E] + For a set $F$, $\dom{(F^{-1})} = \ran{F}$ and $\ran{(F^{-1})} = \dom{F}$. + For a relation $F$, $(F^{-1})^{-1} = F$. + \end{theorem} - For a set $F$, $\dom{(F^{-1})} = \ran{F}$ and $\ran{(F^{-1})} = \dom{F}$. - For a relation $F$, $(F^{-1})^{-1} = F$. - -\end{theorem} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Relation} + \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.dom\_inv\_eq\_ran\_self} - \code*{Bookshelf/Enderton/Set/Relation} + \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.ran\_inv\_eq\_dom\_self} \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.inv\_inv\_eq\_self} - We prove that (i) $\dom{(F^{-1})} = \ran{F}$, (ii) $\ran{(F^{-1})} = \dom{F}$, - and (iii) $(F^{-1})^{-1} = F$. + \begin{proof} + We prove that (i) $\dom{(F^{-1})} = \ran{F}$, (ii) + $\ran{(F^{-1})} = \dom{F}$, and (iii) $(F^{-1})^{-1} = F$. - \paragraph{(i)}% + \paragraph{(i)}% - By definition of the \nameref{ref:domain}, $x \in \dom{(F^{-1})}$ if and - only if there exists some $y$ such that $\pair{x, y} \in F^{-1}$. - By definition of the \nameref{ref:inverse} of a set, - $\pair{y, x} \in F$. - By definition of the \nameref{ref:range}, $x \in \ran{F}$. - Since each step holds biconditionally, it follows - $\dom{(F^{-1})} = \ran{F}$ as expected. + By definition of the \nameref{ref:domain}, $x \in \dom{(F^{-1})}$ if and + only if there exists some $y$ such that $\pair{x, y} \in F^{-1}$. + By definition of the \nameref{ref:inverse} of a set, + $\pair{y, x} \in F$. + By definition of the \nameref{ref:range}, $x \in \ran{F}$. + Since each step holds biconditionally, it follows + $\dom{(F^{-1})} = \ran{F}$ as expected. - \paragraph{(ii)}% + \paragraph{(ii)}% - By definition of the \nameref{ref:range}, $x \in \ran{(F^{-1})}$ if and - only if there exists some $t$ such that $\pair{t, x} \in F^{-1}$. - By definition of the \nameref{ref:inverse} of a set, - $\pair{x, t} \in F$. - By definition of the \nameref{ref:domain}, $x \in \dom{F}$. - Since each step holds biconditionally, it follows - $\ran{(F^{-1})} = \dom{F}$. + By definition of the \nameref{ref:range}, $x \in \ran{(F^{-1})}$ if and + only if there exists some $t$ such that $\pair{t, x} \in F^{-1}$. + By definition of the \nameref{ref:inverse} of a set, + $\pair{x, t} \in F$. + By definition of the \nameref{ref:domain}, $x \in \dom{F}$. + Since each step holds biconditionally, it follows + $\ran{(F^{-1})} = \dom{F}$. - \paragraph{(iii)}% + \paragraph{(iii)}% - By definition of the \nameref{ref:inverse} of a set, - \begin{align*} - (F^{-1})^{-1} - & = \{\pair{u, v} \mid \pair{v, u} \in F^{-1}\} \\ - & = \{\pair{u, v} \mid \pair{u, v} \in F\} \\ - & = F. - \end{align*} + By definition of the \nameref{ref:inverse} of a set, + \begin{align*} + (F^{-1})^{-1} + & = \{\pair{u, v} \mid \pair{v, u} \in F^{-1}\} \\ + & = \{\pair{u, v} \mid \pair{u, v} \in F\} \\ + & = F. + \end{align*} -\end{proof} + \end{proof} \subsection{\verified{Theorem 3F}}% \hyperlabel{sub:theorem-3f} -\begin{theorem}[3F] + \begin{theorem}[3F] + For a set $F$, $F^{-1}$ is a function iff $F$ is single-rooted. + A relation $F$ is a function iff $F^{-1}$ is single-rooted. + \end{theorem} - For a set $F$, $F^{-1}$ is a function iff $F$ is single-rooted. - A relation $F$ is a function iff $F^{-1}$ is single-rooted. - -\end{theorem} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Relation} + \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.single\_valued\_inv\_iff\_single\_rooted\_self} \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.single\_valued\_self\_iff\_single\_rooted\_inv} - We prove that (i) any set $F$, $F^{-1}$ is a function iff $F$ is - single-rooted and (ii) any relation $F$ is a function iff $F^{-1}$ is - single-rooted. + \begin{proof} + We prove that (i) any set $F$, $F^{-1}$ is a function iff $F$ is + single-rooted and (ii) any relation $F$ is a function iff $F^{-1}$ is + single-rooted. - \paragraph{(i)}% - \hyperlabel{par:theorem-3f-i} + \paragraph{(i)}% + \hyperlabel{par:theorem-3f-i} - Let $F$ be any set. + Let $F$ be any set. - \subparagraph{($\Rightarrow$)}% + \subparagraph{($\Rightarrow$)}% - Suppose $F^{-1}$ is a \nameref{ref:function}. - By definition, for each $x \in \dom{(F^{-1})}$, there is only one $y$ - such that $\pair{x, y} \in F^{-1}$. - By definition of the \nameref{ref:inverse} of $F$, - $F^{-1} = \{\pair{u, v} \mid vFu\}$. - Then for each $x \in \ran{F}$, there exists exactly one $y$ such that - $\pair{y, x} \in F$. - This definitionally means $F$ is single-rooted. + Suppose $F^{-1}$ is a \nameref{ref:function}. + By definition, for each $x \in \dom{(F^{-1})}$, there is only one $y$ + such that $\pair{x, y} \in F^{-1}$. + By definition of the \nameref{ref:inverse} of $F$, + $F^{-1} = \{\pair{u, v} \mid vFu\}$. + Then for each $x \in \ran{F}$, there exists exactly one $y$ such that + $\pair{y, x} \in F$. + This definitionally means $F$ is single-rooted. - \subparagraph{($\Leftarrow$)}% + \subparagraph{($\Leftarrow$)}% - Suppose $F$ is single-rooted. - By definition, for each $x \in \ran{F}$, there is only one $t$ such that - $\pair{t, x} \in F$. - By definition of the \nameref{ref:inverse} of $F$, - $F^{-1} = \{\pair{u, v} \mid vFu\}$. - Then for each $x \in \dom{(F^{-1})}$ there exists exactly one $t$ such - that $\pair{x, t} \in F^{-1}$. - This definitionally means $F^{-1}$ is a function. + Suppose $F$ is single-rooted. + By definition, for each $x \in \ran{F}$, there is only one $t$ such that + $\pair{t, x} \in F$. + By definition of the \nameref{ref:inverse} of $F$, + $F^{-1} = \{\pair{u, v} \mid vFu\}$. + Then for each $x \in \dom{(F^{-1})}$ there exists exactly one $t$ such + that $\pair{x, t} \in F^{-1}$. + This definitionally means $F^{-1}$ is a function. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $F$ be a \nameref{ref:relation}. + Let $F$ be a \nameref{ref:relation}. - \subparagraph{($\Rightarrow$)}% + \subparagraph{($\Rightarrow$)}% - Suppose $F$ is a function. - By \nameref{sub:theorem-3e}, $F = (F^{-1})^{-1}$. - Then by \nameref{par:theorem-3f-i}, $F^{-1}$ is single-rooted. + Suppose $F$ is a function. + By \nameref{sub:theorem-3e}, $F = (F^{-1})^{-1}$. + Then by \nameref{par:theorem-3f-i}, $F^{-1}$ is single-rooted. - \subparagraph{($\Leftarrow$)}% + \subparagraph{($\Leftarrow$)}% - Suppose $F^{-1}$ is single-rooted. - Then by \nameref{par:theorem-3f-i}, $(F^{-1})^{-1}$ is a function. - By \nameref{sub:theorem-3e}, $(F^{-1})^{-1} = F$. - Thus $F$ is a function. + Suppose $F^{-1}$ is single-rooted. + Then by \nameref{par:theorem-3f-i}, $(F^{-1})^{-1}$ is a function. + By \nameref{sub:theorem-3e}, $(F^{-1})^{-1} = F$. + Thus $F$ is a function. -\end{proof} + \end{proof} \subsection{\verified{Lemma 1}}% \hyperlabel{sub:lemma-1} \hyperlabel{sub:one-to-one-inverse} -\begin{lemma} - - For any one-to-one function $F$, $F^{-1}$ is also one-to-one. - -\end{lemma} - - -\begin{proof} + \begin{lemma} + For any one-to-one function $F$, $F^{-1}$ is also one-to-one. + \end{lemma} \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.one\_to\_one\_self\_iff\_one\_to\_one\_inv} - We prove that (i) $F^{-1}$ is a function and (ii) $F^{-1}$ is single-rooted. + \begin{proof} + We prove that (i) $F^{-1}$ is a function and (ii) $F^{-1}$ is single-rooted. - \paragraph{(i)}% - \hyperlabel{par:lemma-1-i} + \paragraph{(i)}% + \hyperlabel{par:lemma-1-i} - By hypothesis, $F$ is one-to-one. - This means it is single-rooted, i.e. for all $x \in \ran{F}$, there exists - exactly one $t$ such that $\pair{t, x} \in F$. - By definition of the \nameref{ref:inverse} of $F$, - $\pair{x, t} \in F^{-1}$. - But then for all $x \in \dom{(F^{-1})}$, there exists exactly one $t$ such - that $\pair{x, t} \in F^{-1}$. - Thus $F^{-1}$ is a function. + By hypothesis, $F$ is one-to-one. + This means it is single-rooted, i.e. for all $x \in \ran{F}$, there exists + exactly one $t$ such that $\pair{t, x} \in F$. + By definition of the \nameref{ref:inverse} of $F$, + $\pair{x, t} \in F^{-1}$. + But then for all $x \in \dom{(F^{-1})}$, there exists exactly one $t$ such + that $\pair{x, t} \in F^{-1}$. + Thus $F^{-1}$ is a function. - \paragraph{(ii)}% - \hyperlabel{par:lemma-1-ii} + \paragraph{(ii)}% + \hyperlabel{par:lemma-1-ii} - By hypothesis, $F$ is single-valued. - That is, for all $x \in \dom{F}$, there exists exactly one $y$ such that - $\pair{x, y} \in F$. - By definition of the \nameref{ref:inverse} of $F$, - $\pair{y, x} \in F^{-1}$. - But then for all $x \in \ran{(F^{-1})}$, there exists exactly one $y$ such - that $\pair{y, x} \in F^{-1}$. - Thus $F^{-1}$ is single-rooted. + By hypothesis, $F$ is single-valued. + That is, for all $x \in \dom{F}$, there exists exactly one $y$ such that + $\pair{x, y} \in F$. + By definition of the \nameref{ref:inverse} of $F$, + $\pair{y, x} \in F^{-1}$. + But then for all $x \in \ran{(F^{-1})}$, there exists exactly one $y$ such + that $\pair{y, x} \in F^{-1}$. + Thus $F^{-1}$ is single-rooted. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - By \nameref{par:lemma-1-i} and \nameref{par:lemma-1-ii}, $F^{-1}$ is - a one-to-one function. + By \nameref{par:lemma-1-i} and \nameref{par:lemma-1-ii}, $F^{-1}$ is + a one-to-one function. -\end{proof} + \end{proof} \subsection{\verified{Theorem 3G}}% \hyperlabel{sub:theorem-3g} -\begin{theorem}[3G] + \begin{theorem}[3G] + Assume that $F$ is a one-to-one function. + If $x \in \dom{F}$, then $F^{-1}(F(x)) = x$. + If $y \in \ran{F}$, then $F(F^{-1}(y)) = y$. + \end{theorem} - Assume that $F$ is a one-to-one function. - If $x \in \dom{F}$, then $F^{-1}(F(x)) = x$. - If $y \in \ran{F}$, then $F(F^{-1}(y)) = y$. - -\end{theorem} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3g\_i} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3g\_ii} - Suppose $F$ is a one-to-one \nameref{ref:function}. - Then \nameref{sub:one-to-one-inverse} indicates $F^{-1}$ is a one-to-one - function with domain $\ran{F}$ and range $\dom{F}$. - - For all $x \in \dom{F}$, $\pair{x, F(x)} \in F$. - Then $\pair{F(x), x} \in F^{-1}$. - Since $F^{-1}$ is single-valued, $F^{-1}(F(x)) = x$. - - For all $y \in \ran{F}$, $\pair{y, F^{-1}(y)} \in F^{-1}$. - Then $\pair{F^{-1}(y), y} \in F$. - Since $F$ is single-valued, $F(F^{-1}(y)) = y$. - -\end{proof} + \begin{proof} + Suppose $F$ is a one-to-one \nameref{ref:function}. + Then \nameref{sub:one-to-one-inverse} indicates $F^{-1}$ is a one-to-one + function with domain $\ran{F}$ and range $\dom{F}$. + For all $x \in \dom{F}$, $\pair{x, F(x)} \in F$. + Then $\pair{F(x), x} \in F^{-1}$. + Since $F^{-1}$ is single-valued, $F^{-1}(F(x)) = x$. + For all $y \in \ran{F}$, $\pair{y, F^{-1}(y)} \in F^{-1}$. + Then $\pair{F^{-1}(y), y} \in F$. + Since $F$ is single-valued, $F(F^{-1}(y)) = y$. + \end{proof} \subsection{\verified{Theorem 3H}}% \hyperlabel{sub:theorem-3h} -\begin{theorem}[3H] + \begin{theorem}[3H] + Assume that $F$ and $G$ are functions. + Then $F \circ G$ is a function, its domain is + \begin{equation} + \hyperlabel{sub:theorem-3h-eq1} + \{x \in \dom{G} \mid G(x) \in \dom{F}\}, + \end{equation} + and for $x$ in its domain, $(F \circ G)(x) = F(G(x))$. + \end{theorem} - Assume that $F$ and $G$ are functions. - Then $F \circ G$ is a function, its domain is - \begin{equation} - \hyperlabel{sub:theorem-3h-eq1} - \{x \in \dom{G} \mid G(x) \in \dom{F}\}, - \end{equation} - and for $x$ in its domain, $(F \circ G)(x) = F(G(x))$. - -\end{theorem} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Relation} + \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.single\_valued\_comp\_is\_single\_valued} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3h\_dom} - Let $F$ and $G$ be \nameref{ref:function}s. - By definition of the \nameref{ref:composition} of $F$ and $G$, - \begin{equation} - \hyperlabel{sub:theorem-3h-eq2} - F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}. - \end{equation} - By construction, $F \circ G$ is a relation. - By the definition of the \nameref{ref:domain} of a relation, - $x \in \dom{(F \circ G)}$ if and only if there exists some $y$ such that - $\pair{x, y} \in F \circ G$. - We prove that (i) $F \circ G$ is a function with domain satisfying - \eqref{sub:theorem-3h-eq1}, and (ii) $(F \circ G)(x) = F(G(x))$. + \begin{proof} + Let $F$ and $G$ be \nameref{ref:function}s. + By definition of the \nameref{ref:composition} of $F$ and $G$, + \begin{equation} + \hyperlabel{sub:theorem-3h-eq2} + F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}. + \end{equation} + By construction, $F \circ G$ is a relation. + By the definition of the \nameref{ref:domain} of a relation, + $x \in \dom{(F \circ G)}$ if and only if there exists some $y$ such that + $\pair{x, y} \in F \circ G$. + We prove that (i) $F \circ G$ is a function with domain satisfying + \eqref{sub:theorem-3h-eq1}, and (ii) $(F \circ G)(x) = F(G(x))$. - \paragraph{(i)}% - \hyperlabel{par:theorem-3h-i} + \paragraph{(i)}% + \hyperlabel{par:theorem-3h-i} - By \eqref{sub:theorem-3h-eq2}, there exists some $t$ such that - $\pair{x, t} \in G$ and $\pair{t, y} \in F$. - Since $G$ is single-valued, $t$ is uniquely determined by $x$. - Since $F$ is single-valued, $y$ is uniquely determined by $t$. - Therefore, by transitivity, $y$ is uniquely determined by $x$. - Thus $F \circ G$ is single-valued, i.e. $F \circ G$ is a function. + By \eqref{sub:theorem-3h-eq2}, there exists some $t$ such that + $\pair{x, t} \in G$ and $\pair{t, y} \in F$. + Since $G$ is single-valued, $t$ is uniquely determined by $x$. + Since $F$ is single-valued, $y$ is uniquely determined by $t$. + Therefore, by transitivity, $y$ is uniquely determined by $x$. + Thus $F \circ G$ is single-valued, i.e. $F \circ G$ is a function. - Furthermore, by definition of function application, $t = G(x)$. - Thus $$\pair{x, G(x)} \in G \quad\text{and}\quad \pair{G(x), y} \in F.$$ - This immediately implies \eqref{sub:theorem-3h-eq1} holds true. + Furthermore, by definition of function application, $t = G(x)$. + Thus $$\pair{x, G(x)} \in G \quad\text{and}\quad \pair{G(x), y} \in F.$$ + This immediately implies \eqref{sub:theorem-3h-eq1} holds true. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $x \in \dom{(F \circ G)}$. - By definition, $\pair{x, (F \circ G)(x)} \in F \circ G$. - Then \eqref{sub:theorem-3h-eq2} implies $(F \circ G)(x)$ satisfies - $\pair{G(x), (F \circ G)(x)} \in F$. - This is equivalent to saying $F(G(x)) = (F \circ G)(x)$ as expected. + Let $x \in \dom{(F \circ G)}$. + By definition, $\pair{x, (F \circ G)(x)} \in F \circ G$. + Then \eqref{sub:theorem-3h-eq2} implies $(F \circ G)(x)$ satisfies + $\pair{G(x), (F \circ G)(x)} \in F$. + This is equivalent to saying $F(G(x)) = (F \circ G)(x)$ as expected. -\end{proof} + \end{proof} \subsection{\verified{Theorem 3I}}% \hyperlabel{sub:theorem-3i} -\begin{theorem}[3I] - - For any sets $F$ and $G$, $$(F \circ G)^{-1} = G^{-1} \circ F^{-1}.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[3I] + For any sets $F$ and $G$, $$(F \circ G)^{-1} = G^{-1} \circ F^{-1}.$$ + \end{theorem} \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.comp\_inv\_eq\_inv\_comp\_inv} - By definition of the \nameref{ref:composition} of $F$ and $G$, - $$F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}.$$ - By definition of the \nameref{ref:inverse} of a function, - \begin{align*} - (F \circ G)^{-1} - & = \{\pair{u, v} \mid \exists t (vGt \land tFu)\} \\ - & = \{\pair{u, v} \mid \exists t (tFu \land vGt)\} \\ - & = \{\pair{u, v} \mid - \exists t \left[ u(F^{-1})t \land t(G^{-1})v \right]\} \\ - & = G^{-1} \circ F^{-1}. - \end{align*} - -\end{proof} + \begin{proof} + By definition of the \nameref{ref:composition} of $F$ and $G$, + $$F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}.$$ + By definition of the \nameref{ref:inverse} of a function, + \begin{align*} + (F \circ G)^{-1} + & = \{\pair{u, v} \mid \exists t (vGt \land tFu)\} \\ + & = \{\pair{u, v} \mid \exists t (tFu \land vGt)\} \\ + & = \{\pair{u, v} \mid + \exists t \left[ u(F^{-1})t \land t(G^{-1})v \right]\} \\ + & = G^{-1} \circ F^{-1}. + \end{align*} + \end{proof} \subsection{\pending{Theorem 3J}}% \hyperlabel{sub:theorem-3j} -\begin{theorem}[3J] + \begin{theorem}[3J] + Assume that $F \colon A \rightarrow B$, and that $A$ is nonempty. + \begin{enumerate}[(a)] + \item There exists a function $G \colon B \rightarrow A$ + (a "left inverse") such that $G \circ F$ is the identity function $I_A$ + on $A$ iff $F$ is one-to-one. + \item There exists a function $H \colon B \rightarrow A$ + (a "right inverse") such that $F \circ H$ is the identity function $I_B$ + on $B$ iff $F$ maps $A$ \textit{onto} $B$. + \end{enumerate} + \end{theorem} - Assume that $F \colon A \rightarrow B$, and that $A$ is nonempty. - \begin{enumerate}[(a)] - \item There exists a function $G \colon B \rightarrow A$ (a "left inverse") - such that $G \circ F$ is the identity function $I_A$ on $A$ iff $F$ is - one-to-one. - \item There exists a function $H \colon B \rightarrow A$ (a "right inverse") - such that $F \circ H$ is the identity function $I_B$ on $B$ iff $F$ maps - $A$ \textit{onto} $B$. - \end{enumerate} + \begin{proof} + Let $F$ be a \nameref{ref:function} from nonempty set $A$ to set $B$. -\end{theorem} + \paragraph{(a)}% -\begin{proof} + We prove there exists a function $G \colon B \rightarrow A$ such that + $G \circ F = I_A$ if and only if $F$ is one-to-one. - Let $F$ be a \nameref{ref:function} from nonempty set $A$ to set $B$. + \subparagraph{($\Rightarrow$)}% - \paragraph{(a)}% + Let $G \colon B \rightarrow A$ such that $G \circ F = I_A$. + All that remains is to prove $F$ is single-rooted. + Let $y \in \ran{F}$. + By definition of the \nameref{ref:range} of a function, there exists + some $x_1$ such that $\pair{x_1, y} \in F$. + Suppose there exists a set $x_2$ such that $\pair{x_2, y} \in F$. + By hypothesis, $G(F(x_1)) = G(F(x_2))$ implies $I_A(x_1) = I_A(x_2)$. + Thus $x_1 = x_2$. + Therefore $F$ must be single-rooted. - We prove there exists a function $G \colon B \rightarrow A$ such that - $G \circ F = I_A$ if and only if $F$ is one-to-one. + \subparagraph{($\Leftarrow$)}% - \subparagraph{($\Rightarrow$)}% + Let $F$ be one-to-one. + Since $A$ is nonempty, there exists some $a \in A$. + Let $G \colon B \rightarrow A$ be given by + $$G(y) = \begin{cases} + F^{-1}(y) & \text{if } y \in \ran{F} \\ + a & \text{otherwise}. + \end{cases}$$ + $G$ is a function by virtue of \nameref{sub:one-to-one-inverse} and + choice of mapping for all values $y \not\in \ran{F}$. + Furthermore, for all $x \in A$, $F(x) \in \ran{F}$. + Thus $(G \circ F)(x) = G(F(x)) = F^{-1}(F(x)) = x$ by + \nameref{sub:theorem-3g}. - Let $G \colon B \rightarrow A$ such that $G \circ F = I_A$. - All that remains is to prove $F$ is single-rooted. - Let $y \in \ran{F}$. - By definition of the \nameref{ref:range} of a function, there exists some - $x_1$ such that $\pair{x_1, y} \in F$. - Suppose there exists a set $x_2$ such that $\pair{x_2, y} \in F$. - By hypothesis, $G(F(x_1)) = G(F(x_2))$ implies $I_A(x_1) = I_A(x_2)$. - Thus $x_1 = x_2$. - Therefore $F$ must be single-rooted. + \paragraph{(b)}% - \subparagraph{($\Leftarrow$)}% + We prove there exists a function $H \colon B \rightarrow A$ such that + $F \circ H = I_A$ if and only if $F$ maps $A$ onto $B$. - Let $F$ be one-to-one. - Since $A$ is nonempty, there exists some $a \in A$. - Let $G \colon B \rightarrow A$ be given by - $$G(y) = \begin{cases} - F^{-1}(y) & \text{if } y \in \ran{F} \\ - a & \text{otherwise}. - \end{cases}$$ - $G$ is a function by virtue of \nameref{sub:one-to-one-inverse} and choice - of mapping for all values $y \not\in \ran{F}$. - Furthermore, for all $x \in A$, $F(x) \in \ran{F}$. - Thus $(G \circ F)(x) = G(F(x)) = F^{-1}(F(x)) = x$ by - \nameref{sub:theorem-3g}. + \subparagraph{($\Rightarrow$)}% - \paragraph{(b)}% + Suppose $H \colon B \rightarrow A$ such that $F \circ H = I_A$. + All that remains is to prove $\ran{F} = B$. + Note that $\ran{F} \subseteq B$ by hypothesis. + Let $y \in B$. + But $F(H(y)) = y$ meaning $y \in \ran{F}$. + Thus $B \subseteq \ran{F}$. + Since $\ran{F} \subseteq B$ and $B \subseteq \ran{F}$, $\ran{F} = B$. - We prove there exists a function $H \colon B \rightarrow A$ such that - $F \circ H = I_A$ if and only if $F$ maps $A$ onto $B$. + \subparagraph{($\Leftarrow$)}% - \subparagraph{($\Rightarrow$)}% + Suppose $F$ maps $A$ \textit{onto} $B$. + By definition of maps onto, $\ran{F} = B$. + Then for all $y \in B$, there exists some $x \in A$ such that + $\pair{x, y} \in F$. + Notice though that $F^{-1}[\{y\}]$ may not be a singleton set. + Then there is no obvious way to \textit{choose} an element from each + preimage to form a function. + By the \nameref{ref:axiom-of-choice-1}, there exists a function + $H \subseteq F^{-1}$ such that $\dom{H} = \dom{F^{-1}} = B$. + For all $y \in B$, $\pair{y, H(y)} \in H \subseteq F^{-1}$ + meaning $\pair{H(y), y} \in F$. + Thus $F(H(y)) = y$ as expected. - Suppose $H \colon B \rightarrow A$ such that $F \circ H = I_A$. - All that remains is to prove $\ran{F} = B$. - Note that $\ran{F} \subseteq B$ by hypothesis. - Let $y \in B$. - But $F(H(y)) = y$ meaning $y \in \ran{F}$. - Thus $B \subseteq \ran{F}$. - Since $\ran{F} \subseteq B$ and $B \subseteq \ran{F}$, $\ran{F} = B$. - - \subparagraph{($\Leftarrow$)}% - - Suppose $F$ maps $A$ \textit{onto} $B$. - By definition of maps onto, $\ran{F} = B$. - Then for all $y \in B$, there exists some $x \in A$ such that - $\pair{x, y} \in F$. - Notice though that $F^{-1}[\{y\}]$ may not be a singleton set. - Then there is no obvious way to \textit{choose} an element from each - preimage to form a function. - By the \nameref{ref:axiom-of-choice-1}, there exists a function - $H \subseteq F^{-1}$ such that $\dom{H} = \dom{F^{-1}} = B$. - For all $y \in B$, $\pair{y, H(y)} \in H \subseteq F^{-1}$ - meaning $\pair{H(y), y} \in F$. - Thus $F(H(y)) = y$ as expected. - -\end{proof} + \end{proof} \subsection{\verified{Theorem 3K(a)}}% \hyperlabel{sub:theorem-3k-a} -\begin{theorem}[3K(a)] - - The following hold for any sets. ($F$ need not be a function.) - The image of a union is the union of the images: - \begin{equation} - \hyperlabel{sub:theorem-3k-a-eq1} - \img{F}{A \cup B} = \img{F}{A} \cup \img{F}{B} - \end{equation} - and - \begin{equation} - \hyperlabel{sub:theorem-3k-a-eq2} - \img{F}{\bigcup{\mathscr{A}}} = - \bigcup\;\{\img{F}{A} \mid A \in \mathscr{A}\}. - \end{equation} - -\end{theorem} - -\begin{proof} + \begin{theorem}[3K(a)] + The following hold for any sets. ($F$ need not be a function.) + The image of a union is the union of the images: + \begin{equation} + \hyperlabel{sub:theorem-3k-a-eq1} + \img{F}{A \cup B} = \img{F}{A} \cup \img{F}{B} + \end{equation} + and + \begin{equation} + \hyperlabel{sub:theorem-3k-a-eq2} + \img{F}{\bigcup{\mathscr{A}}} = + \bigcup\;\{\img{F}{A} \mid A \in \mathscr{A}\}. + \end{equation} + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3k\_a} - Let $F$, $A$, $B$, and $\mathscr{A}$ be arbitrary sets. - We prove (i) \eqref{sub:theorem-3k-a-eq1} and (ii) - \eqref{sub:theorem-3k-a-eq2}. + \begin{proof} + Let $F$, $A$, $B$, and $\mathscr{A}$ be arbitrary sets. + We prove (i) \eqref{sub:theorem-3k-a-eq1} and (ii) + \eqref{sub:theorem-3k-a-eq2}. - \paragraph{(i)}% + \paragraph{(i)}% - By definition of the \nameref{ref:image} of a set: - \begin{align*} - \img{F}{A \cup B} - & = \{v \mid \exists u, u \in A \cup B \land uFv\} \\ - & = \{v \mid \exists u, - (u \in A \land uFv) \lor (u \in B \land uFv)\} \\ - & = \{v \mid (\exists u \in A) uFv\} \cup - \{v \mid (\exists u \in B) uFv\} \\ - & = \img{F}{A} \cup \img{F}{B}. - \end{align*} + By definition of the \nameref{ref:image} of a set: + \begin{align*} + \img{F}{A \cup B} + & = \{v \mid \exists u, u \in A \cup B \land uFv\} \\ + & = \{v \mid \exists u, + (u \in A \land uFv) \lor (u \in B \land uFv)\} \\ + & = \{v \mid (\exists u \in A) uFv\} \cup + \{v \mid (\exists u \in B) uFv\} \\ + & = \img{F}{A} \cup \img{F}{B}. + \end{align*} - \paragraph{(ii)}% + \paragraph{(ii)}% - We prove that both sides of \eqref{sub:theorem-3k-a-eq2} is a subset of the - other. + We prove that both sides of \eqref{sub:theorem-3k-a-eq2} is a subset of + the other. - \subparagraph{($\subseteq$)}% + \subparagraph{($\subseteq$)}% - Let $v \in \img{F}{\bigcup{\mathscr{A}}}$. - By definition of the \nameref{ref:image} of a set, there exists a set $u$ - such that $u \in \bigcup{\mathscr{A}} \land uFv$. - Then, by definition of the union of sets, there exists some - $A \in \mathscr{A}$ such that $u \in A$. - Therefore $v \in \img{F}{A}$ meaning - $v \in \bigcup\{\img{F}{A} \mid A \in \mathscr{A}\}$. + Let $v \in \img{F}{\bigcup{\mathscr{A}}}$. + By definition of the \nameref{ref:image} of a set, there exists a set + $u$ such that $u \in \bigcup{\mathscr{A}} \land uFv$. + Then, by definition of the union of sets, there exists some + $A \in \mathscr{A}$ such that $u \in A$. + Therefore $v \in \img{F}{A}$ meaning + $v \in \bigcup\{\img{F}{A} \mid A \in \mathscr{A}\}$. - \subparagraph{($\supseteq$)}% + \subparagraph{($\supseteq$)}% - Let $v \in \bigcup\{\img{F}{A} \mid A \in \mathscr{A}\}$. - Then there exists some $b \in \{\img{F}{A} \mid A \in \mathscr{A}\}$ such - that $v \in b$. - In other words, there exists some $A \in \mathscr{A}$ such that - $v \in b = \img{F}{A}$. - By definition of the \nameref{ref:image} of a set, there exists a set $u$ - such that $u \in A \land uFv$. - But this implies that $u \in \bigcup{\mathscr{A}} \land uFv$. - Therefore $v \in \img{F}{\bigcup{\mathscr{A}}}$. + Let $v \in \bigcup\{\img{F}{A} \mid A \in \mathscr{A}\}$. + Then there exists some $b \in \{\img{F}{A} \mid A \in \mathscr{A}\}$ + such that $v \in b$. + In other words, there exists some $A \in \mathscr{A}$ such that + $v \in b = \img{F}{A}$. + By definition of the \nameref{ref:image} of a set, there exists a set + $u$ such that $u \in A \land uFv$. + But this implies that $u \in \bigcup{\mathscr{A}} \land uFv$. + Therefore $v \in \img{F}{\bigcup{\mathscr{A}}}$. -\end{proof} + \end{proof} \subsection{\verified{Theorem 3K(b)}}% \hyperlabel{sub:theorem-3k-b} -\begin{theorem}[3K(b)] + \begin{theorem}[3K(b)] + The following hold for any sets. ($F$ need not be a function.) + The image of an intersection is included in the intersection of the images: + \begin{equation} + \hyperlabel{sub:theorem-3k-b-eq1} + \img{F}{A \cap B} \subseteq \img{F}{A} \cap \img{F}{B} + \end{equation} + and + \begin{equation} + \hyperlabel{sub:theorem-3k-b-eq2} + \img{F}{\bigcap\mathscr{A}} \subseteq + \bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\}. + \end{equation} + for nonempty $\mathscr{A}$. + Equality holds if $F$ is single-rooted. + \end{theorem} - The following hold for any sets. ($F$ need not be a function.) - The image of an intersection is included in the intersection of the images: - \begin{equation} - \hyperlabel{sub:theorem-3k-b-eq1} - \img{F}{A \cap B} \subseteq \img{F}{A} \cap \img{F}{B} - \end{equation} - and - \begin{equation} - \hyperlabel{sub:theorem-3k-b-eq2} - \img{F}{\bigcap\mathscr{A}} \subseteq - \bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\}. - \end{equation} - for nonempty $\mathscr{A}$. - Equality holds if $F$ is single-rooted. - -\end{theorem} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3k\_b\_i} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3k\_b\_ii} - Let $F$, $A$, $B$ be arbitrary sets. - Let $\mathscr{A}$ be a nonempty set. - We first prove (i) \eqref{sub:theorem-3k-b-eq1} and (ii) - \eqref{sub:theorem-3k-b-eq2}. - Then, assuming $F$ is single-rooted, we prove both (iii) - \eqref{sub:theorem-3k-b-eq1} and (iv) \eqref{sub:theorem-3k-b-eq2} hold - under equality. + \begin{proof} + Let $F$, $A$, $B$ be arbitrary sets. + Let $\mathscr{A}$ be a nonempty set. + We first prove (i) \eqref{sub:theorem-3k-b-eq1} and (ii) + \eqref{sub:theorem-3k-b-eq2}. + Then, assuming $F$ is single-rooted, we prove both (iii) + \eqref{sub:theorem-3k-b-eq1} and (iv) \eqref{sub:theorem-3k-b-eq2} hold + under equality. - \paragraph{(i)}% - \hyperlabel{par:theorem-3k-b-i} + \paragraph{(i)}% + \hyperlabel{par:theorem-3k-b-i} - Let $v \in \img{F}{A \cap B}$. - By definition of the \nameref{ref:image} of a set, - $\exists u \in A \cap B, uFv$. - Then $u \in A \land uFv$ and $u \in B \land uFv$. - Therefore $v \in \img{F}{A} \cap \img{F}{B}$. + Let $v \in \img{F}{A \cap B}$. + By definition of the \nameref{ref:image} of a set, + $\exists u \in A \cap B, uFv$. + Then $u \in A \land uFv$ and $u \in B \land uFv$. + Therefore $v \in \img{F}{A} \cap \img{F}{B}$. - \paragraph{(ii)}% - \hyperlabel{par:theorem-3k-b-ii} + \paragraph{(ii)}% + \hyperlabel{par:theorem-3k-b-ii} - Let $v \in \img{F}{\bigcap{\mathscr{A}}}$. - By definition of the \nameref{ref:image} of a set, - $\exists u \in \bigcap{\mathscr{A}}, uFv$. - Then $\exists u, (\forall A \in \mathscr{A}, u \in A) \land uFv$. - This implies that $\forall A \in \mathscr{A}, \exists u \in A, uFv$. - Then $\forall A \in \mathscr{A}, v \in \img{F}{A}$. - Thus $v \in \bigcap\{\img{F}{A} \mid A \in \mathscr{A}\}$. + Let $v \in \img{F}{\bigcap{\mathscr{A}}}$. + By definition of the \nameref{ref:image} of a set, + $\exists u \in \bigcap{\mathscr{A}}, uFv$. + Then $\exists u, (\forall A \in \mathscr{A}, u \in A) \land uFv$. + This implies that $\forall A \in \mathscr{A}, \exists u \in A, uFv$. + Then $\forall A \in \mathscr{A}, v \in \img{F}{A}$. + Thus $v \in \bigcap\{\img{F}{A} \mid A \in \mathscr{A}\}$. - \paragraph{(iii)}% + \paragraph{(iii)}% - Suppose $F$ is single-rooted. - By \nameref{par:theorem-3k-b-i}, - $$\img{F}{A \cap B} \subseteq \img{F}{A} \cap \img{F}{B}.$$ - All that remains is showing - $$\img{F}{A} \cap \img{F}{B} \subseteq \img{F}{A \cap B}.$$ - Let $v \in \img{F}{A} \cap \img{F}{B}$. - Then $v \in \img{F}{A}$ and $v \in \img{F}{B}$. - That is, $\exists u \in A, uFv$ and $\exists w \in B, wFv$. - Since $F$ is single rooted, it follows $u = w$. - Thus $u \in A \cap B \land uFv$ meaning $v \in \img{F}{A \cap B}$. + Suppose $F$ is single-rooted. + By \nameref{par:theorem-3k-b-i}, + $$\img{F}{A \cap B} \subseteq \img{F}{A} \cap \img{F}{B}.$$ + All that remains is showing + $$\img{F}{A} \cap \img{F}{B} \subseteq \img{F}{A \cap B}.$$ + Let $v \in \img{F}{A} \cap \img{F}{B}$. + Then $v \in \img{F}{A}$ and $v \in \img{F}{B}$. + That is, $\exists u \in A, uFv$ and $\exists w \in B, wFv$. + Since $F$ is single rooted, it follows $u = w$. + Thus $u \in A \cap B \land uFv$ meaning $v \in \img{F}{A \cap B}$. - \paragraph{(iv)}% + \paragraph{(iv)}% - Suppose $F$ is single-rooted. - By \nameref{par:theorem-3k-b-ii}, - $$\img{F}{\bigcap\mathscr{A}} \subseteq - \bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\}.$$ - All that remains is showing - $$\bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\} \subseteq - \img{F}{\bigcap\mathscr{A}}.$$ - Let $v \in \bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\}$. - Then $\forall A \in \mathscr{A}, v \in \img{F}{A}$. - By definition of the \nameref{ref:image} of a set, - $\forall A \in \mathscr{A}, \exists u \in A, uFv$. - Since $F$ is single-rooted and $\mathscr{A}$ is nonempty, it follows that - $\exists u, (\forall A \in \mathscr{A}, u \in A) \land uFv$. - Equivalently, $\exists u \in \bigcap{A}, uFv$. - Thus $v \in \img{F}{\bigcap{A}}$. + Suppose $F$ is single-rooted. + By \nameref{par:theorem-3k-b-ii}, + $$\img{F}{\bigcap\mathscr{A}} \subseteq + \bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\}.$$ + All that remains is showing + $$\bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\} \subseteq + \img{F}{\bigcap\mathscr{A}}.$$ + Let $v \in \bigcap\;\{\img{F}{A} \mid A \in \mathscr{A}\}$. + Then $\forall A \in \mathscr{A}, v \in \img{F}{A}$. + By definition of the \nameref{ref:image} of a set, + $\forall A \in \mathscr{A}, \exists u \in A, uFv$. + Since $F$ is single-rooted and $\mathscr{A}$ is nonempty, it follows that + $\exists u, (\forall A \in \mathscr{A}, u \in A) \land uFv$. + Equivalently, $\exists u \in \bigcap{A}, uFv$. + Thus $v \in \img{F}{\bigcap{A}}$. -\end{proof} + \end{proof} \subsection{\verified{Theorem 3K(c)}}% \hyperlabel{sub:theorem-3k-c} -\begin{theorem}[3K(c)] + \begin{theorem}[3K(c)] + The following hold for any sets. ($F$ need not be a function.) + The image of a difference includes the difference of the images: + \begin{equation} + \hyperlabel{sub:theorem-3k-c-eq1} + \img{F}{A} - \img{F}{B} \subseteq \img{F}{A - B}. + \end{equation} + Equality holds if $F$ is single-rooted. + \end{theorem} - The following hold for any sets. ($F$ need not be a function.) - The image of a difference includes the difference of the images: - \begin{equation} - \hyperlabel{sub:theorem-3k-c-eq1} - \img{F}{A} - \img{F}{B} \subseteq \img{F}{A - B}. - \end{equation} - Equality holds if $F$ is single-rooted. - -\end{theorem} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3k\_c\_i} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3k\_c\_ii} - We prove that (i) \eqref{sub:theorem-3k-c-eq1} holds and (ii) equality holds - if $F$ is single-rooted. + \begin{proof} + We prove that (i) \eqref{sub:theorem-3k-c-eq1} holds and (ii) equality holds + if $F$ is single-rooted. - \paragraph{(i)}% - \hyperlabel{par:theorem-3k-c-i} + \paragraph{(i)}% + \hyperlabel{par:theorem-3k-c-i} - Let $v \in \img{F}{A} - \img{F}{B}$. - By definition of the difference of two sets, - $v \in \img{F}{A}$ and $v \not\in \img{F}{B}$. - By definition of the \nameref{ref:image} of a set, there exists a set - $u \in A$ such that $\pair{u, v} \in F$. - Likewise, $\forall w \in B, \pair{w, v} \not\in F$. - Thus $u \not\in B$, since otherwise we get an immediate contradiction. - Therefore $u \in A - B$ meaning $v \in \img{F}{A - B}$. + Let $v \in \img{F}{A} - \img{F}{B}$. + By definition of the difference of two sets, + $v \in \img{F}{A}$ and $v \not\in \img{F}{B}$. + By definition of the \nameref{ref:image} of a set, there exists a set + $u \in A$ such that $\pair{u, v} \in F$. + Likewise, $\forall w \in B, \pair{w, v} \not\in F$. + Thus $u \not\in B$, since otherwise we get an immediate contradiction. + Therefore $u \in A - B$ meaning $v \in \img{F}{A - B}$. - \paragraph{(ii)}% + \paragraph{(ii)}% - Suppose $F$ is single-rooted. - By \nameref{par:theorem-3k-c-i}, - $$\img{F}{A} - \img{F}{B} \subseteq \img{F}{A - B}.$$ - All that remains is showing - $$\img{F}{A - B} \subseteq \img{F}{A} - \img{F}{B}.$$ - Let $v \in \img{F}{A - B}$. - By definition of the \nameref{ref:image} of a set, there exists a set - $u \in A - B$ such that $uFv$. - Then $u \in A$ and $u \not\in B$. - The former membership relation implies $v \in \img{F}{A}$. - The latter implies $v \not\in \img{F}{B}$ since $F$ being single-rooted - would otherwise invoke an immediate contradiction. - Thus $v \in \img{F}{A} - \img{F}{B}$. + Suppose $F$ is single-rooted. + By \nameref{par:theorem-3k-c-i}, + $$\img{F}{A} - \img{F}{B} \subseteq \img{F}{A - B}.$$ + All that remains is showing + $$\img{F}{A - B} \subseteq \img{F}{A} - \img{F}{B}.$$ + Let $v \in \img{F}{A - B}$. + By definition of the \nameref{ref:image} of a set, there exists a set + $u \in A - B$ such that $uFv$. + Then $u \in A$ and $u \not\in B$. + The former membership relation implies $v \in \img{F}{A}$. + The latter implies $v \not\in \img{F}{B}$ since $F$ being single-rooted + would otherwise invoke an immediate contradiction. + Thus $v \in \img{F}{A} - \img{F}{B}$. -\end{proof} + \end{proof} \subsection{\verified{Corollary 3L}}% \hyperlabel{sub:corollary-3l} -\begin{theorem}[3L] + \begin{theorem}[3L] + For any function $G$ and sets $A$, $B$, and $\mathscr{A}$: + \begin{align} + \img{G^{-1}}{\bigcup{\mathscr{A}}} + & = \bigcup\;\{\img{G^{-1}}{A} \mid A \in \mathscr{A}\}, + \hyperlabel{sub:corollary-3l-eq1} \\ + \img{G^{-1}}{\bigcap{\mathscr{A}}} + & = \bigcap\;\{\img{G^{-1}}{A} \mid A \in \mathscr{A}\} + \text{ for } \mathscr{A} \neq \emptyset, + \hyperlabel{sub:corollary-3l-eq2} \\ + \img{G^{-1}}{A - B} & = \img{G^{-1}}{A} - \img{G^{-1}}{B}. + \hyperlabel{sub:corollary-3l-eq3} + \end{align} + \end{theorem} - For any function $G$ and sets $A$, $B$, and $\mathscr{A}$: - \begin{align} - \img{G^{-1}}{\bigcup{\mathscr{A}}} - & = \bigcup\;\{\img{G^{-1}}{A} \mid A \in \mathscr{A}\}, - \hyperlabel{sub:corollary-3l-eq1} \\ - \img{G^{-1}}{\bigcap{\mathscr{A}}} - & = \bigcap\;\{\img{G^{-1}}{A} \mid A \in \mathscr{A}\} - \text{ for } \mathscr{A} \neq \emptyset, - \hyperlabel{sub:corollary-3l-eq2} \\ - \img{G^{-1}}{A - B} & = \img{G^{-1}}{A} - \img{G^{-1}}{B}. - \hyperlabel{sub:corollary-3l-eq3} - \end{align} - -\end{theorem} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.corollary\_3l\_i} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.corollary\_3l\_ii} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.corollary\_3l\_iii} - \nameref{sub:theorem-3k-a} implies \eqref{sub:corollary-3l-eq1}. - Because the inverse of a function is always single-rooted, - \nameref{sub:theorem-3k-b} implies \eqref{sub:corollary-3l-eq2}. - Likewise \nameref{sub:theorem-3k-c} implies \eqref{sub:corollary-3l-eq3}. - -\end{proof} + \begin{proof} + \nameref{sub:theorem-3k-a} implies \eqref{sub:corollary-3l-eq1}. + Because the inverse of a function is always single-rooted, + \nameref{sub:theorem-3k-b} implies \eqref{sub:corollary-3l-eq2}. + Likewise \nameref{sub:theorem-3k-c} implies \eqref{sub:corollary-3l-eq3}. + \end{proof} \section{Equivalence Relations}% \hyperlabel{sec:equivalence-relations} @@ -3641,190 +3285,177 @@ If not, then under what conditions does equality hold? \subsection{\verified{Theorem 3M}}% \hyperlabel{sub:theorem-3m} -\begin{theorem}[3M] - - If $R$ is a symmetric and transitive relation, then $R$ is an equivalence - relation on $\fld{R}$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[3M] + If $R$ is a symmetric and transitive relation, then $R$ is an equivalence + relation on $\fld{R}$. + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3m} - Suppose $R$ is a \nameref{ref:symmetric} and \nameref{ref:transitive} - \nameref{ref:relation}. - By definition, the \nameref{ref:field} of $R$ is given by - $\fld{R} = \dom{R} \cup \ran{R}$. - An \nameref{ref:equivalence-relation} on $\fld{R}$ is, by definition, a - binary relation \nameref{ref:reflexive} on $\fld{R}$, symmetric, and - transitive. - All that remains is to show $R$ is reflexive on $\fld{R}$. + \begin{proof} + Suppose $R$ is a \nameref{ref:symmetric} and \nameref{ref:transitive} + \nameref{ref:relation}. + By definition, the \nameref{ref:field} of $R$ is given by + $\fld{R} = \dom{R} \cup \ran{R}$. + An \nameref{ref:equivalence-relation} on $\fld{R}$ is, by definition, a + binary relation \nameref{ref:reflexive} on $\fld{R}$, symmetric, and + transitive. + All that remains is to show $R$ is reflexive on $\fld{R}$. - Let $x \in \fld{R}$. - Then $x \in \dom{R}$ or $x \in \ran{R}$. - If $x \in \dom{R}$, there exists some $y$ such that $xRy$. - Since $R$ is symmetric, it follows $yRx$. - Since $R$ is transitive, it follows $xRx$. - If instead $x \in \ran{R}$, there exists some $t$ such that $tRx$. - Since $R$ is symmetric, it follows $xRt$. - Since $R$ is transitive, it follows $xRx$. - Thus $R$ is reflexive on $\fld{R}$. - -\end{proof} + Let $x \in \fld{R}$. + Then $x \in \dom{R}$ or $x \in \ran{R}$. + If $x \in \dom{R}$, there exists some $y$ such that $xRy$. + Since $R$ is symmetric, it follows $yRx$. + Since $R$ is transitive, it follows $xRx$. + If instead $x \in \ran{R}$, there exists some $t$ such that $tRx$. + Since $R$ is symmetric, it follows $xRt$. + Since $R$ is transitive, it follows $xRx$. + Thus $R$ is reflexive on $\fld{R}$. + \end{proof} \subsection{\verified{Lemma 3N}}% \hyperlabel{sub:lemma-3n} -\begin{lemma}[3N] - - Assume that $R$ is an equivalence relation on $A$ and that $x$ and $y$ belong - to $A$. - Then $$[x]_R = [y]_R \iff xRy.$$ - -\end{lemma} - -\begin{proof} + \begin{lemma}[3N] + Assume that $R$ is an equivalence relation on $A$ and that $x$ and $y$ + belong to $A$. + Then $$[x]_R = [y]_R \iff xRy.$$ + \end{lemma} \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.neighborhood\_iff\_mem} - Suppose $R$ is an \nameref{ref:equivalence-relation} on set $A$. - Let $x, y \in A$. + \begin{proof} + Suppose $R$ is an \nameref{ref:equivalence-relation} on set $A$. + Let $x, y \in A$. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $[x]_R = [y]_R$. - Since $R$ is an equivalence relation, it is reflexive on $A$. - Thus $yRy$ meaning $y \in [y]_R = \{t \mid yRt\}$. - Since $[x]_R = [y]_R$, $y \in \{t \mid xRt\}$ as well. - That is, $xRy$. + Suppose $[x]_R = [y]_R$. + Since $R$ is an equivalence relation, it is reflexive on $A$. + Thus $yRy$ meaning $y \in [y]_R = \{t \mid yRt\}$. + Since $[x]_R = [y]_R$, $y \in \{t \mid xRt\}$ as well. + That is, $xRy$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $xRy$. - We show $[x]_R \subseteq [y]_R$ and $[y]_R \subseteq [x]_R$. + Suppose $xRy$. + We show $[x]_R \subseteq [y]_R$ and $[y]_R \subseteq [x]_R$. - \subparagraph{($\subseteq$)}% + \subparagraph{($\subseteq$)}% - Let $t \in [x]_R$. - Then $xRt$. - Since $R$ is symmetric, $xRy$ implies $yRx$. - Since $R$ is transitive, $yRx$ and $xRt$ implies $yRt$. - Thus $t \in [y]_R$. + Let $t \in [x]_R$. + Then $xRt$. + Since $R$ is symmetric, $xRy$ implies $yRx$. + Since $R$ is transitive, $yRx$ and $xRt$ implies $yRt$. + Thus $t \in [y]_R$. - \subparagraph{($\supseteq$)}% + \subparagraph{($\supseteq$)}% - Let $t \in [y]_R$. - Then $yRt$. - Since $R$ is transitive, $xRy$ and $yRt$ implies $xRt$. - Thus $t \in [x]_R$. + Let $t \in [y]_R$. + Then $yRt$. + Since $R$ is transitive, $xRy$ and $yRt$ implies $xRt$. + Thus $t \in [x]_R$. -\end{proof} + \end{proof} \subsection{\verified{Theorem 3P}}% \hyperlabel{sub:theorem-3p} -\begin{theorem}[3P] - - Assume that $R$ is an equivalence relation on $A$. - Then the set $\{[x]_R \mid x \in A\}$ of all equivalence classes is a - partition of $A$. - -\end{theorem} - -\begin{proof} + \begin{theorem}[3P] + Assume that $R$ is an equivalence relation on $A$. + Then the set $\{[x]_R \mid x \in A\}$ of all equivalence classes is a + partition of $A$. + \end{theorem} \code{Bookshelf/Enderton/Set/Relation} {Set.Relation.modEquiv\_partition} - Let $\Pi = \{[x]_R \mid x \in A\}$. - We show that (i) there are no empty sets in $\Pi$, (ii) no two different sets - in $\Pi$ have any common elements and (iii) that each element of $A$ is in - some set in $\Pi$. + \begin{proof} + Let $\Pi = \{[x]_R \mid x \in A\}$. + We show that (i) there are no empty sets in $\Pi$, (ii) no two different + sets in $\Pi$ have any common elements and (iii) that each element of $A$ + is in some set in $\Pi$. - \paragraph{(i)}% + \paragraph{(i)}% - By construction, every element of $\Pi$ is of form $[x]_R$ for some - $x \in A$. - At the very least, $x \in A$ is also in $[x]_R$. - Thus every element of $\Pi$ must be nonempty. + By construction, every element of $\Pi$ is of form $[x]_R$ for some + $x \in A$. + At the very least, $x \in A$ is also in $[x]_R$. + Thus every element of $\Pi$ must be nonempty. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $[x]_R, [y]_R \in \Pi$ be two different sets. - We must show that $[x]_R \cap [y]_R = \emptyset$. - For the sake of contradiction, suppose $[x]_R \cap [y]_R \neq \emptyset$. - Let $z \in [x]_R \cap [y]_R$. - Then $xRz$ and $yRz$. - Since $R$ is an \nameref{ref:equivalence-relation} on $A$, it is - \nameref{ref:symmetric} and \nameref{ref:transitive}. - Then $zRy$ and $xRy$. - By \nameref{sub:lemma-3n}, $xRy$ if and only if $[x]_R = [y]_R$, - contradicting the distinctness of $[x]_R$ and $[y]_R$. - Thus it follows $[x]_R \cap [y]_R] = \emptyset$. + Let $[x]_R, [y]_R \in \Pi$ be two different sets. + We must show that $[x]_R \cap [y]_R = \emptyset$. + For the sake of contradiction, suppose $[x]_R \cap [y]_R \neq \emptyset$. + Let $z \in [x]_R \cap [y]_R$. + Then $xRz$ and $yRz$. + Since $R$ is an \nameref{ref:equivalence-relation} on $A$, it is + \nameref{ref:symmetric} and \nameref{ref:transitive}. + Then $zRy$ and $xRy$. + By \nameref{sub:lemma-3n}, $xRy$ if and only if $[x]_R = [y]_R$, + contradicting the distinctness of $[x]_R$ and $[y]_R$. + Thus it follows $[x]_R \cap [y]_R] = \emptyset$. - \paragraph{(iii)}% + \paragraph{(iii)}% - Let $x \in A$. - Since $R$ is an \nameref{ref:equivalence-relation} on $A$, it follows - $xRx$. - Thus $x$ is a member of some set in $\Pi$, namely $[x]_R$. + Let $x \in A$. + Since $R$ is an \nameref{ref:equivalence-relation} on $A$, it follows + $xRx$. + Thus $x$ is a member of some set in $\Pi$, namely $[x]_R$. -\end{proof} + \end{proof} \subsection{\unverified{Theorem 3Q}}% \hyperlabel{sub:theorem-3q} -\begin{theorem}[3Q] + \begin{theorem}[3Q] + Assume that $R$ is an equivalence relation on $A$ and that + $F \colon A \rightarrow A$. + If $F$ is compatible with $R$, then there exists a unique + $\hat{F} \colon A / R \rightarrow A / R$ such that + \begin{equation} + \hyperlabel{sub:theorem-3q-eq1} + \hat{F}([x]_R) = [F(x)]_R \quad\text{for all } x \text{ in } A. + \end{equation} + If $F$ is not compatible with $R$, then no such $\hat{F}$ exists. + \end{theorem} - Assume that $R$ is an equivalence relation on $A$ and that - $F \colon A \rightarrow A$. - If $F$ is compatible with $R$, then there exists a unique - $\hat{F} \colon A / R \rightarrow A / R$ such that - \begin{equation} - \hyperlabel{sub:theorem-3q-eq1} - \hat{F}([x]_R) = [F(x)]_R \quad\text{for all } x \text{ in } A. - \end{equation} - If $F$ is not compatible with $R$, then no such $\hat{F}$ exists. + \begin{proof} + Let $R$ be an \nameref{ref:equivalence-relation} on $A$ and + $F \colon A \rightarrow A$. + Suppose $F$ is \nameref{ref:compatible} with $R$. + Next define \nameref{ref:relation} $\hat{F}$ to be + $$\hat{F} = \{\pair{[x]_R, [F(x)]_R} \mid x \in A\}.$$ + By construction $\hat{F}$ has domain $A / R$ and + $\ran{\hat{F}} \subseteq A / R$. + All that remains is proving $\hat{F}$ is single-valued. + Let $[x_1]_R, [x_2]_R \in \dom{\hat{F}}$ such that $[x_1]_R = [x_2]_R$. + By definition of $\hat{F}$, $\pair{[x_1]_R, [F(x_1)]_R} \in \hat{F}$ + and $\pair{[x_2]_R, [F(x_2)]_R} \in \hat{F}$. + By \nameref{sub:lemma-3n}, $[x_1]_R = [x_2]_R$ implies $x_1Rx_2$. + Since $F$ is compatible, $F(x_1)RF(x_2)$. + Another application of \nameref{sub:lemma-3n} implies that + $[F(x_1)]_R = [F(x_2)]_R$. + Thus $\hat{F}$ is single-valued. -\end{theorem} + Uniqueness follows immediately from the \nameref{ref:extensionality-axiom}. -\begin{proof} + \suitdivider - Let $R$ be an \nameref{ref:equivalence-relation} on $A$ and - $F \colon A \rightarrow A$. - Suppose $F$ is \nameref{ref:compatible} with $R$. - Next define \nameref{ref:relation} $\hat{F}$ to be - $$\hat{F} = \{\pair{[x]_R, [F(x)]_R} \mid x \in A\}.$$ - By construction $\hat{F}$ has domain $A / R$ and - $\ran{\hat{F}} \subseteq A / R$. - All that remains is proving $\hat{F}$ is single-valued. - Let $[x_1]_R, [x_2]_R \in \dom{\hat{F}}$ such that $[x_1]_R = [x_2]_R$. - By definition of $\hat{F}$, $\pair{[x_1]_R, [F(x_1)]_R} \in \hat{F}$ - and $\pair{[x_2]_R, [F(x_2)]_R} \in \hat{F}$. - By \nameref{sub:lemma-3n}, $[x_1]_R = [x_2]_R$ implies $x_1Rx_2$. - Since $F$ is compatible, $F(x_1)RF(x_2)$. - Another application of \nameref{sub:lemma-3n} implies that - $[F(x_1)]_R = [F(x_2)]_R$. - Thus $\hat{F}$ is single-valued. - - Uniqueness follows immediately from the \nameref{ref:extensionality-axiom}. - - \suitdivider - - Suppose $F$ is not compatible with $R$. - Then there exists some $x, y \in A$ such that $xRy$ and $\neg F(x)RF(y)$. - By \nameref{sub:lemma-3n}, $[x]_R = [y]_R$. - For the sake of contradiction, suppose a function $\hat{F}$ exists satisfying - \eqref{sub:theorem-3q-eq1}. - Then $\hat{F}([x]_R) = \hat{F}([y]_R)$ meaning $[F(x)]_R = [F(y)]_R$. - Then \nameref{sub:lemma-3n} implies $F(x)RF(y)$, a contradiction. - Therefore our original hypothesis must be incorrect. - That is, there is no function $\hat{F}$ satisfying \eqref{sub:theorem-3q-eq1}. - -\end{proof} + Suppose $F$ is not compatible with $R$. + Then there exists some $x, y \in A$ such that $xRy$ and $\neg F(x)RF(y)$. + By \nameref{sub:lemma-3n}, $[x]_R = [y]_R$. + For the sake of contradiction, suppose a function $\hat{F}$ exists + satisfying \eqref{sub:theorem-3q-eq1}. + Then $\hat{F}([x]_R) = \hat{F}([y]_R)$ meaning $[F(x)]_R = [F(y)]_R$. + Then \nameref{sub:lemma-3n} implies $F(x)RF(y)$, a contradiction. + Therefore our original hypothesis must be incorrect. + That is, there is no function $\hat{F}$ satisfying + \eqref{sub:theorem-3q-eq1}. + \end{proof} \section{Ordering Relations}% \hyperlabel{sec:ordering-relations} @@ -3832,38 +3463,35 @@ If not, then under what conditions does equality hold? \subsection{\verified{Theorem 3R}}% \hyperlabel{sub:theorem-3r} -\begin{theorem}[3R] - - Let $R$ be a linear ordering on $A$. - \begin{enumerate}[(i)] - \item There is no $x$ for which $xRx$. - \item For distinct $x$ and $y$ in $A$, either $xRy$ or $yRx$ (but not both). - \end{enumerate} - -\end{theorem} - -\begin{proof} + \begin{theorem}[3R] + Let $R$ be a linear ordering on $A$. + \begin{enumerate}[(i)] + \item There is no $x$ for which $xRx$. + \item For distinct $x$ and $y$ in $A$, either $xRy$ or $yRx$ (but not both). + \end{enumerate} + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.theorem\_3r} - Suppose $R$ is a \nameref{ref:linear-ordering} on $A$. + \begin{proof} + Suppose $R$ is a \nameref{ref:linear-ordering} on $A$. - \paragraph{(i)}% + \paragraph{(i)}% - Let $x \in A$. - By definition, $R$ is \nameref{ref:trichotomous}. - Then only one of $xRx$ and $x = x$ can hold. - Since $x = x$ obviously holds, it follows $\pair{x, x} \not\in R$. + Let $x \in A$. + By definition, $R$ is \nameref{ref:trichotomous}. + Then only one of $xRx$ and $x = x$ can hold. + Since $x = x$ obviously holds, it follows $\pair{x, x} \not\in R$. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $x, y \in A$ such that $x \neq y$. - By definition, $R$ is \nameref{ref:trichotomous}. - Thus only one of $$xRy, \quad x = y, \quad yRx$$ hold. - By hypothesis $x \neq y$ meaning either $xRy$ or $yRx$ (but not both). + Let $x, y \in A$ such that $x \neq y$. + By definition, $R$ is \nameref{ref:trichotomous}. + Thus only one of $$xRy, \quad x = y, \quad yRx$$ hold. + By hypothesis $x \neq y$ meaning either $xRy$ or $yRx$ (but not both). -\end{proof} + \end{proof} \section{Exercises 3}% \hyperlabel{sec:exercises-3} @@ -3871,410 +3499,391 @@ If not, then under what conditions does equality hold? \subsection{\verified{Exercise 3.1}}% \hyperlabel{sub:exercise-3.1} -Suppose that we attempted to generalize the Kuratowski definitions of ordered - pairs to ordered triples by defining - $$\pair{x, y, z}^* = \{\{x\}, \{x, y\}, \{x, y, z\}\}.$$ -Show that this definition is unsuccessful by giving examples of objects - $u$, $v$, $w$, $x$, $y$, $z$ with - $\pair{x, y, z}^* = \pair{u, v, w}^*$ but with either - $y \neq v$ or $z \neq w$ (or both). + Suppose that we attempted to generalize the Kuratowski definitions of ordered + pairs to ordered triples by defining + $$\pair{x, y, z}^* = \{\{x\}, \{x, y\}, \{x, y, z\}\}.$$ + Show that this definition is unsuccessful by giving examples of objects + $u$, $v$, $w$, $x$, $y$, $z$ with + $\pair{x, y, z}^* = \pair{u, v, w}^*$ but with either + $y \neq v$ or $z \neq w$ (or both). -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_1} - Let $x = 1$, $y = 1$, and $z = 2$. - Let $u = 1$, $v = 2$, and $w = 2$. - Then - \begin{align*} - \pair{x, y, z}^* - & = \{\{x\}, \{x, y\}, \{x, y, z\}\} \\ - & = \{\{1\}, \{1, 1\}, \{1, 1, 2\}\} \\ - & = \{\{1\}, \{1, 2\}\}. - \end{align*} - Likewise - \begin{align*} - \pair{u, v, w}^* - & = \{\{u\}, \{u, v\}, \{u, v, w\}\} \\ - & = \{\{1\}, \{1, 2\}, \{1, 2, 2\}\} \\ - & = \{\{1\}, \{1, 2\}\}. - \end{align*} - Thus $\pair{x, y, z}^* = \pair{u, v, w}^*$ but $y \neq v$. - -\end{proof} + \begin{proof} + Let $x = 1$, $y = 1$, and $z = 2$. + Let $u = 1$, $v = 2$, and $w = 2$. + Then + \begin{align*} + \pair{x, y, z}^* + & = \{\{x\}, \{x, y\}, \{x, y, z\}\} \\ + & = \{\{1\}, \{1, 1\}, \{1, 1, 2\}\} \\ + & = \{\{1\}, \{1, 2\}\}. + \end{align*} + Likewise + \begin{align*} + \pair{u, v, w}^* + & = \{\{u\}, \{u, v\}, \{u, v, w\}\} \\ + & = \{\{1\}, \{1, 2\}, \{1, 2, 2\}\} \\ + & = \{\{1\}, \{1, 2\}\}. + \end{align*} + Thus $\pair{x, y, z}^* = \pair{u, v, w}^*$ but $y \neq v$. + \end{proof} \subsection{\verified{Exercise 3.2a}}% \hyperlabel{sub:exercise-3.2a} -Show that $A \times (B \cup C) = (A \times B) \cup (A \times C)$. + Show that $A \times (B \cup C) = (A \times B) \cup (A \times C)$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_2a} - Let $A$, $B$, and $C$ be arbitrary sets. - Then by \nameref{sub:corollary-3c} and the definition of the union of sets, - \begin{align*} - A \times (B \cup C) - & = \{ \pair{x, y} \mid x \in A \land y \in (B \cup C) \} \\ - & = \{ \pair{x, y} \mid - x \in A \land (y \in B \lor y \in C) \} \\ - & = \{ \pair{x, y} \mid - (x \in A \land y \in B) \lor (x \in A \land y \in C) \} \\ - & = \{ \pair{x, y} \mid (x \in A \land y \in B) \} \cup - \{ \pair{x, y} \mid (x \in A \land y \in C) \} \\ - & = (A \times B) \cup (A \times C). - \end{align*} - -\end{proof} + \begin{proof} + Let $A$, $B$, and $C$ be arbitrary sets. + Then by \nameref{sub:corollary-3c} and the definition of the union of sets, + \begin{align*} + A \times (B \cup C) + & = \{ \pair{x, y} \mid x \in A \land y \in (B \cup C) \} \\ + & = \{ \pair{x, y} \mid + x \in A \land (y \in B \lor y \in C) \} \\ + & = \{ \pair{x, y} \mid + (x \in A \land y \in B) \lor (x \in A \land y \in C) \} \\ + & = \{ \pair{x, y} \mid (x \in A \land y \in B) \} \cup + \{ \pair{x, y} \mid (x \in A \land y \in C) \} \\ + & = (A \times B) \cup (A \times C). + \end{align*} + \end{proof} \subsection{\verified{Exercise 3.2b}}% \hyperlabel{sub:exercise-3.2b} -Show that if $A \times B = A \times C$ and $A \neq \emptyset$, then $B = C$. + Show that if $A \times B = A \times C$ and $A \neq \emptyset$, then $B = C$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_2b} - Let $A$, $B$, and $C$ be arbitrary sets such that $A \neq \emptyset$. - By \nameref{sub:corollary-3c}, - \begin{align} - A \times B & = \{ \pair{x, y} \mid x \in A \land y \in B \} - & \hyperlabel{sub:exercise-3.2b-eq1} \\ - A \times C & = \{ \pair{x, y} \mid x \in A \land y \in C \}. - & \hyperlabel{sub:exercise-3.2b-eq2} - \end{align} - There are two cases to consider: + \begin{proof} + Let $A$, $B$, and $C$ be arbitrary sets such that $A \neq \emptyset$. + By \nameref{sub:corollary-3c}, + \begin{align} + A \times B & = \{ \pair{x, y} \mid x \in A \land y \in B \} + & \hyperlabel{sub:exercise-3.2b-eq1} \\ + A \times C & = \{ \pair{x, y} \mid x \in A \land y \in C \}. + & \hyperlabel{sub:exercise-3.2b-eq2} + \end{align} + There are two cases to consider: - \paragraph{Case 1}% + \paragraph{Case 1}% - Suppose $B \neq \emptyset$. - Then $A \times B \neq \emptyset$ and $A \times C \neq \emptyset$. - Let $\pair{x, y} \in A \times B$. - By \eqref{sub:exercise-3.2b-eq1}, $x \in A$ and $y \in B$. - By the \nameref{ref:extensionality-axiom}, - $$\pair{x, y} \in A \times B \iff \pair{x, y} \in A \times C.$$ - Therefore $\pair{x, y} \in A \times C$. - By \eqref{sub:exercise-3.2b-eq2}, $x \in A$ and $y \in C$. - Since membership of $y$ in $B$ and in $C$ holds biconditionally, the - \nameref{ref:extensionality-axiom} indicates $B = C$. + Suppose $B \neq \emptyset$. + Then $A \times B \neq \emptyset$ and $A \times C \neq \emptyset$. + Let $\pair{x, y} \in A \times B$. + By \eqref{sub:exercise-3.2b-eq1}, $x \in A$ and $y \in B$. + By the \nameref{ref:extensionality-axiom}, + $$\pair{x, y} \in A \times B \iff \pair{x, y} \in A \times C.$$ + Therefore $\pair{x, y} \in A \times C$. + By \eqref{sub:exercise-3.2b-eq2}, $x \in A$ and $y \in C$. + Since membership of $y$ in $B$ and in $C$ holds biconditionally, the + \nameref{ref:extensionality-axiom} indicates $B = C$. - \paragraph{Case 2}% + \paragraph{Case 2}% - Suppose $B = \emptyset$. - Then there is no $\pair{x, y}$ such that $x \in A$ and $y \in B$. - Thus $A \times B = \emptyset$ and $A \times C = \emptyset$. - But then there cannot exist an $\pair{x, y}$ such that $x \in A$ - and $y \in C$ either. - Since $A \neq \emptyset$, it must be the case that $C = \emptyset$. - Thus $B = C$. + Suppose $B = \emptyset$. + Then there is no $\pair{x, y}$ such that $x \in A$ and $y \in B$. + Thus $A \times B = \emptyset$ and $A \times C = \emptyset$. + But then there cannot exist an $\pair{x, y}$ such that $x \in A$ + and $y \in C$ either. + Since $A \neq \emptyset$, it must be the case that $C = \emptyset$. + Thus $B = C$. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.3}}% \hyperlabel{sub:exercise-3.3} -Show that $A \times \bigcup \mathscr{B} = - \bigcup\;\{ A \times X \mid X \in \mathscr{B} \}$. + Show that $A \times \bigcup \mathscr{B} = + \bigcup\;\{ A \times X \mid X \in \mathscr{B} \}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_3} - Let $A$ and $\mathscr{B}$ be arbitrary sets. - By \nameref{sub:corollary-3c} and the definition of the union of sets, - \begin{align*} - A \times \bigcup\mathscr{B} - & = \{ \pair{x, y} \mid - x \in A \land y \in \bigcup\mathscr{B} \} \\ - & = \{ \pair{x, y} \mid - x \in A \land (\exists b \in \mathscr{B}), y \in b \} \\ - & = \{ \pair{x, y} \mid - (\exists b \in \mathscr{B}), x \in A \land y \in b \} \\ - & = \bigcup\; \{ A \times X \mid X \in \mathscr{B} \}. - \end{align*} - -\end{proof} + \begin{proof} + Let $A$ and $\mathscr{B}$ be arbitrary sets. + By \nameref{sub:corollary-3c} and the definition of the union of sets, + \begin{align*} + A \times \bigcup\mathscr{B} + & = \{ \pair{x, y} \mid + x \in A \land y \in \bigcup\mathscr{B} \} \\ + & = \{ \pair{x, y} \mid + x \in A \land (\exists b \in \mathscr{B}), y \in b \} \\ + & = \{ \pair{x, y} \mid + (\exists b \in \mathscr{B}), x \in A \land y \in b \} \\ + & = \bigcup\; \{ A \times X \mid X \in \mathscr{B} \}. + \end{align*} + \end{proof} \subsection{\unverified{Exercise 3.4}}% \hyperlabel{sub:exercise-3.4} -Show that there is no set to which every ordered pair belongs. + Show that there is no set to which every ordered pair belongs. -\begin{proof} - - For the sake of contradiction, suppose there exists a set $A$ to which every - ordered pair belongs. - That is, for all sets $x$ and $y$, $\pair{x, y} = \{\{x\}, \{x, y\}\}$ - is a member of $A$. - By the \nameref{ref:union-axiom}, it follows that $\bigcup\bigcup A$ is the - set to which every set belongs. - But \nameref{sub:theorem-2a} shows this is impossible. - Thus our original assumption was wrong; there exists no set to which every - ordered pair belongs. - -\end{proof} + \begin{proof} + For the sake of contradiction, suppose there exists a set $A$ to which every + ordered pair belongs. + That is, for all sets $x$ and $y$, $\pair{x, y} = \{\{x\}, \{x, y\}\}$ + is a member of $A$. + By the \nameref{ref:union-axiom}, it follows that $\bigcup\bigcup A$ is the + set to which every set belongs. + But \nameref{sub:theorem-2a} shows this is impossible. + Thus our original assumption was wrong; there exists no set to which every + ordered pair belongs. + \end{proof} \subsection{\verified{Exercise 3.5a}}% \hyperlabel{sub:exercise-3.5a} -Assume that $A$ and $B$ are given sets, and show that there exists a set $C$ - such that for any $y$, - \begin{equation} - \hyperlabel{sub:exercise-3.5a-eq1} - y \in C \iff y = \{x\} \times B \text{ for some } x \text{ in } A. - \end{equation} -In other words, show that $\{\{x\} \times B \mid x \in A\}$ is a set. + Assume that $A$ and $B$ are given sets, and show that there exists a set $C$ + such that for any $y$, + \begin{equation} + \hyperlabel{sub:exercise-3.5a-eq1} + y \in C \iff y = \{x\} \times B \text{ for some } x \text{ in } A. + \end{equation} + In other words, show that $\{\{x\} \times B \mid x \in A\}$ is a set. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_5a} - Let $a \in A$. - By the \nameref{ref:pairing-axiom}, $\{a\}$ is a set. - By \nameref{sub:corollary-3c}, $\{a\} \times B$ is a set. - Again by the \nameref{ref:pairing-axiom}, $\{\{a\} \times B\}$ is a set. + \begin{proof} + Let $a \in A$. + By the \nameref{ref:pairing-axiom}, $\{a\}$ is a set. + By \nameref{sub:corollary-3c}, $\{a\} \times B$ is a set. + Again by the \nameref{ref:pairing-axiom}, $\{\{a\} \times B\}$ is a set. - Next, by another application of \nameref{sub:corollary-3c}, $A \times B$ - is a set. - By the \nameref{ref:power-set-axiom}, $\powerset{(A \times B)}$ is a set. - Thus, by the \nameref{ref:subset-axioms}, the following is also a set: - $$C = \{ y \in \powerset{(A \times B)} \mid - \exists a \in A, \forall x, \left[ x \in y \iff - \exists b \in B, x = \pair{a, b} \right] \}.$$ - We now show that $C$ satisfies \eqref{sub:exercise-3.5a-eq1}. + Next, by another application of \nameref{sub:corollary-3c}, $A \times B$ + is a set. + By the \nameref{ref:power-set-axiom}, $\powerset{(A \times B)}$ is a set. + Thus, by the \nameref{ref:subset-axioms}, the following is also a set: + $$C = \{ y \in \powerset{(A \times B)} \mid + \exists a \in A, \forall x, \left[ x \in y \iff + \exists b \in B, x = \pair{a, b} \right] \}.$$ + We now show that $C$ satisfies \eqref{sub:exercise-3.5a-eq1}. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $y \in C$. - Then there exists some $a \in A$ such that - $$\forall x, \left[ x \in y \iff - \exists b \in B, x = \pair{a, b} \right].$$ - By the \nameref{ref:extensionality-axiom}, - \begin{align*} - y - & = \{ \pair{a, b} \mid b \in B \} \\ - & = \{ \pair{x, b} \mid x \in \{a\} \land b \in B \} \\ - & = \{ \{a\} \times B \}. - \end{align*} + Suppose $y \in C$. + Then there exists some $a \in A$ such that + $$\forall x, \left[ x \in y \iff + \exists b \in B, x = \pair{a, b} \right].$$ + By the \nameref{ref:extensionality-axiom}, + \begin{align*} + y + & = \{ \pair{a, b} \mid b \in B \} \\ + & = \{ \pair{x, b} \mid x \in \{a\} \land b \in B \} \\ + & = \{ \{a\} \times B \}. + \end{align*} - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $y = \{a\} \times B$ for some $a \in A$. - By \nameref{sub:corollary-3c}, $x \in \{a\} \times B$ if and only if - $\exists b \in B$ such that $x = \pair{a, b}$. - But then $x \in y$ if and only if $\exists b \in B$ such that - $x = \pair{a, b}$. - This immediately proves $y \in C$. + Suppose $y = \{a\} \times B$ for some $a \in A$. + By \nameref{sub:corollary-3c}, $x \in \{a\} \times B$ if and only if + $\exists b \in B$ such that $x = \pair{a, b}$. + But then $x \in y$ if and only if $\exists b \in B$ such that + $x = \pair{a, b}$. + This immediately proves $y \in C$. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.5b}}% \hyperlabel{sub:exercise-3.5b} -With $A$, $B$, and $C$ as above, show that $A \times B = \bigcup C$. + With $A$, $B$, and $C$ as above, show that $A \times B = \bigcup C$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_5b} - Let $A$ and $B$ be arbitrary sets. - We want to show that - \begin{equation} - \hyperlabel{sub:exercise-3.5b-eq1} - A \times B = \bigcup\; \{\{x\} \times B \mid x \in A\}. - \end{equation} - The left-hand side of \eqref{sub:exercise-3.5b-eq1} is a set by virtue of - \nameref{sub:corollary-3c}. - The right-hand side of \eqref{sub:exercise-3.5b-eq1} is a set by virtue of - \nameref{sub:exercise-3.5a}. - We prove the set on each side is a subset of the other. + \begin{proof} + Let $A$ and $B$ be arbitrary sets. + We want to show that + \begin{equation} + \hyperlabel{sub:exercise-3.5b-eq1} + A \times B = \bigcup\; \{\{x\} \times B \mid x \in A\}. + \end{equation} + The left-hand side of \eqref{sub:exercise-3.5b-eq1} is a set by virtue of + \nameref{sub:corollary-3c}. + The right-hand side of \eqref{sub:exercise-3.5b-eq1} is a set by virtue of + \nameref{sub:exercise-3.5a}. + We prove the set on each side is a subset of the other. - \paragraph{($\subseteq$)}% + \paragraph{($\subseteq$)}% - Let $c \in A \times B$. - Then there exists some $a \in A$ and $b \in B$ such that $c = \pair{a, b}$. - Thus $c \in \{a\} \times B$. - We also note $\{a\} \times B \in \{\{x\} \times B \mid x \in A\}$, - specifically when $x = a$. - Therefore, by the \nameref{ref:union-axiom}, - $c \in \bigcup\;\{\{x\} \times B \mid x \in A\}$. + Let $c \in A \times B$. + Then there exists some $a \in A$ and $b \in B$ such that + $c = \pair{a, b}$. + Thus $c \in \{a\} \times B$. + We also note $\{a\} \times B \in \{\{x\} \times B \mid x \in A\}$, + specifically when $x = a$. + Therefore, by the \nameref{ref:union-axiom}, + $c \in \bigcup\;\{\{x\} \times B \mid x \in A\}$. - \paragraph{($\supseteq$)}% + \paragraph{($\supseteq$)}% - Let $c \in \bigcup\; \{\{x\} \times B \mid x \in A\}$. - By the \nameref{ref:union-axiom}, there exists some - $b \in \{\{x\} \times B \mid x \in A\}$ such that $c \in b$. - Then there exists some $x \in A$ such that $b = \{x\} \times B$. - Therefore $c \in \{x\} \times B$. - But $x \in A$ meaning $c \in A \times B$ as well. + Let $c \in \bigcup\; \{\{x\} \times B \mid x \in A\}$. + By the \nameref{ref:union-axiom}, there exists some + $b \in \{\{x\} \times B \mid x \in A\}$ such that $c \in b$. + Then there exists some $x \in A$ such that $b = \{x\} \times B$. + Therefore $c \in \{x\} \times B$. + But $x \in A$ meaning $c \in A \times B$ as well. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - Since we have shown - $A \times B \subseteq \bigcup\; \{\{x\} \times B \mid x \in A\}$ and - $A \times B \supseteq \bigcup\; \{\{x\} \times B \mid x \in A\}$, it - follows \eqref{sub:exercise-3.5b-eq1} is a true identity. + Since we have shown + $A \times B \subseteq \bigcup\; \{\{x\} \times B \mid x \in A\}$ and + $A \times B \supseteq \bigcup\; \{\{x\} \times B \mid x \in A\}$, it + follows \eqref{sub:exercise-3.5b-eq1} is a true identity. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.6}}% \hyperlabel{sub:exercise-3.6} -Show that a set $A$ is a relation iff $A \subseteq \dom{A} \times \ran{A}$. + Show that a set $A$ is a relation iff $A \subseteq \dom{A} \times \ran{A}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_6} - Let $A$ be a set. - We prove the forward and reverse direction of the bidirectional. + \begin{proof} + Let $A$ be a set. + We prove the forward and reverse direction of the bidirectional. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $A$ is a \nameref{ref:relation}. - We show for all $a \in A$, $a \in \dom{A} \times \ran{A}$. - Let $a \in A$. - Since $A$ is a relation, $a$ is an ordered pair. - Then there exists some sets $x$ and $y$ such that $a = \pair{x, y}$. - By the definition of the \nameref{ref:domain} and \nameref{ref:range} of - $A$, $x \in \dom{A}$ and $y \in \ran{A}$. - Thus $a = \pair{x, y} \in \dom{A} \times \ran{A}$ as well. - This proves $A \subseteq \dom{A} \times \ran{A}$. + Suppose $A$ is a \nameref{ref:relation}. + We show for all $a \in A$, $a \in \dom{A} \times \ran{A}$. + Let $a \in A$. + Since $A$ is a relation, $a$ is an ordered pair. + Then there exists some sets $x$ and $y$ such that $a = \pair{x, y}$. + By the definition of the \nameref{ref:domain} and \nameref{ref:range} of + $A$, $x \in \dom{A}$ and $y \in \ran{A}$. + Thus $a = \pair{x, y} \in \dom{A} \times \ran{A}$ as well. + This proves $A \subseteq \dom{A} \times \ran{A}$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $A \subseteq \dom{A} \times \ran{A}$. - Then for all $a \in A$, $a \in \dom{A} \times \ran{A}$. - Therefore $a$ is an ordered pair. - Since this holds for all $a \in A$, it follows $A$ is a relation. + Suppose $A \subseteq \dom{A} \times \ran{A}$. + Then for all $a \in A$, $a \in \dom{A} \times \ran{A}$. + Therefore $a$ is an ordered pair. + Since this holds for all $a \in A$, it follows $A$ is a relation. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.7}}% \hyperlabel{sub:exercise-3.7} -Show that if $R$ is a relation, then $\fld{R} = \bigcup\bigcup R$. + Show that if $R$ is a relation, then $\fld{R} = \bigcup\bigcup R$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_7} - Let $R$ be a \nameref{ref:relation}. - We show that (i) $\fld{R} \subseteq \bigcup\bigcup R$ and (ii) that - $\bigcup\bigcup R \subseteq \fld{R}$. + \begin{proof} + Let $R$ be a \nameref{ref:relation}. + We show that (i) $\fld{R} \subseteq \bigcup\bigcup R$ and (ii) that + $\bigcup\bigcup R \subseteq \fld{R}$. - \paragraph{(i)}% - \hyperlabel{par:exercise-3.7-i} + \paragraph{(i)}% + \hyperlabel{par:exercise-3.7-i} - Let $x \in \fld{R} = \dom{R} \cup \ran{R}$. - That is, $x \in \dom{R}$ or $x \in \ran{R}$. + Let $x \in \fld{R} = \dom{R} \cup \ran{R}$. + That is, $x \in \dom{R}$ or $x \in \ran{R}$. - If $x \in \dom{R}$, then there exists some $y$ such that - $\pair{x, y} = \{\{x\}, \{x, y\}\} \in R$. - Then $\{x\} \in \bigcup R$ and $x \in \bigcup\bigcup R$. + If $x \in \dom{R}$, then there exists some $y$ such that + $\pair{x, y} = \{\{x\}, \{x, y\}\} \in R$. + Then $\{x\} \in \bigcup R$ and $x \in \bigcup\bigcup R$. - On the other hand, if $x \in \ran{R}$, then there exists some $t$ such that - $\pair{t, x} = \{\{t\}, \{t, x\}\} \in R$. - Then $\{t, x\} \in \bigcup R$ and $x \in \bigcup\bigcup R$. + On the other hand, if $x \in \ran{R}$, then there exists some $t$ such that + $\pair{t, x} = \{\{t\}, \{t, x\}\} \in R$. + Then $\{t, x\} \in \bigcup R$ and $x \in \bigcup\bigcup R$. - \paragraph{(ii)}% - \hyperlabel{par:exercise-3.7-ii} + \paragraph{(ii)}% + \hyperlabel{par:exercise-3.7-ii} - Let $t \in \bigcup\bigcup R$. - Then there exists some member $T \in \bigcup R$ such that $t \in T$. - Likewise there exists some member $T' \in R$ such that $T \in T'$. - By definition of a relation, $T' = \pair{x, y} = \{\{x\}, \{x, y\}\}$ for - some sets $x$ and $y$. - Thus $t = x$ or $t = y$. - By \nameref{sub:exercise-3.6}, $t \in \dom{R}$ or $t \in \ran{R}$. - In other words, $t \in \fld{R}$. + Let $t \in \bigcup\bigcup R$. + Then there exists some member $T \in \bigcup R$ such that $t \in T$. + Likewise there exists some member $T' \in R$ such that $T \in T'$. + By definition of a relation, $T' = \pair{x, y} = \{\{x\}, \{x, y\}\}$ for + some sets $x$ and $y$. + Thus $t = x$ or $t = y$. + By \nameref{sub:exercise-3.6}, $t \in \dom{R}$ or $t \in \ran{R}$. + In other words, $t \in \fld{R}$. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - Since \nameref{par:exercise-3.7-i} and \nameref{par:exercise-3.7-ii} hold, - $\fld{R} = \bigcup\bigcup{R}$. + Since \nameref{par:exercise-3.7-i} and \nameref{par:exercise-3.7-ii} hold, + $\fld{R} = \bigcup\bigcup{R}$. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.8}}% \hyperlabel{sub:exercise-3.8} -Show that for any set $\mathscr{A}$: - \begin{align} - \dom{\bigcup{\mathscr{A}}} - & = \bigcup\;\{ \dom{R} \mid R \in \mathscr{A} \}, - & \hyperlabel{sub:exercise-3.8-eq1} \\ - \ran{\bigcup{\mathscr{A}}} - & = \bigcup\;\{ \ran{R} \mid R \in \mathscr{A} \}. - & \hyperlabel{sub:exercise-3.8-eq2} - \end{align} + Show that for any set $\mathscr{A}$: + \begin{align} + \dom{\bigcup{\mathscr{A}}} + & = \bigcup\;\{ \dom{R} \mid R \in \mathscr{A} \}, + & \hyperlabel{sub:exercise-3.8-eq1} \\ + \ran{\bigcup{\mathscr{A}}} + & = \bigcup\;\{ \ran{R} \mid R \in \mathscr{A} \}. + & \hyperlabel{sub:exercise-3.8-eq2} + \end{align} -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_8\_i} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_8\_ii} - We prove (i) \eqref{sub:exercise-3.8-eq1} and then (ii) - \eqref{sub:exercise-3.8-eq2}. + \begin{proof} + We prove (i) \eqref{sub:exercise-3.8-eq1} and then (ii) + \eqref{sub:exercise-3.8-eq2}. - \paragraph{(i)}% + \paragraph{(i)}% - Let $x \in \dom{\bigcup{\mathscr{A}}}$. - By definition of a domain, there exists some $y$ such that - $\pair{x, y} \in \bigcup{\mathscr{A}}$. - By definition of the union of sets, - $\exists y, \exists R \in \mathscr{A}, \pair{x, y} \in R$. - Equivalently, - $\exists R \in \mathscr{A}, \exists y, \pair{x, y} \in R$. - By another application of the definition of a domain, - $\exists R \in \mathscr{A}, x \in \dom{R}$. - By another application of the definition of the union of sets, - $x \in \bigcup\;\{ \dom{R} \mid R \in \mathscr{A} \}$. - Since membership of these two sets holds biconditionally, it follows - \eqref{sub:exercise-3.8-eq1} holds. + Let $x \in \dom{\bigcup{\mathscr{A}}}$. + By definition of a domain, there exists some $y$ such that + $\pair{x, y} \in \bigcup{\mathscr{A}}$. + By definition of the union of sets, + $\exists y, \exists R \in \mathscr{A}, \pair{x, y} \in R$. + Equivalently, + $\exists R \in \mathscr{A}, \exists y, \pair{x, y} \in R$. + By another application of the definition of a domain, + $\exists R \in \mathscr{A}, x \in \dom{R}$. + By another application of the definition of the union of sets, + $x \in \bigcup\;\{ \dom{R} \mid R \in \mathscr{A} \}$. + Since membership of these two sets holds biconditionally, it follows + \eqref{sub:exercise-3.8-eq1} holds. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $x \in \ran{\bigcup{\mathscr{A}}}$. - By definition of a range, there exists some $t$ such that - $\pair{t, x} \in \bigcup{\mathscr{A}}$. - By definition of the union of sets, - $\exists t, \exists R \in \mathscr{A}, \pair{t, x} \in R$. - Equivalently, - $\exists R \in \mathscr{A}, \exists t, \pair{t, x} \in R$. - By another application of the definition of a range, - $\exists R \in \mathscr{A}, x \in \ran{R}$. - By another application of the definition of the union of sets, - $x \in \bigcup\;\{ \ran{R} \mid R \in \mathscr{A} \}$. - Since membership of these two sets holds biconditionally, it follows - \eqref{sub:exercise-3.8-eq2} holds. + Let $x \in \ran{\bigcup{\mathscr{A}}}$. + By definition of a range, there exists some $t$ such that + $\pair{t, x} \in \bigcup{\mathscr{A}}$. + By definition of the union of sets, + $\exists t, \exists R \in \mathscr{A}, \pair{t, x} \in R$. + Equivalently, + $\exists R \in \mathscr{A}, \exists t, \pair{t, x} \in R$. + By another application of the definition of a range, + $\exists R \in \mathscr{A}, x \in \ran{R}$. + By another application of the definition of the union of sets, + $x \in \bigcup\;\{ \ran{R} \mid R \in \mathscr{A} \}$. + Since membership of these two sets holds biconditionally, it follows + \eqref{sub:exercise-3.8-eq2} holds. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.9}}% \hyperlabel{sub:exercise-3.9} -Discuss the result of replacing the union operation by the intersection - operation in the preceding problem. - -\begin{answer} - - \statementpadding + Discuss the result of replacing the union operation by the intersection + operation in the preceding problem. \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_9\_i} @@ -4282,298 +3891,281 @@ Discuss the result of replacing the union operation by the intersection \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_9\_ii} - Replacing the union operation with the intersection problem produces the - following relationships - \begin{align} - \dom{\bigcap{\mathscr{A}}} - & \subseteq \bigcap\;\{ \dom{R} \mid R \in \mathscr{A} \}, - & \hyperlabel{sub:exercise-3.9-eq1} \\ - \ran{\bigcap{\mathscr{A}}} - & \subseteq \bigcap\;\{ \ran{R} \mid R \in \mathscr{A} \}. - & \hyperlabel{sub:exercise-3.9-eq2} - \end{align} + \begin{answer} + Replacing the union operation with the intersection problem produces the + following relationships + \begin{align} + \dom{\bigcap{\mathscr{A}}} + & \subseteq \bigcap\;\{ \dom{R} \mid R \in \mathscr{A} \}, + & \hyperlabel{sub:exercise-3.9-eq1} \\ + \ran{\bigcap{\mathscr{A}}} + & \subseteq \bigcap\;\{ \ran{R} \mid R \in \mathscr{A} \}. + & \hyperlabel{sub:exercise-3.9-eq2} + \end{align} - We prove (i) \eqref{sub:exercise-3.9-eq1} and then (ii) - \eqref{sub:exercise-3.9-eq2}. + We prove (i) \eqref{sub:exercise-3.9-eq1} and then (ii) + \eqref{sub:exercise-3.9-eq2}. - \paragraph{(i)}% + \paragraph{(i)}% - Let $x \in \dom{\bigcap{\mathscr{A}}}$. - By definition of the \nameref{ref:domain} of a set, - $\exists y, \pair{x, y} \in \bigcap{\mathscr{A}}$. - By definition of the intersection of sets, - $\exists y, \forall R \in \mathscr{A}, \pair{x, y} \in R$. - But this implies that - $\forall R \in \mathscr{A}, \exists y, \pair{x, y} \in R$. - By another application of the definition of the \nameref{ref:domain} of a - set, $\forall R \in \mathscr{A}, x \in \dom{R}$. - By another application of the intersection of sets, - $x \in \bigcap\;\{ \dom{R} \mid R \in \mathscr{A} \}$. - Thus \eqref{sub:exercise-3.9-eq1} holds. + Let $x \in \dom{\bigcap{\mathscr{A}}}$. + By definition of the \nameref{ref:domain} of a set, + $\exists y, \pair{x, y} \in \bigcap{\mathscr{A}}$. + By definition of the intersection of sets, + $\exists y, \forall R \in \mathscr{A}, \pair{x, y} \in R$. + But this implies that + $\forall R \in \mathscr{A}, \exists y, \pair{x, y} \in R$. + By another application of the definition of the \nameref{ref:domain} of a + set, $\forall R \in \mathscr{A}, x \in \dom{R}$. + By another application of the intersection of sets, + $x \in \bigcap\;\{ \dom{R} \mid R \in \mathscr{A} \}$. + Thus \eqref{sub:exercise-3.9-eq1} holds. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $x \in \ran{\bigcap{\mathscr{A}}}$. - By definition of the \nameref{ref:range} of a set, - $\exists t, \pair{t, x} \in \bigcap{\mathscr{A}}$. - By definition of the intersection of sets, - $\exists t, \forall R \in \mathscr{A}, \pair{t, x} \in R$. - But this implies that - $\forall R \in \mathscr{A}, \exists t, \pair{t, x} \in R$. - By another application of the definition of the \nameref{ref:range} of a - set, $\forall R \in \mathscr{A}, x \in \ran{R}$. - By another application of the intersection of sets, - $x \in \bigcap\;\{ \ran{R} \mid R \in \mathscr{A} \}$. - Thus \eqref{sub:exercise-3.9-eq2} holds. + Let $x \in \ran{\bigcap{\mathscr{A}}}$. + By definition of the \nameref{ref:range} of a set, + $\exists t, \pair{t, x} \in \bigcap{\mathscr{A}}$. + By definition of the intersection of sets, + $\exists t, \forall R \in \mathscr{A}, \pair{t, x} \in R$. + But this implies that + $\forall R \in \mathscr{A}, \exists t, \pair{t, x} \in R$. + By another application of the definition of the \nameref{ref:range} of a + set, $\forall R \in \mathscr{A}, x \in \ran{R}$. + By another application of the intersection of sets, + $x \in \bigcap\;\{ \ran{R} \mid R \in \mathscr{A} \}$. + Thus \eqref{sub:exercise-3.9-eq2} holds. -\end{answer} + \end{answer} \subsection{\unverified{Exercise 3.10}}% \hyperlabel{sub:exercise-3.10} -Show that an ordered $4$-tuple is also an ordered $m$-tuple for every positive - integer $m$ less than $4$. + Show that an ordered $4$-tuple is also an ordered $m$-tuple for every positive + integer $m$ less than $4$. -\begin{answer} - - Let $\pair{x_1, x_2, x_3, x_4}$ denote an arbitrary $4$-tuple. - Then - \begin{align} - \pair{x_1, x_2, x_3, x_4} - & = \pair{\pair{x_1, x_2, x_3}, x_4} - & \hyperlabel{sub:exercise-7.10-eq1} \\ - & = \pair{\pair{\pair{x_1, x_2}, x_3}, x_4} - & \hyperlabel{sub:exercise-7.10-eq2} - \end{align} - Here \eqref{sub:exercise-7.10-eq1} is an equivalent ordered $2$-tuple and - \eqref{sub:exercise-7.10-eq2} is an equivalent ordered $3$-tuple. - Furthermore, $\pair{x_1, x_2, x_3, x_4} = \pair{\pair{x_1, x_2, x_3, x_4}}$, - showing it can be represented as an ordered $1$-tuple as well. - -\end{answer} + \begin{answer} + Let $\pair{x_1, x_2, x_3, x_4}$ denote an arbitrary $4$-tuple. + Then + \begin{align} + \pair{x_1, x_2, x_3, x_4} + & = \pair{\pair{x_1, x_2, x_3}, x_4} + & \hyperlabel{sub:exercise-7.10-eq1} \\ + & = \pair{\pair{\pair{x_1, x_2}, x_3}, x_4} + & \hyperlabel{sub:exercise-7.10-eq2} + \end{align} + Here \eqref{sub:exercise-7.10-eq1} is an equivalent ordered $2$-tuple and + \eqref{sub:exercise-7.10-eq2} is an equivalent ordered $3$-tuple. + Furthermore, $\pair{x_1, x_2, x_3, x_4} = \pair{\pair{x_1, x_2, x_3, x_4}}$, + showing it can be represented as an ordered $1$-tuple as well. + \end{answer} \subsection{\pending{Exercise 3.11}}% \hyperlabel{sub:exercise-3.11} -Prove the following version (for functions) of the extensionality principle: - Assume that $F$ and $G$ are functions, $\dom{F} = \dom{G}$, and - $F(x) = G(x)$ for all $x$ in the common domain. -Then $F = G$. + Prove the following version (for functions) of the extensionality principle: + Assume that $F$ and $G$ are functions, $\dom{F} = \dom{G}$, and + $F(x) = G(x)$ for all $x$ in the common domain. + Then $F = G$. -\begin{proof} + \lean*{Init/Core}{funext} - \lean{Init/Core}{funext} - - Let $F$ and $G$ be functions such that $\dom{F} = \dom{G}$ and $F(x) = G(x)$ - for all $x$ in the common domain. - We prove that $\pair{x, y} \in F$ if and only if $\pair{x, y} \in G$. - But this follows immediately: - \begin{align*} - \pair{x, y} \in F - & \iff y = F(x) \land \pair{x, F(x)} \in F \\ - & \iff y = G(x) \land \pair{x, G(x)} \in G \\ - & \iff \pair{x, y} \in G. - \end{align*} - By the \nameref{ref:extensionality-axiom}, $F = G$. - -\end{proof} + \begin{proof} + Let $F$ and $G$ be functions such that $\dom{F} = \dom{G}$ and $F(x) = G(x)$ + for all $x$ in the common domain. + We prove that $\pair{x, y} \in F$ if and only if $\pair{x, y} \in G$. + But this follows immediately: + \begin{align*} + \pair{x, y} \in F + & \iff y = F(x) \land \pair{x, F(x)} \in F \\ + & \iff y = G(x) \land \pair{x, G(x)} \in G \\ + & \iff \pair{x, y} \in G. + \end{align*} + By the \nameref{ref:extensionality-axiom}, $F = G$. + \end{proof} \subsection{\verified{Exercise 3.12}}% \hyperlabel{sub:exercise-3.12} -Assume that $f$ and $g$ are functions and show that - $$f \subseteq g \iff \dom{f} \subseteq \dom{g} \land - (\forall x \in \dom{f}) f(x) = g(x).$$ - -\begin{proof} + Assume that $f$ and $g$ are functions and show that + $$f \subseteq g \iff \dom{f} \subseteq \dom{g} \land + (\forall x \in \dom{f}) f(x) = g(x).$$ \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_12} - Let $f$ and $g$ be \nameref{ref:function}s. + \begin{proof} + Let $f$ and $g$ be \nameref{ref:function}s. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $f \subseteq g$. - Then for all \nameref{ref:ordered-pair}s $\pair{x, y}$, - $\pair{x, y} \in f$ implies $\pair{x, y} \in g$. - Thus every $x \in \dom{f}$ must be a member of $\dom{g}$. - Likewise, by definition of a function, $f$ and $g$ are single-valued. - Thus $f(x) = y$ and $g(x) = y$. - Since $x$ is an arbitrary element in the domain of $f$, it follows - $(\forall x \in \dom{f}) f(x) = y = g(x)$. + Suppose $f \subseteq g$. + Then for all \nameref{ref:ordered-pair}s $\pair{x, y}$, + $\pair{x, y} \in f$ implies $\pair{x, y} \in g$. + Thus every $x \in \dom{f}$ must be a member of $\dom{g}$. + Likewise, by definition of a function, $f$ and $g$ are single-valued. + Thus $f(x) = y$ and $g(x) = y$. + Since $x$ is an arbitrary element in the domain of $f$, it follows + $(\forall x \in \dom{f}) f(x) = y = g(x)$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $\dom{f} \subseteq \dom{g}$ and - $(\forall x \in \dom{f}) f(x) = g(x)$. - Let $\pair{x, y} \in f$. - By hypothesis, $x \in \dom{g}$ and $y = f(x) = g(x)$. - Thus $\pair{x, y} \in g$ as well. - Therefore $f \subseteq g$. + Suppose $\dom{f} \subseteq \dom{g}$ and + $(\forall x \in \dom{f}) f(x) = g(x)$. + Let $\pair{x, y} \in f$. + By hypothesis, $x \in \dom{g}$ and $y = f(x) = g(x)$. + Thus $\pair{x, y} \in g$ as well. + Therefore $f \subseteq g$. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.13}}% \hyperlabel{sub:exercise-3.13} -Assume that $f$ and $g$ are functions with $f \subseteq g$ and - $\dom{g} \subseteq \dom{f}$. -Show that $f = g$. + Assume that $f$ and $g$ are functions with $f \subseteq g$ and + $\dom{g} \subseteq \dom{f}$. + Show that $f = g$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_13} - Let $f$ and $g$ be functions such that $f \subseteq g$ and - $\dom{g} \subseteq \dom{f}$. - By \nameref{sub:exercise-3.12}, it follows that $\dom{f} \subseteq \dom{g}$ - and $(\forall x \in \dom{f}) f(x) = g(x)$. - Since $\dom{g} \subseteq \dom{f}$ and $\dom{f} \subseteq \dom{g}$, it follows - that $\dom{g} = \dom{f}$. - By \nameref{sub:exercise-3.11}, $f = g$. - -\end{proof} + \begin{proof} + Let $f$ and $g$ be functions such that $f \subseteq g$ and + $\dom{g} \subseteq \dom{f}$. + By \nameref{sub:exercise-3.12}, it follows that $\dom{f} \subseteq \dom{g}$ + and $(\forall x \in \dom{f}) f(x) = g(x)$. + Since $\dom{g} \subseteq \dom{f}$ and $\dom{f} \subseteq \dom{g}$, it + follows that $\dom{g} = \dom{f}$. + By \nameref{sub:exercise-3.11}, $f = g$. + \end{proof} \subsection{\verified{Exercise 3.14}}% \hyperlabel{sub:exercise-3.14} -Assume that $f$ and $g$ are functions. + Assume that $f$ and $g$ are functions. + \begin{enumerate}[(a)] + \item Show that $f \cap g$ is a function. + \item Show that $f \cup g$ is a function iff $f(x) = g(x)$ for every $x$ in + $(\dom{f}) \cap (\dom{g})$. + \end{enumerate} -\begin{enumerate}[(a)] - \item Show that $f \cap g$ is a function. - \item Show that $f \cup g$ is a function iff $f(x) = g(x)$ for every $x$ in - $(\dom{f}) \cap (\dom{g})$. -\end{enumerate} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_14\_a} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_14\_b} - Assume $f$ and $g$ are \nameref{ref:function}s. + \begin{proof} + Assume $f$ and $g$ are \nameref{ref:function}s. - \paragraph{(a)}% + \paragraph{(a)}% - Consider $f \cap g$. - By definition of the intersection of sets, $f \cap g \subseteq f$. - Since $f$ is single-valued, it trivially follows that so must $f \cap g$. - Therefore $f \cap g$ is a function. + Consider $f \cap g$. + By definition of the intersection of sets, $f \cap g \subseteq f$. + Since $f$ is single-valued, it trivially follows that so must $f \cap g$. + Therefore $f \cap g$ is a function. - \paragraph{(b)}% + \paragraph{(b)}% - \subparagraph{($\Rightarrow$)}% + \subparagraph{($\Rightarrow$)}% - Suppose $f \cup g$ is a function. - Let $x \in (\dom{f}) \cap (\dom{g})$. - That is, $x \in \dom{f}$ and $x \in \dom{g}$. - Then there exists only one $y_1$ such that $\pair{x, y_1} \in f$. - Likewise there exists only one $y_2$ such that - $\pair{x, y_2} \in g$. - But $\pair{x, y_1} \in f \cup g$ and $\pair{x, y_2} \in f \cup g$. - Since $f \cup g$ is single-valued, it follows $y_1 = y_2$. - That is, $f(x) = g(x)$. + Suppose $f \cup g$ is a function. + Let $x \in (\dom{f}) \cap (\dom{g})$. + That is, $x \in \dom{f}$ and $x \in \dom{g}$. + Then there exists only one $y_1$ such that $\pair{x, y_1} \in f$. + Likewise there exists only one $y_2$ such that + $\pair{x, y_2} \in g$. + But $\pair{x, y_1} \in f \cup g$ and $\pair{x, y_2} \in f \cup g$. + Since $f \cup g$ is single-valued, it follows $y_1 = y_2$. + That is, $f(x) = g(x)$. - \subparagraph{($\Leftarrow$)}% + \subparagraph{($\Leftarrow$)}% - Suppose $f(x) = g(x)$ for every $x \in (\dom{f}) \cap (\dom{g})$. - Let $x \in \dom{(f \cup g)}$. - There are three cases to consider: + Suppose $f(x) = g(x)$ for every $x \in (\dom{f}) \cap (\dom{g})$. + Let $x \in \dom{(f \cup g)}$. + There are three cases to consider: - \begin{enumerate}[(i)] - \item Suppose $x \in \dom{f}$ but not in $\dom{g}$. - Since $f$ is a function, it follows $f \cup g$ has only one value $y$ - such that $\pair{x, y} \in f \cup g$. - \item Suppose $x \in \dom{g}$ but not in $\dom{f}$. - Again, since $g$ is a function, it follows $f \cup g$ has only one - value $y$ such that $\pair{x, y} \in f \cup g$. - \item Suppose $x \in \dom{f}$ and $x \in \dom{g}$. - By hypothesis, $f(x) = g(x)$ meaning there is only one value $y$ such - that $\pair{x, y} \in f \cup g$. - \end{enumerate} + \begin{enumerate}[(i)] + \item Suppose $x \in \dom{f}$ but not in $\dom{g}$. + Since $f$ is a function, it follows $f \cup g$ has only one value $y$ + such that $\pair{x, y} \in f \cup g$. + \item Suppose $x \in \dom{g}$ but not in $\dom{f}$. + Again, since $g$ is a function, it follows $f \cup g$ has only one + value $y$ such that $\pair{x, y} \in f \cup g$. + \item Suppose $x \in \dom{f}$ and $x \in \dom{g}$. + By hypothesis, $f(x) = g(x)$ meaning there is only one value $y$ such + that $\pair{x, y} \in f \cup g$. + \end{enumerate} - The above cases are exhaustive. - Together they imply that $f \cup g$ is single-valued, i.e. a function. + The above cases are exhaustive. + Together they imply that $f \cup g$ is single-valued, i.e. a function. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.15}}% \hyperlabel{sub:exercise-3.15} -Let $\mathscr{A}$ be a set of functions such that for any $f$ and $g$ in - $\mathscr{A}$, either $f \subseteq g$ or $g \subseteq f$. -Show that $\bigcup{\mathscr{A}}$ is a function. + Let $\mathscr{A}$ be a set of functions such that for any $f$ and $g$ in + $\mathscr{A}$, either $f \subseteq g$ or $g \subseteq f$. + Show that $\bigcup{\mathscr{A}}$ is a function. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_15} - Let $\mathscr{A}$ be a set of \nameref{ref:function}s such that for any $f$ - and $g$ in $\mathscr{A}$, either $f \subseteq g$ or $g \subseteq f$. - Let $x \in \dom{\bigcup{\mathscr{A}}}$. - Then there exists some $y_1$ such that - $\pair{x, y_1} \in \bigcup{\mathscr{A}}$. - Suppose there also exists some $y_2$ such that - $\pair{x, y_2} \in \bigcup{\mathscr{A}}$. + \begin{proof} + Let $\mathscr{A}$ be a set of \nameref{ref:function}s such that for any $f$ + and $g$ in $\mathscr{A}$, either $f \subseteq g$ or $g \subseteq f$. + Let $x \in \dom{\bigcup{\mathscr{A}}}$. + Then there exists some $y_1$ such that + $\pair{x, y_1} \in \bigcup{\mathscr{A}}$. + Suppose there also exists some $y_2$ such that + $\pair{x, y_2} \in \bigcup{\mathscr{A}}$. - By definition of the union of sets, there exists some function - $f \in \mathscr{A}$ such that $\pair{x, y_1} \in f$. - Likewise there exists some function $g \in \mathscr{A}$ such that - $\pair{x, y_2} \in g$. - There are two cases to consider: + By definition of the union of sets, there exists some function + $f \in \mathscr{A}$ such that $\pair{x, y_1} \in f$. + Likewise there exists some function $g \in \mathscr{A}$ such that + $\pair{x, y_2} \in g$. + There are two cases to consider: - \paragraph{Case 1}% + \paragraph{Case 1}% - Suppose $f \subseteq g$. - Then $\pair{x, y_1}, \pair{x, y_2} \in g$. - Since $g$ is a function, i.e. single-valued, $y_1 = y_2$. + Suppose $f \subseteq g$. + Then $\pair{x, y_1}, \pair{x, y_2} \in g$. + Since $g$ is a function, i.e. single-valued, $y_1 = y_2$. - \paragraph{Case 2}% + \paragraph{Case 2}% - Suppose $g \subseteq f$. - Then $\pair{x, y_1}, \pair{x, y_2} \in f$. - Since $f$ is a function, i.e. single-valued, $y_1 = y_2$. + Suppose $g \subseteq f$. + Then $\pair{x, y_1}, \pair{x, y_2} \in f$. + Since $f$ is a function, i.e. single-valued, $y_1 = y_2$. - \paragraph{Conclusion}% + \paragraph{Conclusion}% - Since the above two cases applies for all - $x \in \dom{\bigcup{\mathscr{A}}}$ and appropriate choices of $f$ and $g$, - it follows $\bigcup{\mathscr{A}}$ is indeed a function. + Since the above two cases applies for all + $x \in \dom{\bigcup{\mathscr{A}}}$ and appropriate choices of $f$ and $g$, + it follows $\bigcup{\mathscr{A}}$ is indeed a function. -\end{proof} + \end{proof} \subsection{\unverified{Exercise 3.16}}% \hyperlabel{sub:exercise-3.16} -Show that there is no set to which every function belongs. + Show that there is no set to which every function belongs. -\begin{proof} - - Every \nameref{ref:relation} consisting of a single \nameref{ref:ordered-pair} - is, by definition, a \nameref{ref:function}. - By \nameref{sub:exercise-3.4}, there is no set to which every ordered pair - belongs. - Thus there is no set to which every function of the described type belongs - either, let alone a set to which \textit{every} function belongs. - -\end{proof} + \begin{proof} + Every \nameref{ref:relation} consisting of a single + \nameref{ref:ordered-pair} is, by definition, a \nameref{ref:function}. + By \nameref{sub:exercise-3.4}, there is no set to which every ordered pair + belongs. + Thus there is no set to which every function of the described type belongs + either, let alone a set to which \textit{every} function belongs. + \end{proof} \subsection{\verified{Exercise 3.17}}% \hyperlabel{sub:exercise-3.17} -Show that the composition of two single-rooted sets is again single-rooted. -Conclude that the composition of two one-to-one functions is again one-to-one. - -\begin{proof} - - \statementpadding + Show that the composition of two single-rooted sets is again single-rooted. + Conclude that the composition of two one-to-one functions is again one-to-one. \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_17\_i} @@ -4581,1301 +4173,1249 @@ Conclude that the composition of two one-to-one functions is again one-to-one. \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_17\_ii} - Let $F$ and $G$ be two single-rooted sets. - Consider $F \circ G$. - By definition of the \nameref{ref:composition} of sets, - \begin{equation} - \hyperlabel{sub:exercise-3.17-eq1} - F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}. - \end{equation} - Consider any $v \in \ran{(F \circ G)}$. - By definition of the \nameref{ref:range} of a \nameref{ref:relation}, there - exists some $u_1$ such that $\pair{u_1, v} \in F \circ G$. - Let $u_2$ be a set such that $\pair{u_2, v} \in F \circ G$. + \begin{proof} + Let $F$ and $G$ be two single-rooted sets. + Consider $F \circ G$. + By definition of the \nameref{ref:composition} of sets, + \begin{equation} + \hyperlabel{sub:exercise-3.17-eq1} + F \circ G = \{\pair{u, v} \mid \exists t(uGt \land tFv)\}. + \end{equation} + Consider any $v \in \ran{(F \circ G)}$. + By definition of the \nameref{ref:range} of a \nameref{ref:relation}, there + exists some $u_1$ such that $\pair{u_1, v} \in F \circ G$. + Let $u_2$ be a set such that $\pair{u_2, v} \in F \circ G$. - By \eqref{sub:exercise-3.17-eq1}, there exists a set $t_1$ such that - $\pair{u_1, t_1} \in G$ and $\pair{t_1, v} \in F$. - Likewise, there exists a set $t_2$ such that - $\pair{u_2, t_2} \in G$ and $\pair{t_2, v} \in F$. - But $F$ is single-rooted, meaning $t_1 = t_2$. - Likewise, because $G$ is single-rooted, $u_1 = u_2$. - Thus $F \circ G$ must also be single-rooted. + By \eqref{sub:exercise-3.17-eq1}, there exists a set $t_1$ such that + $\pair{u_1, t_1} \in G$ and $\pair{t_1, v} \in F$. + Likewise, there exists a set $t_2$ such that + $\pair{u_2, t_2} \in G$ and $\pair{t_2, v} \in F$. + But $F$ is single-rooted, meaning $t_1 = t_2$. + Likewise, because $G$ is single-rooted, $u_1 = u_2$. + Thus $F \circ G$ must also be single-rooted. - \suitdivider + \suitdivider - Let $f$ and $g$ be one-to-one functions. - By \nameref{sub:theorem-3h}, $f \circ g$ is single-valued. - By the above, $f \circ g$ is single-rooted. - Thus $f \circ g$ is one-to-one. - -\end{proof} + Let $f$ and $g$ be one-to-one functions. + By \nameref{sub:theorem-3h}, $f \circ g$ is single-valued. + By the above, $f \circ g$ is single-rooted. + Thus $f \circ g$ is one-to-one. + \end{proof} \subsection{\verified{Exercise 3.18}}% \hyperlabel{sub:exercise-3.18} -Let $R$ be the set - $$\{ \pair{0, 1}, \pair{0, 2}, \pair{0, 3}, - \pair{1, 2}, \pair{1, 3}, \pair{2, 3}\}.$$ -Evaluate the following: $R \circ R$, $R \restriction \{1\}$, - $R^{-1} \restriction \{1\}$, $\img{R}{\{1\}}$, and $\img{R^{-1}}{\{1\}}$. - -\begin{proof} - - \statementpadding + Let $R$ be the set + $$\{ \pair{0, 1}, \pair{0, 2}, \pair{0, 3}, + \pair{1, 2}, \pair{1, 3}, \pair{2, 3}\}.$$ + Evaluate the following: $R \circ R$, $R \restriction \{1\}$, + $R^{-1} \restriction \{1\}$, $\img{R}{\{1\}}$, and $\img{R^{-1}}{\{1\}}$. \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_18\_i} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_18\_ii} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_18\_iii} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_18\_iv} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_18\_v} - \begin{enumerate}[(i)] - \item $R \circ R = \{ \pair{0, 2}, \pair{0, 3}, \pair{1, 3} \}$. - \item $R \restriction \{1\} = \{ \pair{1, 2}, \pair{1, 3} \}$. - \item $R^{-1} \restriction \{1\} = \{\pair{1, 0}\}$. - \item $\img{R}{\{1\}} = \{2, 3\}$. - \item $\img{R^{-1}}{\{1\}} = \{0\}$. - \end{enumerate} - -\end{proof} + \begin{proof} + \begin{enumerate}[(i)] + \item $R \circ R = \{ \pair{0, 2}, \pair{0, 3}, \pair{1, 3} \}$. + \item $R \restriction \{1\} = \{ \pair{1, 2}, \pair{1, 3} \}$. + \item $R^{-1} \restriction \{1\} = \{\pair{1, 0}\}$. + \item $\img{R}{\{1\}} = \{2, 3\}$. + \item $\img{R^{-1}}{\{1\}} = \{0\}$. + \end{enumerate} + \end{proof} \subsection{\verified{Exercise 3.19}}% \hyperlabel{sub:exercise-3.19} -Let $$A = \{ - \pair{\emptyset, \{\emptyset, \{\emptyset\}\}}, - \pair{\{\emptyset\}, \emptyset} - \}.$$ -Evaluate each of the following: $A(\emptyset)$, $\img{A}{\emptyset}$, - $\img{A}{\{\emptyset\}}$, $\img{A}{\{\emptyset, \{\emptyset\}\}}$, - $A^{-1}$, $A \circ A$, $A \restriction \emptyset$, - $A \restriction \{\emptyset\}$, $A \restriction \{\emptyset, \{\emptyset\}\}$, - $\bigcup\bigcup A$. + Let $$A = \{ + \pair{\emptyset, \{\emptyset, \{\emptyset\}\}}, + \pair{\{\emptyset\}, \emptyset} + \}.$$ + Evaluate each of the following: $A(\emptyset)$, $\img{A}{\emptyset}$, + $\img{A}{\{\emptyset\}}$, $\img{A}{\{\emptyset, \{\emptyset\}\}}$, + $A^{-1}$, $A \circ A$, $A \restriction \emptyset$, + $A \restriction \{\emptyset\}$, + $A \restriction \{\emptyset, \{\emptyset\}\}$, + $\bigcup\bigcup A$. -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_i} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_ii} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_iii} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_iv} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_v} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_vi} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_vii} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_viii} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_ix} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_19\_x} - \begin{enumerate}[(i)] - \item $A(\emptyset) = \{\emptyset, \{\emptyset\}\}$. - \item $\img{A}{\emptyset} = \emptyset$. - \item $\img{A}{\{\emptyset\}} = \{\{\emptyset, \{\emptyset\}\}\}$. - \item $\img{A}{\{\emptyset, \{\emptyset\}\}} = - \{\{\emptyset, \{\emptyset\}\}, \emptyset\}$. - \item $A^{-1} = \{ - \pair{\{\emptyset, \{\emptyset\}\}, \emptyset}, - \pair{\emptyset, \{\emptyset\}} - \}$. - \item $A \circ A = - \{\pair{\{\emptyset\}, \{\emptyset, \{\emptyset\}\}}\}$. - \item $A \restriction \emptyset = \emptyset$ - \item $A \restriction \{\emptyset\} = - \{\pair{\emptyset, \{\emptyset, \{\emptyset\}\}}\}$. - \item $A \restriction \{\emptyset, \{\emptyset\}\} = A$. - \item $\bigcup\bigcup A = - \{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}$. - \end{enumerate} - -\end{proof} + \begin{proof} + \begin{enumerate}[(i)] + \item $A(\emptyset) = \{\emptyset, \{\emptyset\}\}$. + \item $\img{A}{\emptyset} = \emptyset$. + \item $\img{A}{\{\emptyset\}} = \{\{\emptyset, \{\emptyset\}\}\}$. + \item $\img{A}{\{\emptyset, \{\emptyset\}\}} = + \{\{\emptyset, \{\emptyset\}\}, \emptyset\}$. + \item $A^{-1} = \{ + \pair{\{\emptyset, \{\emptyset\}\}, \emptyset}, + \pair{\emptyset, \{\emptyset\}} + \}$. + \item $A \circ A = + \{\pair{\{\emptyset\}, \{\emptyset, \{\emptyset\}\}}\}$. + \item $A \restriction \emptyset = \emptyset$ + \item $A \restriction \{\emptyset\} = + \{\pair{\emptyset, \{\emptyset, \{\emptyset\}\}}\}$. + \item $A \restriction \{\emptyset, \{\emptyset\}\} = A$. + \item $\bigcup\bigcup A = + \{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}$. + \end{enumerate} + \end{proof} \subsection{\verified{Exercise 3.20}}% \hyperlabel{sub:exercise-3.20} -Show that $F \restriction A = F \cap (A \times \ran{F})$. + Show that $F \restriction A = F \cap (A \times \ran{F})$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_20} - Let $F$ and $A$ be arbitrary sets. - By \nameref{sub:corollary-3c} and definition of the \nameref{ref:restriction}, - intersection, and \nameref{ref:range} of sets, - \begin{align*} - F \restriction A - & = \{\pair{u, v} \mid uFv \land u \in A\} \\ - & = \{\pair{u, v} \mid - uFv \land u \in A \land v \in \ran{F}\} \\ - & = \{\pair{u, v} \mid uFv\} \cap - \{\pair{u, v} \mid u \in A \land v \in \ran{F}\} \\ - & = F \cap \{\pair{u, v} \mid u \in A \land v \in \ran{F}\} \\ - & = F \cap (A \times \ran{F}). - \end{align*} - -\end{proof} + \begin{proof} + Let $F$ and $A$ be arbitrary sets. + By \nameref{sub:corollary-3c} and definition of the + \nameref{ref:restriction}, intersection, and \nameref{ref:range} of sets, + \begin{align*} + F \restriction A + & = \{\pair{u, v} \mid uFv \land u \in A\} \\ + & = \{\pair{u, v} \mid + uFv \land u \in A \land v \in \ran{F}\} \\ + & = \{\pair{u, v} \mid uFv\} \cap + \{\pair{u, v} \mid u \in A \land v \in \ran{F}\} \\ + & = F \cap \{\pair{u, v} \mid u \in A \land v \in \ran{F}\} \\ + & = F \cap (A \times \ran{F}). + \end{align*} + \end{proof} \subsection{\verified{Exercise 3.21}}% \hyperlabel{sub:exercise-3.21} -Show that $(R \circ S) \circ T = R \circ (S \circ T)$. + Show that $(R \circ S) \circ T = R \circ (S \circ T)$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Relation} + \code*{Bookshelf/Enderton/Set/Relation} {Set.Relation.comp\_assoc} - Let $R$, $S$, and $T$ be arbitrary sets. - By definition of the \nameref{ref:composition} of sets, - \begin{align*} - (R \circ S) \circ T - & = \{\pair{u, v} \mid - \exists t(uTt \land t(R \circ S)v)\} \\ - & = \{\pair{u, v} \mid - \exists t(uTt \land (\exists a(tSa \land aRv))\} \\ - & = \{\pair{u, v} \mid - \exists t, \exists a, (uTt \land tSa) \land aRv)\} \\ - & = \{\pair{u, v} \mid - \exists a, \exists t, (uTt \land tSa) \land aRv)\} \\ - & = \{\pair{u, v} \mid - \exists a, (\exists t(uTt \land tSa)) \land aRv)\} \\ - & = \{\pair{u, v} \mid - \exists a, u(S \circ T)a \land aRv)\} \\ - & = R \circ (S \circ T). - \end{align*} - -\end{proof} + \begin{proof} + Let $R$, $S$, and $T$ be arbitrary sets. + By definition of the \nameref{ref:composition} of sets, + \begin{align*} + (R \circ S) \circ T + & = \{\pair{u, v} \mid + \exists t(uTt \land t(R \circ S)v)\} \\ + & = \{\pair{u, v} \mid + \exists t(uTt \land (\exists a(tSa \land aRv))\} \\ + & = \{\pair{u, v} \mid + \exists t, \exists a, (uTt \land tSa) \land aRv)\} \\ + & = \{\pair{u, v} \mid + \exists a, \exists t, (uTt \land tSa) \land aRv)\} \\ + & = \{\pair{u, v} \mid + \exists a, (\exists t(uTt \land tSa)) \land aRv)\} \\ + & = \{\pair{u, v} \mid + \exists a, u(S \circ T)a \land aRv)\} \\ + & = R \circ (S \circ T). + \end{align*} + \end{proof} \subsection{\verified{Exercise 3.22}}% \hyperlabel{sub:exercise-3.22} -Show that the following are correct for any sets. + Show that the following are correct for any sets. + \begin{enumerate}[(a)] + \item $A \subseteq B \Rightarrow \img{F}{A} \subseteq \img{F}{B}$. + \item $\img{(F \circ G)}{A} = \img{F}{\img{G}{A}}$. + \item $Q \restriction (A \cup B) = + (Q \restriction A) \cup (Q \restriction B)$. + \end{enumerate} -\begin{enumerate}[(a)] - \item $A \subseteq B \Rightarrow \img{F}{A} \subseteq \img{F}{B}$. - \item $\img{(F \circ G)}{A} = \img{F}{\img{G}{A}}$. - \item $Q \restriction (A \cup B) = - (Q \restriction A) \cup (Q \restriction B)$. -\end{enumerate} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_22\_a} - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_22\_b} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_22\_c} - Let $A$, $B$, $F$, $G$, and $Q$ be arbitrary sets. + \begin{proof} + Let $A$, $B$, $F$, $G$, and $Q$ be arbitrary sets. - \paragraph{(a)}% + \paragraph{(a)}% - Suppose $A \subseteq B$. - Let $x \in \img{F}{A}$. - By definition of the \nameref{ref:image} of a set, - $\img{F}{A} = \{v \mid (\exists u \in A) uFv\}$. - Thus there exists some $u \in A$ such that $uFx$. - But $A \subseteq B$ meaning $u \in B$. - That is, $(\exists u \in B)uFx$. - Thus $$x \in \{v \mid (\exists u \in B)uFv\} = \img{F}{B}.$$ + Suppose $A \subseteq B$. + Let $x \in \img{F}{A}$. + By definition of the \nameref{ref:image} of a set, + $\img{F}{A} = \{v \mid (\exists u \in A) uFv\}$. + Thus there exists some $u \in A$ such that $uFx$. + But $A \subseteq B$ meaning $u \in B$. + That is, $(\exists u \in B)uFx$. + Thus $$x \in \{v \mid (\exists u \in B)uFv\} = \img{F}{B}.$$ - \paragraph{(b)}% + \paragraph{(b)}% - By definition of the \nameref{ref:composition} and \nameref{ref:image} of a - set, - \begin{align*} - \img{(F \circ G)}{A} - & = \{v \mid (\exists u \in A) u(F \circ G)v\} \\ - & = \{v \mid (\exists u \in A) \pair{u, v} \in F \circ G\} \\ - & = \{v \mid (\exists u \in A) - \pair{u, v} \in \{\pair{b, c} \mid - \exists a(bGa \land aFc)\}\} \\ - & = \{v \mid \exists u \in A, \exists a, uGa \land aFv\} \\ - & = \{v \mid \exists a, \exists u \in A, uGa \land aFv\} \\ - & = \{v \mid \exists a, (\exists u \in A, uGa) \land aFv\} \\ - & = \{v \mid \exists a \in \{w \mid (\exists u \in A)uGw\}, aFv\} \\ - & = \{v \mid (\exists a \in \img{G}{A}) aFv\} \\ - & = \img{F}{\img{G}{A}}. - \end{align*} + By definition of the \nameref{ref:composition} and \nameref{ref:image} of a + set, + \begin{align*} + \img{(F \circ G)}{A} + & = \{v \mid (\exists u \in A) u(F \circ G)v\} \\ + & = \{v \mid (\exists u \in A) \pair{u, v} \in F \circ G\} \\ + & = \{v \mid (\exists u \in A) + \pair{u, v} \in \{\pair{b, c} \mid + \exists a(bGa \land aFc)\}\} \\ + & = \{v \mid \exists u \in A, \exists a, uGa \land aFv\} \\ + & = \{v \mid \exists a, \exists u \in A, uGa \land aFv\} \\ + & = \{v \mid \exists a, (\exists u \in A, uGa) \land aFv\} \\ + & = \{v \mid \exists a \in \{w \mid (\exists u \in A)uGw\}, aFv\} \\ + & = \{v \mid (\exists a \in \img{G}{A}) aFv\} \\ + & = \img{F}{\img{G}{A}}. + \end{align*} - \paragraph{(c)}% + \paragraph{(c)}% - By definition of the \nameref{ref:restriction} of a set, - \begin{align*} - Q \restriction (A \cup B) - & = \{\pair{u, v} \mid uQv \land u \in A \cup B\} \\ - & = \{\pair{u, v} \mid uQv \land (u \in A \lor u \in B)\} \\ - & = \{\pair{u, v} \mid - (uQv \land u \in A) \lor (uQv \land u \in B)\} \\ - & = \{\pair{u, v} \mid uQv \land u \in A\} \cup - \{\pair{u, v} \mid uQv \land u \in B\} \\ - & = (Q \restriction A) \cup (Q \restriction B). - \end{align*} + By definition of the \nameref{ref:restriction} of a set, + \begin{align*} + Q \restriction (A \cup B) + & = \{\pair{u, v} \mid uQv \land u \in A \cup B\} \\ + & = \{\pair{u, v} \mid uQv \land (u \in A \lor u \in B)\} \\ + & = \{\pair{u, v} \mid + (uQv \land u \in A) \lor (uQv \land u \in B)\} \\ + & = \{\pair{u, v} \mid uQv \land u \in A\} \cup + \{\pair{u, v} \mid uQv \land u \in B\} \\ + & = (Q \restriction A) \cup (Q \restriction B). + \end{align*} -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.23}}% \hyperlabel{sub:exercise-3.23} -Let $I_A$ be the identity function on the set $A$. -Show that for any sets $B$ and $C$, - $$B \circ I_A = B \restriction A \quad\text{and}\quad - \img{I_A}{C} = A \cap C.$$ + Let $I_A$ be the identity function on the set $A$. + Show that for any sets $B$ and $C$, + $$B \circ I_A = B \restriction A \quad\text{and}\quad + \img{I_A}{C} = A \cap C.$$ -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_23\_i} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_23\_ii} - Let $I_A$ be the identity function on the set $A$. - That is, $I_A = \{\pair{u, u} \mid u \in A\}$. - Let $B$ and $C$ be any sets. - We show that (i) $B \circ I_A = B \restriction A$ and (ii) - $\img{I_A}{C} = A \cap C$. + \begin{proof} + Let $I_A$ be the identity function on the set $A$. + That is, $I_A = \{\pair{u, u} \mid u \in A\}$. + Let $B$ and $C$ be any sets. + We show that (i) $B \circ I_A = B \restriction A$ and (ii) + $\img{I_A}{C} = A \cap C$. - \paragraph{(i)}% + \paragraph{(i)}% - We show that $B \circ I_A \subseteq B \restriction A$ and - $B \restriction A \subseteq B \circ I_A$. + We show that $B \circ I_A \subseteq B \restriction A$ and + $B \restriction A \subseteq B \circ I_A$. - \subparagraph{($\subseteq$)}% + \subparagraph{($\subseteq$)}% - Let $\pair{x, y} \in B \circ I_A$. - By definition of the \nameref{ref:composition} of sets, - there exists some $t$ such that $x(I_A)t$ and $tBy$. - By definition of the identity function, $I_A(x) = t$ implies $x = t$. - Thus $xBy$. - By hypothesis, $x \in \dom{(B \circ I_A)}$. - Therefore $x \in \dom{I_A} = A$. - Thus $$\pair{x, y} \in \{\pair{u, v} \mid u \in A \land uBv\} - = B \restriction A.$$ + Let $\pair{x, y} \in B \circ I_A$. + By definition of the \nameref{ref:composition} of sets, + there exists some $t$ such that $x(I_A)t$ and $tBy$. + By definition of the identity function, $I_A(x) = t$ implies $x = t$. + Thus $xBy$. + By hypothesis, $x \in \dom{(B \circ I_A)}$. + Therefore $x \in \dom{I_A} = A$. + Thus $$\pair{x, y} \in \{\pair{u, v} \mid u \in A \land uBv\} + = B \restriction A.$$ - \subparagraph{($\supseteq$)}% + \subparagraph{($\supseteq$)}% - Let $\pair{x, y} \in B \restriction A$. - By definition of the \nameref{ref:restriction} of sets, - $x \in A$ and $xBy$. - But $I_A(x) = x$ meaning $\pair{I_A(x), y} \in B$. - In other words, $\pair{x, y} \in B \circ I_A$. + Let $\pair{x, y} \in B \restriction A$. + By definition of the \nameref{ref:restriction} of sets, + $x \in A$ and $xBy$. + But $I_A(x) = x$ meaning $\pair{I_A(x), y} \in B$. + In other words, $\pair{x, y} \in B \circ I_A$. - \paragraph{(ii)}% + \paragraph{(ii)}% - By definition of the \nameref{ref:image} of sets, - \begin{align*} - \img{I_A}{C} - & = \{v \mid (\exists u \in C) \pair{u, v} \in I_A\} \\ - & = \{v \mid \exists u \in C, u \in A \land u = v\} \\ - & = \{v \mid v \in C \land v \in A\} \\ - & = C \cap A. - \end{align*} + By definition of the \nameref{ref:image} of sets, + \begin{align*} + \img{I_A}{C} + & = \{v \mid (\exists u \in C) \pair{u, v} \in I_A\} \\ + & = \{v \mid \exists u \in C, u \in A \land u = v\} \\ + & = \{v \mid v \in C \land v \in A\} \\ + & = C \cap A. + \end{align*} -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.24}}% \hyperlabel{sub:exercise-3.24} -Show that for a function $F$, - $\img{F^{-1}}{A} = \{x \in \dom{F} \mid F(x) \in A\}$. + Show that for a function $F$, + $\img{F^{-1}}{A} = \{x \in \dom{F} \mid F(x) \in A\}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_24} - Let $F$ be a function. - By definition of the \nameref{ref:inverse} of a set, - \begin{align*} - \img{F^{-1}}{A} - & = \{x \mid (\exists y \in A) yF^{-1}x\} \\ - & = \{x \mid (\exists y \in A) xFy\} \\ - & = \{x \mid (\exists y \in A) \pair{x, y} \in F\} \\ - & = \{x \mid x \in \dom{F} \land F(x) \in A\} \\ - & = \{x \in \dom{F} \mid F(x) \in A\}. - \end{align*} - -\end{proof} + \begin{proof} + Let $F$ be a function. + By definition of the \nameref{ref:inverse} of a set, + \begin{align*} + \img{F^{-1}}{A} + & = \{x \mid (\exists y \in A) yF^{-1}x\} \\ + & = \{x \mid (\exists y \in A) xFy\} \\ + & = \{x \mid (\exists y \in A) \pair{x, y} \in F\} \\ + & = \{x \mid x \in \dom{F} \land F(x) \in A\} \\ + & = \{x \in \dom{F} \mid F(x) \in A\}. + \end{align*} + \end{proof} \subsection{\verified{Exercise 3.25}}% \hyperlabel{sub:exercise-3.25} -\begin{enumerate}[(a)] - \item Assume that $G$ is a one-to-one function. - Show that $G \circ G^{-1}$ is $I_{\ran{G}}$, the identity function on - $\ran{G}$. - \item Show that the result of part (a) holds for any function $G$, not - necessarily one-to-one. -\end{enumerate} + \begin{enumerate}[(a)] + \item Assume that $G$ is a one-to-one function. + Show that $G \circ G^{-1}$ is $I_{\ran{G}}$, the identity function on + $\ran{G}$. + \item Show that the result of part (a) holds for any function $G$, not + necessarily one-to-one. + \end{enumerate} -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_25\_b} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_25\_a} - \paragraph{(b)}% - \hyperlabel{par:exercise-3.25-b} + \begin{proof} - Let $G$ be an arbitrary function. - We show that $G \circ G^{-1} \subseteq I_{\ran{G}}$ and that - $I_{\ran{G}} \subseteq G \circ G^{-1}$. + \paragraph{(b)}% + \hyperlabel{par:exercise-3.25-b} - \subparagraph{($\subseteq$)}% + Let $G$ be an arbitrary function. + We show that $G \circ G^{-1} \subseteq I_{\ran{G}}$ and that + $I_{\ran{G}} \subseteq G \circ G^{-1}$. - Let $\pair{x, y} \in G \circ G^{-1}$. - By definition of the \nameref{ref:composition} of sets, there exists some - set $t$ such that $x(G^{-1})t$ and $tGy$. - By definition of the \nameref{ref:inverse} of a set, - $$x(G^{-1})t \iff tGx.$$ - The right hand side of the above biconditional indicates $x \in \ran{G}$. - Since $G$ is single-valued, $tGy \land tGx$ implies $x = y$. - Thus $\pair{x, y} \in I_{\ran{G}}$. + \subparagraph{($\subseteq$)}% - \subparagraph{($\supseteq$)}% + Let $\pair{x, y} \in G \circ G^{-1}$. + By definition of the \nameref{ref:composition} of sets, there exists some + set $t$ such that $x(G^{-1})t$ and $tGy$. + By definition of the \nameref{ref:inverse} of a set, + $$x(G^{-1})t \iff tGx.$$ + The right hand side of the above biconditional indicates $x \in \ran{G}$. + Since $G$ is single-valued, $tGy \land tGx$ implies $x = y$. + Thus $\pair{x, y} \in I_{\ran{G}}$. - Let $\pair{x, x} \in I_{\ran{G}}$ where $x \in \ran{G}$. - By definition of the \nameref{ref:range} of a function, there exists some - $t$ such that $\pair{t, x} \in G$. - By definition of the \nameref{ref:inverse} of a set, it follows - $\pair{x, t} \in G^{-1}$. - Thus $\pair{x, x} \in G \circ G^{-1}$. + \subparagraph{($\supseteq$)}% - \subparagraph{Conclusion}% + Let $\pair{x, x} \in I_{\ran{G}}$ where $x \in \ran{G}$. + By definition of the \nameref{ref:range} of a function, there exists some + $t$ such that $\pair{t, x} \in G$. + By definition of the \nameref{ref:inverse} of a set, it follows + $\pair{x, t} \in G^{-1}$. + Thus $\pair{x, x} \in G \circ G^{-1}$. - Since $G \circ G^{-1}$ is a subset of $I_{\ran{G}}$ and vice versa, it - follows that these two sets are equal. + \subparagraph{Conclusion}% - \paragraph{(a)}% + Since $G \circ G^{-1}$ is a subset of $I_{\ran{G}}$ and vice versa, it + follows that these two sets are equal. - This immediately follows from part \nameref{par:exercise-3.25-b}. + \paragraph{(a)}% -\end{proof} + This immediately follows from part \nameref{par:exercise-3.25-b}. + + \end{proof} \subsection{\verified{Exercise 3.26}}% \hyperlabel{sub:exercise-3.26} -Prove the second halves of parts (a) and (b) of Theorem 3K. + Prove the second halves of parts (a) and (b) of Theorem 3K. -\begin{proof} - - Refer to \nameref{sub:theorem-3k-a}, \nameref{sub:theorem-3k-b}, and - \nameref{sub:theorem-3k-c}. - -\end{proof} + \begin{proof} + Refer to \nameref{sub:theorem-3k-a}, \nameref{sub:theorem-3k-b}, and + \nameref{sub:theorem-3k-c}. + \end{proof} \subsection{\verified{Exercise 3.27}}% \hyperlabel{sub:exercise-3.27} -Show that $\dom{(F \circ G)} = \img{G^{-1}}{\dom{F}}$ for any sets $F$ and $G$. -($F$ and $G$ need not be functions.) + Show that $\dom{(F \circ G)} = \img{G^{-1}}{\dom{F}}$ for any sets $F$ and + $G$. + ($F$ and $G$ need not be functions.) -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_27} - Let $F$ and $G$ be arbitrary sets. - We show that each side of our desired equality is a subset of the other. + \begin{proof} + Let $F$ and $G$ be arbitrary sets. + We show that each side of our desired equality is a subset of the other. - \paragraph{($\subseteq$)}% + \paragraph{($\subseteq$)}% - Let $x \in \dom{(F \circ G)}$. - Then there exists a set $y$ such that $\pair{x, y} \in F \circ G$. - By definition of the \nameref{ref:composition} of sets, there exists a set - $t$ such that $xGt$ and $tFy$. - Thus $t \in \dom{F}$. - Therefore - \begin{align*} - x - & \in \{v \mid (\exists t \in \dom{F}) vGt\} \\ - & = \{v \mid (\exists t \in \dom{F}) t(G^{-1})v\} \\ - & = \img{G^{-1}}{\dom{F}}. - \end{align*} + Let $x \in \dom{(F \circ G)}$. + Then there exists a set $y$ such that $\pair{x, y} \in F \circ G$. + By definition of the \nameref{ref:composition} of sets, there exists a set + $t$ such that $xGt$ and $tFy$. + Thus $t \in \dom{F}$. + Therefore + \begin{align*} + x + & \in \{v \mid (\exists t \in \dom{F}) vGt\} \\ + & = \{v \mid (\exists t \in \dom{F}) t(G^{-1})v\} \\ + & = \img{G^{-1}}{\dom{F}}. + \end{align*} - \paragraph{($\supseteq$)}% + \paragraph{($\supseteq$)}% - Let $x \in \img{G^{-1}}{\dom{F}}$. - Then, by definition of the \nameref{ref:image} of a set, there exists some - $u \in \dom{F}$ such that $u(G^{-1})x$. - By definition of the \nameref{ref:inverse} of a set, $xGu$. - By definition of the \nameref{ref:domain} of a set, there exists some $t$ - such that $uFt$. - Thus $xGu \land uFt$. - By definition of the \nameref{ref:composition} of sets, - $\pair{x, t} \in F \circ G$. - Therefore $x \in \dom{(F \circ G)}$. + Let $x \in \img{G^{-1}}{\dom{F}}$. + Then, by definition of the \nameref{ref:image} of a set, there exists some + $u \in \dom{F}$ such that $u(G^{-1})x$. + By definition of the \nameref{ref:inverse} of a set, $xGu$. + By definition of the \nameref{ref:domain} of a set, there exists some $t$ + such that $uFt$. + Thus $xGu \land uFt$. + By definition of the \nameref{ref:composition} of sets, + $\pair{x, t} \in F \circ G$. + Therefore $x \in \dom{(F \circ G)}$. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.28}}% \hyperlabel{sub:exercise-3.28} -Assume that $f$ is a one-to-one function from $A$ into $B$, and that $G$ is the - function with $\dom{G} = \powerset{A}$ defined by the equation - $G(X) = \img{f}{X}$. -Show that $G$ maps $\powerset{A}$ one-to-one into $\powerset{B}$. + Assume that $f$ is a one-to-one function from $A$ into $B$, and that $G$ is + the function with $\dom{G} = \powerset{A}$ defined by the equation + $G(X) = \img{f}{X}$. + Show that $G$ maps $\powerset{A}$ one-to-one into $\powerset{B}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_28} - By construction, $\dom{G} = \powerset{A}$. - Likewise, $\ran{G} \subseteq \powerset{B}$ by definition of the - \nameref{ref:image} of sets. - Thus $G$ maps $\powerset{A}$ into $\powerset{B}$. + \begin{proof} + By construction, $\dom{G} = \powerset{A}$. + Likewise, $\ran{G} \subseteq \powerset{B}$ by definition of the + \nameref{ref:image} of sets. + Thus $G$ maps $\powerset{A}$ into $\powerset{B}$. - Let $y \in \ran{G}$. - Then there exists an $X_1 \in \powerset{A}$ such that $\img{f}{X_1} = y$. - To prove $G$ is one-to-one into $\powerset{B}$, assume there exists an - $X_2 \in \powerset{A}$ such that $\img{f}{X_2} = y$. - All that remains is showing $X_1 = X_2$. + Let $y \in \ran{G}$. + Then there exists an $X_1 \in \powerset{A}$ such that $\img{f}{X_1} = y$. + To prove $G$ is one-to-one into $\powerset{B}$, assume there exists an + $X_2 \in \powerset{A}$ such that $\img{f}{X_2} = y$. + All that remains is showing $X_1 = X_2$. - Let $t \in X_1$. - By definition of the \nameref{ref:image} of a set, $f(t) \in \img{f}{X_1}$. - Since $\img{f}{X_1} = \img{f}{X_2}$, it follows $f(t) \in \img{f}{X_2}$. - Because $f$ is one-to-one, $f(t) \in \img{f}{X_2}$ if and only if $t \in X_2$. - Thus $t \in X_1$ if and only if $t \in X_2$. - By the \nameref{ref:extensionality-axiom}, it follows $X_1 = X_2$. - -\end{proof} + Let $t \in X_1$. + By definition of the \nameref{ref:image} of a set, $f(t) \in \img{f}{X_1}$. + Since $\img{f}{X_1} = \img{f}{X_2}$, it follows $f(t) \in \img{f}{X_2}$. + Because $f$ is one-to-one, $f(t) \in \img{f}{X_2}$ if and only if + $t \in X_2$. + Thus $t \in X_1$ if and only if $t \in X_2$. + By the \nameref{ref:extensionality-axiom}, it follows $X_1 = X_2$. + \end{proof} \subsection{\verified{Exercise 3.29}}% \hyperlabel{sub:exercise-3.29} -Assume that $f \colon A \rightarrow B$ and define a function - $G \colon B \rightarrow \powerset{A}$ by - \begin{equation} - \hyperlabel{sub:exercise-3.29-eq1} - G(b) = \{x \in A \mid f(x) = b\}. - \end{equation} -Show that if $f$ maps $A$ \textit{onto} $B$, then $G$ is one-to-one. -Does the converse hold? + Assume that $f \colon A \rightarrow B$ and define a function + $G \colon B \rightarrow \powerset{A}$ by + \begin{equation} + \hyperlabel{sub:exercise-3.29-eq1} + G(b) = \{x \in A \mid f(x) = b\}. + \end{equation} + Show that if $f$ maps $A$ \textit{onto} $B$, then $G$ is one-to-one. + Does the converse hold? -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_39} - Let $f \colon A \rightarrow B$ such that $f$ maps $A$ onto $B$. - Define $G \colon B \rightarrow \powerset{A}$ by - \eqref{sub:exercise-3.29-eq1}. - Let $y \in \ran{G}$. - By definition of the \nameref{ref:range} of a set, there exists an - $x_1 \in B$ such that $G(x_1) = y$. - To prove $G$ is one-to-one, suppose there exists an $x_2 \in B$ such - that $G(x_2) = y$. - All that remains is proving $x_1 = x_2$. + \begin{proof} + Let $f \colon A \rightarrow B$ such that $f$ maps $A$ onto $B$. + Define $G \colon B \rightarrow \powerset{A}$ by + \eqref{sub:exercise-3.29-eq1}. + Let $y \in \ran{G}$. + By definition of the \nameref{ref:range} of a set, there exists an + $x_1 \in B$ such that $G(x_1) = y$. + To prove $G$ is one-to-one, suppose there exists an $x_2 \in B$ such + that $G(x_2) = y$. + All that remains is proving $x_1 = x_2$. - By \eqref{sub:exercise-3.29-eq1}, it follows - \begin{align*} - G(x_1) & = \{x \in A \mid f(x) = x_1\} \\ - G(x_2) & = \{x \in A \mid f(x) = x_2\}. - \end{align*} - Since $f$ maps $A$ onto $B$, $\ran{f} = B$. - Thus $x_1, x_2 \in \ran{f}$. - By definition of the \nameref{ref:range} of a set, there exist some $t \in A$ - such that $f(t) = x_1$. - Therefore $t \in G(x_1)$. - By the \nameref{ref:extensionality-axiom}, $t \in G(x_2)$. - Then $f(t) = x_2$. - But $f$ is a \nameref{ref:function}, i.e. single-valued. - Thus $x_1 = x_2$. + By \eqref{sub:exercise-3.29-eq1}, it follows + \begin{align*} + G(x_1) & = \{x \in A \mid f(x) = x_1\} \\ + G(x_2) & = \{x \in A \mid f(x) = x_2\}. + \end{align*} + Since $f$ maps $A$ onto $B$, $\ran{f} = B$. + Thus $x_1, x_2 \in \ran{f}$. + By definition of the \nameref{ref:range} of a set, there exist some + $t \in A$ such that $f(t) = x_1$. + Therefore $t \in G(x_1)$. + By the \nameref{ref:extensionality-axiom}, $t \in G(x_2)$. + Then $f(t) = x_2$. + But $f$ is a \nameref{ref:function}, i.e. single-valued. + Thus $x_1 = x_2$. - \suitdivider - If $G$ is one-to-one, it does not follow that $f$ maps $A$ onto $B$. - As a counterexample, let $f \colon \{1\} \rightarrow \{1, 2\}$ given by - $f(x) = x$. - Define $G \colon \{1, 2\} \rightarrow \powerset{\{1\}}$ by - $$G(b) = \{x \in \{1\} \mid f(x) = b\}.$$ - $G$ is trivially one-to-one since $G(1) = \{1\}$ and $G(2) = \emptyset$. - But $f$ does not map onto $\{1, 2\}$; there is no element in its domain that - corresponds to value $2$. - -\end{proof} + \suitdivider + If $G$ is one-to-one, it does not follow that $f$ maps $A$ onto $B$. + As a counterexample, let $f \colon \{1\} \rightarrow \{1, 2\}$ given by + $f(x) = x$. + Define $G \colon \{1, 2\} \rightarrow \powerset{\{1\}}$ by + $$G(b) = \{x \in \{1\} \mid f(x) = b\}.$$ + $G$ is trivially one-to-one since $G(1) = \{1\}$ and $G(2) = \emptyset$. + But $f$ does not map onto $\{1, 2\}$; there is no element in its domain that + corresponds to value $2$. + \end{proof} \subsection{\sorry{Exercise 3.30}}% \hyperlabel{sub:exercise-3.30} -Assume that $F \colon \powerset{A} \rightarrow \powerset{A}$ and that $F$ has - the monotonicity property: - $$X \subseteq Y \subseteq A \Rightarrow F(X) \subseteq F(Y).$$ -Define - $$B = \bigcap\{X \subseteq A \mid F(X) \subseteq X\} \quad\text{and}\quad - C = \bigcup\{X \subseteq A \mid X \subseteq F(X)\}.$$ + Assume that $F \colon \powerset{A} \rightarrow \powerset{A}$ and that $F$ has + the monotonicity property: + $$X \subseteq Y \subseteq A \Rightarrow F(X) \subseteq F(Y).$$ + Define + $$B = \bigcap\{X \subseteq A \mid F(X) \subseteq X\} \quad\text{and}\quad + C = \bigcup\{X \subseteq A \mid X \subseteq F(X)\}.$$ \subsubsection{\sorry{Exercise 3.30 (a)}}% \hyperlabel{ssub:exercise-3.30-a} -Show that $F(B) = B$ and $F(C) = C$. + Show that $F(B) = B$ and $F(C) = C$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsubsection{\sorry{Exercise 3.30 (b)}}% \hyperlabel{ssub:exercise-3.30-b} -Show that if $F(X) = X$, then $B \subseteq X \subseteq C$. + Show that if $F(X) = X$, then $B \subseteq X \subseteq C$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\unverified{Exercise 3.31}}% \hyperlabel{sub:exercise-3.31} -Show that from the first form of the axiom of choice we can prove the second - form, and conversely. + Show that from the first form of the axiom of choice we can prove the second + form, and conversely. -\begin{proof} + \begin{proof} + We prove the first form holds if and only if the second form holds. - We prove the first form holds if and only if the second form holds. + \paragraph{($\Rightarrow$)}% - \paragraph{($\Rightarrow$)}% + We assume the first form of the axiom of choice. + Let $I$ be a set and $H$ be a function with $\dom{H} = I$. + Furthermore, suppose $H(i) \neq \emptyset$ for all $i \in I$. + By definition of the \nameref{ref:cartesian-product}, + $$\bigtimes_{i \in I} H(i) = \{f \mid + f \text{ is a function with } \dom{f} = I \text{ and } + (\forall i \in I) f(i) \in H(i)\}.$$ + Consider the relation $R$ formed by + $$R = \bigcup_{i \in I} \{i\} \times H(i).$$ + By the \nameref{ref:axiom-of-choice-1}, there exists a function + $f \subseteq R$ with $\dom{f} = I$. + Furthermore, for all $i \in I$, it must be $f(i) \in H(i)$ by + construction. + Then $f$ is a member of $\bigtimes_{i \in I} H(i)$. + That is, $\bigtimes_{i \in I} H(i) \neq \emptyset$. - We assume the first form of the axiom of choice. - Let $I$ be a set and $H$ be a function with $\dom{H} = I$. - Furthermore, suppose $H(i) \neq \emptyset$ for all $i \in I$. - By definition of the \nameref{ref:cartesian-product}, - $$\bigtimes_{i \in I} H(i) = \{f \mid - f \text{ is a function with } \dom{f} = I \text{ and } - (\forall i \in I) f(i) \in H(i)\}.$$ - Consider the relation $R$ formed by - $$R = \bigcup_{i \in I} \{i\} \times H(i).$$ - By the \nameref{ref:axiom-of-choice-1}, there exists a function - $f \subseteq R$ with $\dom{f} = I$. - Furthermore, for all $i \in I$, it must be $f(i) \in H(i)$ by construction. - Then $f$ is a member of $\bigtimes_{i \in I} H(i)$. - That is, $\bigtimes_{i \in I} H(i) \neq \emptyset$. + \paragraph{($\Leftarrow$)}% - \paragraph{($\Leftarrow$)}% + We assume the second form of the axiom of choice. + Let $R$ be an arbitrary relation. + There are two cases to consider: - We assume the second form of the axiom of choice. - Let $R$ be an arbitrary relation. - There are two cases to consider: + \subparagraph{Case 1}% - \subparagraph{Case 1}% + Suppose $\ran{R} = \emptyset$. + Then $R = \emptyset$. + Thus the function $\emptyset \subseteq R$ satisfies + $\dom{\emptyset} = \dom{R}$. - Suppose $\ran{R} = \emptyset$. - Then $R = \emptyset$. - Thus the function $\emptyset \subseteq R$ satisfies - $\dom{\emptyset} = \dom{R}$. + \subparagraph{Case 2}% - \subparagraph{Case 2}% + Suppose $\ran{R} \neq \emptyset$. + Let $I = \dom{R}$ and define $H \colon I \rightarrow \{\ran{R}\}$ as + $H(i) = \ran{R}$ for all $i \in I$. + By the \nameref{ref:axiom-of-choice-2}, + $\bigtimes_{i \in I} H(i) \neq \emptyset$. + By definition of the \nameref{ref:cartesian-product}, there exists some + function $f$ such that $\dom{f} = I$ and + $(\forall i \in I) f(i) \in H(i) = \ran{R}$. + Thus $\dom{f} = \dom{R}$ and $f \subseteq R$ as desired. - Suppose $\ran{R} \neq \emptyset$. - Let $I = \dom{R}$ and define $H \colon I \rightarrow \{\ran{R}\}$ as - $H(i) = \ran{R}$ for all $i \in I$. - By the \nameref{ref:axiom-of-choice-2}, - $\bigtimes_{i \in I} H(i) \neq \emptyset$. - By definition of the \nameref{ref:cartesian-product}, there exists some - function $f$ such that $\dom{f} = I$ and - $(\forall i \in I) f(i) \in H(i) = \ran{R}$. - Thus $\dom{f} = \dom{R}$ and $f \subseteq R$ as desired. + \paragraph{Conclusion}% - \paragraph{Conclusion}% + The above cases are exhaustive and yield the same conclusion: for any + relation $R$ there exists a function $f \subseteq R$ such that + $\dom{f} = \dom{R}$. - The above cases are exhaustive and yield the same conclusion: for any - relation $R$ there exists a function $f \subseteq R$ such that - $\dom{f} = \dom{R}$. - -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.32a}}% \hyperlabel{sub:exercise-3.32-a} -Show that $R$ is symmetric iff $R^{-1} \subseteq R$. + Show that $R$ is symmetric iff $R^{-1} \subseteq R$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_32\_a} - \paragraph{($\Rightarrow$)}% + \begin{proof} - Suppose $R$ is \nameref{ref:symmetric}. - Let $\pair{x, y} \in R^{-1}$. - By definition of the \nameref{ref:inverse} of a set, - $\pair{y, x} \in R$. - By symmetry, $\pair{x, y} \in R$. - Thus $R^{-1} \subseteq R$. + \paragraph{($\Rightarrow$)}% - \paragraph{($\Leftarrow$)}% + Suppose $R$ is \nameref{ref:symmetric}. + Let $\pair{x, y} \in R^{-1}$. + By definition of the \nameref{ref:inverse} of a set, + $\pair{y, x} \in R$. + By symmetry, $\pair{x, y} \in R$. + Thus $R^{-1} \subseteq R$. - Suppose $R^{-1} \subseteq R$. - Let $\pair{x, y} \in R$. - By definition of the \nameref{ref:inverse} of a set, - $\pair{y, x} \in R^{-1}$. - Since $R^{-1} \subseteq R$, $\pair{y, x} \in R$. - Therefore $\pair{x, y}$ and $\pair{y, x}$ are both in $R$. - In other words, $R$ is symmetric. + \paragraph{($\Leftarrow$)}% -\end{proof} + Suppose $R^{-1} \subseteq R$. + Let $\pair{x, y} \in R$. + By definition of the \nameref{ref:inverse} of a set, + $\pair{y, x} \in R^{-1}$. + Since $R^{-1} \subseteq R$, $\pair{y, x} \in R$. + Therefore $\pair{x, y}$ and $\pair{y, x}$ are both in $R$. + In other words, $R$ is symmetric. + + \end{proof} \subsection{\verified{Exercise 3.32b}}% \hyperlabel{sub:exercise-3.32-b} -Show that $R$ is transitive iff $R \circ R \subseteq R$. + Show that $R$ is transitive iff $R \circ R \subseteq R$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_32\_b} - \paragraph{($\Rightarrow$)}% + \begin{proof} - Suppose $R$ is \nameref{ref:transitive}. - Let $\pair{x, y} \in R \circ R$. - By definition of the \nameref{ref:composition} of a set, - there exists some $t$ such that $xRt \land tRy$. - That is, $\pair{x, t} \in R$ and $\pair{t, y} \in R$. - Since $R$ is transitive, it follows $\pair{x, y} \in R$. + \paragraph{($\Rightarrow$)}% - \paragraph{($\Leftarrow$)}% + Suppose $R$ is \nameref{ref:transitive}. + Let $\pair{x, y} \in R \circ R$. + By definition of the \nameref{ref:composition} of a set, + there exists some $t$ such that $xRt \land tRy$. + That is, $\pair{x, t} \in R$ and $\pair{t, y} \in R$. + Since $R$ is transitive, it follows $\pair{x, y} \in R$. - Suppose $R \circ R \subseteq R$. - Let $\pair{x, y} \pair{y, z} \in R$. - By definition of the \nameref{ref:composition} of a set, - $$R \circ R = \{\pair{u, v} \mid \exists t(uRt \land tRv)\}.$$ - Then $\pair{x, z} \in R \circ R$. - Since $R \circ R \subseteq R$, it follows $\pair{x, z} \in R$. - Thus $R$ is transitive. + \paragraph{($\Leftarrow$)}% -\end{proof} + Suppose $R \circ R \subseteq R$. + Let $\pair{x, y} \pair{y, z} \in R$. + By definition of the \nameref{ref:composition} of a set, + $$R \circ R = \{\pair{u, v} \mid \exists t(uRt \land tRv)\}.$$ + Then $\pair{x, z} \in R \circ R$. + Since $R \circ R \subseteq R$, it follows $\pair{x, z} \in R$. + Thus $R$ is transitive. + + \end{proof} \subsection{\verified{Exercise 3.33}}% \hyperlabel{sub:exercise-3.33} -Show that $R$ is a symmetric and transitive relation iff $R = R^{-1} \circ R$. + Show that $R$ is a symmetric and transitive relation iff $R = R^{-1} \circ R$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_33} - By definition of the \nameref{ref:inverse} and \nameref{ref:composition} - of sets, - \begin{align} - R^{-1} \circ R - & = \{ (u, v) \mid \exists t(uRt \land tR^{-1}v) \} - \nonumber \\ - & = \{ (u, v) \mid \exists t(uRt \land vRt) \}. - \hyperlabel{sub:exercise-3.33-eq1} - \end{align} + \begin{proof} + By definition of the \nameref{ref:inverse} and \nameref{ref:composition} + of sets, + \begin{align} + R^{-1} \circ R + & = \{ (u, v) \mid \exists t(uRt \land tR^{-1}v) \} + \nonumber \\ + & = \{ (u, v) \mid \exists t(uRt \land vRt) \}. + \hyperlabel{sub:exercise-3.33-eq1} + \end{align} - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $R$ is symmetric and transitive. - We now show that $R \subseteq R^{-1} \circ R$ and - $R^{-1} \circ R \subseteq R$. + Suppose $R$ is symmetric and transitive. + We now show that $R \subseteq R^{-1} \circ R$ and + $R^{-1} \circ R \subseteq R$. - \subparagraph{($\subseteq$)}% + \subparagraph{($\subseteq$)}% - Let $\pair{x, y} \in R$. - Since $R$ is symmetric, $\pair{y, x} \in R$. - Since $R$ is transitive, $\pair{x, x} \in R$. - Then there exists a $t$ such that $\pair{x, t} \in R$ and - $\pair{y, t} \in R$, namely $t = x$. - By \eqref{sub:exercise-3.33-eq1}, - $\pair{x, y} \in R^{-1} \circ R$. + Let $\pair{x, y} \in R$. + Since $R$ is symmetric, $\pair{y, x} \in R$. + Since $R$ is transitive, $\pair{x, x} \in R$. + Then there exists a $t$ such that $\pair{x, t} \in R$ and + $\pair{y, t} \in R$, namely $t = x$. + By \eqref{sub:exercise-3.33-eq1}, + $\pair{x, y} \in R^{-1} \circ R$. - \subparagraph{($\supseteq$)}% + \subparagraph{($\supseteq$)}% - Let $\pair{x, y} \in R^{-1} \circ R$. - By \eqref{sub:exercise-3.33-eq1}, there exists some $t$ such that - $\pair{x, t} \in R$ and $\pair{y, t} \in R$. - But $R$ is symmetric meaning $\pair{t, y} \in R$. - Since $R$ is transitive, it follows $\pair{x, y} \in R$. + Let $\pair{x, y} \in R^{-1} \circ R$. + By \eqref{sub:exercise-3.33-eq1}, there exists some $t$ such that + $\pair{x, t} \in R$ and $\pair{y, t} \in R$. + But $R$ is symmetric meaning $\pair{t, y} \in R$. + Since $R$ is transitive, it follows $\pair{x, y} \in R$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Suppose $R = R^{-1} \circ R$. - We prove that (i) $R$ is symmetric and (ii) $R$ is transitive. + Suppose $R = R^{-1} \circ R$. + We prove that (i) $R$ is symmetric and (ii) $R$ is transitive. - \subparagraph{(i)}% - \hyperlabel{spar:exercise-3.33-i} + \subparagraph{(i)}% + \hyperlabel{spar:exercise-3.33-i} - First we note that $R$ is equal to its inverse: - \begin{align} - R^{-1} - & = (R^{-1} \circ R)^{-1} \nonumber \\ - & = R^{-1} \circ (R^{-1})^{-1} - & \textref{sub:theorem-3i} \nonumber \\ - & = R^{-1} \circ R - & \textref{sub:theorem-3e} \nonumber \\ - & = R \hyperlabel{sub:exercise-3.33-eq2}. - \end{align} - Now let $\pair{x, y} \in R$. - By \eqref{sub:exercise-3.33-eq2} $\pair{x, y} \in R^{-1}$. - By definition of the \nameref{ref:inverse} of a set, - $\pair{y, x} \in R$. - Thus $R$ is symmetric. + First we note that $R$ is equal to its inverse: + \begin{align} + R^{-1} + & = (R^{-1} \circ R)^{-1} \nonumber \\ + & = R^{-1} \circ (R^{-1})^{-1} + & \textref{sub:theorem-3i} \nonumber \\ + & = R^{-1} \circ R + & \textref{sub:theorem-3e} \nonumber \\ + & = R \hyperlabel{sub:exercise-3.33-eq2}. + \end{align} + Now let $\pair{x, y} \in R$. + By \eqref{sub:exercise-3.33-eq2} $\pair{x, y} \in R^{-1}$. + By definition of the \nameref{ref:inverse} of a set, + $\pair{y, x} \in R$. + Thus $R$ is symmetric. - \subparagraph{(ii)}% + \subparagraph{(ii)}% - Let $\pair{x, y}, \pair{y, z} \in R$. - By \nameref{spar:exercise-3.33-i}, $R$ is symmetric. - Thus $\pair{z, y} \in R$. - By \eqref{sub:exercise-3.33-eq1}, it follows - $\pair{x, z} \in R^{-1} \circ R$. - Since $R^{-1} \circ R = R$, it follows $\pair{x, z} \in R$. - Thus $R$ is transitive. + Let $\pair{x, y}, \pair{y, z} \in R$. + By \nameref{spar:exercise-3.33-i}, $R$ is symmetric. + Thus $\pair{z, y} \in R$. + By \eqref{sub:exercise-3.33-eq1}, it follows + $\pair{x, z} \in R^{-1} \circ R$. + Since $R^{-1} \circ R = R$, it follows $\pair{x, z} \in R$. + Thus $R$ is transitive. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.34}}% \hyperlabel{sub:exercise-3.34} -Assume that $\mathscr{A}$ is a nonempty set, every member of which is a - transitive relation. + Assume that $\mathscr{A}$ is a nonempty set, every member of which is a + transitive relation. + \begin{enumerate}[(a)] + \item Is the set $\bigcap{\mathscr{A}}$ a transitive relation? + \item Is $\bigcup{\mathscr{A}}$ a transitive relation? + \end{enumerate} -\begin{enumerate}[(a)] - \item Is the set $\bigcap{\mathscr{A}}$ a transitive relation? - \item Is $\bigcup{\mathscr{A}}$ a transitive relation? -\end{enumerate} - -\begin{proof} - - \statementpadding - - \code*{Bookshelf/Enderton/Set/Chapter\_3} + \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_34\_a} \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_34\_b} - \paragraph{(a)}% + \begin{proof} - Because $\mathscr{A} \neq \emptyset$, $\bigcap{\mathscr{A}}$ is - well-defined. - We prove that $\bigcap{\mathscr{A}}$ is a transitive relation. - Let $\pair{x, y}, \pair{y, z} \in \bigcap{\mathscr{A}}$. - Then forall $A$ in $\mathscr{A}$, it follows - $\pair{x, y}, \pair{y, z} \in A$. - Since $A$ is transitive, it follows $\pair{x, z} \in A$. - Since this holds for all $A \in \mathscr{A}$, it follows that - $\pair{x, z} \in A$ as well. - Thus $\bigcap{\mathscr{A}}$ is transitive. + \paragraph{(a)}% - \paragraph{(b)}% + Because $\mathscr{A} \neq \emptyset$, $\bigcap{\mathscr{A}}$ is + well-defined. + We prove that $\bigcap{\mathscr{A}}$ is a transitive relation. + Let $\pair{x, y}, \pair{y, z} \in \bigcap{\mathscr{A}}$. + Then forall $A$ in $\mathscr{A}$, it follows + $\pair{x, y}, \pair{y, z} \in A$. + Since $A$ is transitive, it follows $\pair{x, z} \in A$. + Since this holds for all $A \in \mathscr{A}$, it follows that + $\pair{x, z} \in A$ as well. + Thus $\bigcap{\mathscr{A}}$ is transitive. - We show that $\bigcup{\mathscr{A}}$ is not necessarily transitive with a - counterexample. - Suppose $$\mathscr{A} = \{ - \{\pair{1, 2}, \pair{2, 3}, \pair{1, 3}\}, \{\pair{2, 1}\} - \}.$$ - Notice that the two members of $\mathscr{A}$ are transitive relations. - Now $$\bigcup{\mathscr{A}} = \{ - \pair{1, 2}, \pair{2, 3}, \pair{1, 3}, \pair{2, 1}, - \}.$$ - But the above cannot be transitive, for $\pair{1, 2}$ and $\pair{2, 1}$ are - members of the set, but $\pair{1, 1}$ is not. + \paragraph{(b)}% -\end{proof} + We show that $\bigcup{\mathscr{A}}$ is not necessarily transitive with a + counterexample. + Suppose $$\mathscr{A} = \{ + \{\pair{1, 2}, \pair{2, 3}, \pair{1, 3}\}, \{\pair{2, 1}\} + \}.$$ + Notice that the two members of $\mathscr{A}$ are transitive relations. + Now $$\bigcup{\mathscr{A}} = \{ + \pair{1, 2}, \pair{2, 3}, \pair{1, 3}, \pair{2, 1}, + \}.$$ + But the above cannot be transitive, for $\pair{1, 2}$ and $\pair{2, 1}$ are + members of the set, but $\pair{1, 1}$ is not. + + \end{proof} \subsection{\verified{Exercise 3.35}}% \hyperlabel{sub:exercise-3.35} -Show that for any $R$ and $x$, we have $[x]_R = \img{R}{\{x\}}$. + Show that for any $R$ and $x$, we have $[x]_R = \img{R}{\{x\}}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_35} - Let $R$ and $x$ be arbitrary sets. - Then - \begin{align*} - [x]_R - & = \{t \mid xRt\} \\ - & = \{t \mid (\exists u \in \{x\})uRt\} \\ - & = \img{R}{\{x\}}. - \end{align*} - -\end{proof} + \begin{proof} + Let $R$ and $x$ be arbitrary sets. + Then + \begin{align*} + [x]_R + & = \{t \mid xRt\} \\ + & = \{t \mid (\exists u \in \{x\})uRt\} \\ + & = \img{R}{\{x\}}. + \end{align*} + \end{proof} \subsection{\verified{Exercise 3.36}}% \hyperlabel{sub:exercise-3.36} -Assume that $f \colon A \rightarrow B$ and that $R$ is an equivalence relation - on $B$. -Define $Q$ to be the set - \begin{equation} - \hyperlabel{sub:exercise-3.36-eq1} - \{\pair{x, y} \in A \times A \mid \pair{f(x), f(y)} \in R\}. - \end{equation} -Show that $Q$ is an equivalence relation on $A$. + Assume that $f \colon A \rightarrow B$ and that $R$ is an equivalence relation + on $B$. + Define $Q$ to be the set + \begin{equation} + \hyperlabel{sub:exercise-3.36-eq1} + \{\pair{x, y} \in A \times A \mid \pair{f(x), f(y)} \in R\}. + \end{equation} + Show that $Q$ is an equivalence relation on $A$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_36} - We prove that (i) $Q$ is \nameref{ref:reflexive} on $A$, (ii) $Q$ is - \nameref{ref:symmetric}, and (iii) $Q$ is \nameref{ref:transitive}. + \begin{proof} + We prove that (i) $Q$ is \nameref{ref:reflexive} on $A$, (ii) $Q$ is + \nameref{ref:symmetric}, and (iii) $Q$ is \nameref{ref:transitive}. - \paragraph{(i)}% + \paragraph{(i)}% - Let $x \in A$. - By hypothesis, $f(x) \in B$. - Since $R$ is an equivalence relation on $B$, $R$ is reflexive on $B$. - Thus $\pair{f(x), f(x)} \in R$. - But then \eqref{sub:exercise-3.36-eq1} implies $\pair{x, x} \in Q$. - Thus $Q$ is reflexive on $A$. + Let $x \in A$. + By hypothesis, $f(x) \in B$. + Since $R$ is an equivalence relation on $B$, $R$ is reflexive on $B$. + Thus $\pair{f(x), f(x)} \in R$. + But then \eqref{sub:exercise-3.36-eq1} implies $\pair{x, x} \in Q$. + Thus $Q$ is reflexive on $A$. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $\pair{x, y} \in Q$. - By \eqref{sub:exercise-3.36-eq1}, $\pair{f(x), f(y)} \in R$. - Since $R$ is an equivalence relation on $B$, $R$ is symmetric. - Thus $\pair{f(y), f(x)} \in R$. - But then \eqref{sub:exercise-3.36-eq1} implies $\pair{y, x} \in Q$. - Thus $Q$ is symmetric. + Let $\pair{x, y} \in Q$. + By \eqref{sub:exercise-3.36-eq1}, $\pair{f(x), f(y)} \in R$. + Since $R$ is an equivalence relation on $B$, $R$ is symmetric. + Thus $\pair{f(y), f(x)} \in R$. + But then \eqref{sub:exercise-3.36-eq1} implies $\pair{y, x} \in Q$. + Thus $Q$ is symmetric. - \paragraph{(iii)}% + \paragraph{(iii)}% - Let $\pair{x, y}, \pair{y, z} \in Q$. - By \eqref{sub:exercise-3.36-eq1}, - $\pair{f(x), f(y)}, \pair{f(y), f(z)} \in R$. - Since $R$ is an equivalence relation on $B$, $R$ is transitive. - Thus $\pair{f(x), f(z)} \in R$. - But then \eqref{sub:exercise-3.36-eq1} implies $\pair{x, z} \in Q$. - Thus $Q$ is transitive. + Let $\pair{x, y}, \pair{y, z} \in Q$. + By \eqref{sub:exercise-3.36-eq1}, + $\pair{f(x), f(y)}, \pair{f(y), f(z)} \in R$. + Since $R$ is an equivalence relation on $B$, $R$ is transitive. + Thus $\pair{f(x), f(z)} \in R$. + But then \eqref{sub:exercise-3.36-eq1} implies $\pair{x, z} \in Q$. + Thus $Q$ is transitive. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.37}}% \hyperlabel{sub:exercise-3.37} -Assume that $\Pi$ is a partition of a set $A$. -Define the relation $R_\Pi$ as follows: - \begin{equation} - \hyperlabel{sub:exercise-3.37-eq1} - xR_{\Pi}y \iff (\exists B \in \Pi)(x \in B \land y \in B). - \end{equation} -Show that $R_\Pi$ is an equivalence relation on $A$. -(This is a formalized version of the discussion at the beginning of this - section.) + Assume that $\Pi$ is a partition of a set $A$. + Define the relation $R_\Pi$ as follows: + \begin{equation} + \hyperlabel{sub:exercise-3.37-eq1} + xR_{\Pi}y \iff (\exists B \in \Pi)(x \in B \land y \in B). + \end{equation} + Show that $R_\Pi$ is an equivalence relation on $A$. + (This is a formalized version of the discussion at the beginning of this + section.) -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_37} - We prove that (i) $R_\Pi$ is \nameref{ref:reflexive} on $B$, (ii) $R_\Pi$ is - \nameref{ref:symmetric}, and (iii) $R_\Pi$ is \nameref{ref:transitive}. + \begin{proof} + We prove that (i) $R_\Pi$ is \nameref{ref:reflexive} on $B$, (ii) $R_\Pi$ is + \nameref{ref:symmetric}, and (iii) $R_\Pi$ is \nameref{ref:transitive}. - \paragraph{(i)}% + \paragraph{(i)}% - Let $x \in A$. - By definition of a \nameref{ref:partition}, there exists some nonempty set - $B \in \Pi$ such that $x \in B$. - Thus $(\exists B \in \Pi)(x \in B \land x \in B)$. - By \eqref{sub:exercise-3.37-eq1}, $\pair{x, x} \in R_\Pi$. - Therefore $R_\Pi$ is reflexive on $A$. + Let $x \in A$. + By definition of a \nameref{ref:partition}, there exists some nonempty set + $B \in \Pi$ such that $x \in B$. + Thus $(\exists B \in \Pi)(x \in B \land x \in B)$. + By \eqref{sub:exercise-3.37-eq1}, $\pair{x, x} \in R_\Pi$. + Therefore $R_\Pi$ is reflexive on $A$. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $\pair{x, y} \in R_\Pi$. - By \eqref{sub:exercise-3.37-eq1}, there exists some $B \in \Pi$ such that - $x \in B \land y \in B$. - But then $y \in B \land x \in B$. - Thus $\pair{y, x} \in R_\Pi$. - In other words, $R_\Pi$ is symmetric. + Let $\pair{x, y} \in R_\Pi$. + By \eqref{sub:exercise-3.37-eq1}, there exists some $B \in \Pi$ such that + $x \in B \land y \in B$. + But then $y \in B \land x \in B$. + Thus $\pair{y, x} \in R_\Pi$. + In other words, $R_\Pi$ is symmetric. - \paragraph{(iii)}% + \paragraph{(iii)}% - Let $\pair{x, y}, \pair{y, z} \in R_\Pi$. - By \eqref{sub:exercise-3.37-eq1}, there exists some $B_1 \in \Pi$ such that - $x \in B_1 \land y \in B_1$. - Likewise there exists some $B_2 \in \Pi$ such that - $y \in B_2 \land z \in B_2$. - But $\Pi$ is a \nameref{ref:partition} meaning $y \in B_1$ and $y \in B_2$ - if $B_1 = B_2$. - Therefore $x \in B_1 \land z \in B_1$ and $\pair{x, z} \in R_\Pi$. - In other words, $R_\Pi$ is transitive. + Let $\pair{x, y}, \pair{y, z} \in R_\Pi$. + By \eqref{sub:exercise-3.37-eq1}, there exists some $B_1 \in \Pi$ such that + $x \in B_1 \land y \in B_1$. + Likewise there exists some $B_2 \in \Pi$ such that + $y \in B_2 \land z \in B_2$. + But $\Pi$ is a \nameref{ref:partition} meaning $y \in B_1$ and $y \in B_2$ + if $B_1 = B_2$. + Therefore $x \in B_1 \land z \in B_1$ and $\pair{x, z} \in R_\Pi$. + In other words, $R_\Pi$ is transitive. -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.38}}% \hyperlabel{sub:exercise-3.38} -\nameref{sub:theorem-3p} shows that $A / R$ is a partition of $A$ whenever $R$ - is an equivalence relation on $A$. -Show that if we start with the equivalence relation $R_\Pi$ of the preceding - exercise, then the partition $A / R_\Pi$ is just $\Pi$. + \nameref{sub:theorem-3p} shows that $A / R$ is a partition of $A$ whenever $R$ + is an equivalence relation on $A$. + Show that if we start with the equivalence relation $R_\Pi$ of the preceding + exercise, then the partition $A / R_\Pi$ is just $\Pi$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_38} - By definition, - \begin{equation} - \hyperlabel{sub:exercise-3.38-eq1} - R_\Pi = \{ (x, y) \mid (\exists B \in \Pi)(x \in B \land y \in B) \}. - \end{equation} - We prove that $A / R_\Pi = \Pi$. - By the \nameref{ref:extensionality-axiom}, these two sets are equal when - $$B \in A / R_\Pi \iff B \in \Pi.$$ - We prove both directions of this biconditional. + \begin{proof} + By definition, + \begin{equation} + \hyperlabel{sub:exercise-3.38-eq1} + R_\Pi = \{ (x, y) \mid (\exists B \in \Pi)(x \in B \land y \in B) \}. + \end{equation} + We prove that $A / R_\Pi = \Pi$. + By the \nameref{ref:extensionality-axiom}, these two sets are equal when + $$B \in A / R_\Pi \iff B \in \Pi.$$ + We prove both directions of this biconditional. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Suppose $B \in A / R_\Pi$. - By \nameref{sub:exercise-3.37}, $R_\Pi$ is an equivalence class. - Then, by definition of a \nameref{ref:quotient-set}, - $$A / R_\Pi = \{[x]_{R_\Pi} \mid x \in A\},$$ - whose members are the \nameref{ref:equivalence-class}es. - Thus there exists some $x \in A$ such that $B = [x]_{R_\Pi}$. - By definition of a \nameref{ref:partition}, there exists a unique set - $B' \in \Pi$ containing $x$. - Thus it suffices to prove that $B = B'$, for then $B = [x]_{R_\Pi} = B'$ is - a member of $\Pi$ as desired. - We proceed by extensionality again; that is, we show - $$y \in B \iff y \in B'.$$ + Suppose $B \in A / R_\Pi$. + By \nameref{sub:exercise-3.37}, $R_\Pi$ is an equivalence class. + Then, by definition of a \nameref{ref:quotient-set}, + $$A / R_\Pi = \{[x]_{R_\Pi} \mid x \in A\},$$ + whose members are the \nameref{ref:equivalence-class}es. + Thus there exists some $x \in A$ such that $B = [x]_{R_\Pi}$. + By definition of a \nameref{ref:partition}, there exists a unique set + $B' \in \Pi$ containing $x$. + Thus it suffices to prove that $B = B'$, for then $B = [x]_{R_\Pi} = B'$ + is a member of $\Pi$ as desired. + We proceed by extensionality again; that is, we show + $$y \in B \iff y \in B'.$$ - \subparagraph{($\rightarrow$)}% + \subparagraph{($\rightarrow$)}% - Suppose $y \in B$. - Then + Suppose $y \in B$. + Then + \begin{align*} + y + & \in B = [x]_{R_\Pi} \\ + & = \{t \mid \pair{x, t} \in R_\Pi\} \\ + & = \{t \mid (\exists B_1 \in \Pi)(x \in B_1 \land t \in B_1)\}. + & \eqref{sub:exercise-3.38-eq1} + \end{align*} + Thus there exists some $B_1 \in \Pi$ such that $x \in B_1$ and + $y \in B_1$. + By definition of a \nameref{ref:partition}, $B_1 \in \Pi$ is the unique + member of $\Pi$ containing $y$. + Thus $B_1 = B'$ meaning $y \in B'$ as desired. + + \subparagraph{($\leftarrow$)}% + + Suppose $y \in B'$. + By construction, $x \in B'$. + Then there exists a set $B_1$ such that $x \in B_1$ and $y \in B_1$, + namely $B'$. + Therefore + \begin{align*} + y + & \in \{t \mid (\exists B_1 \in \Pi)(x \in B_1 \land t \in B_1)\} \\ + & = \{t \mid \pair{x, t} \in R_\Pi\} \\ + & = [x]_{R_\Pi} = B. + \end{align*} + + \subparagraph{Conclusion}% + + By the \nameref{ref:extensionality-axiom}, it follows $B = B'$. + Since $B' \in P$, it also follows $B \in P$. + + \paragraph{($\Leftarrow$)}% + + Let $B \in \Pi$. + By definition of a \nameref{ref:partition}, $B$ is nonempty. + Let $x \in B$. + By definition of a set, $B = \{t \mid x \in B \land t \in B\}$. + By definition of a \nameref{ref:partition}, every member of $B$ must + belong to only $B$ (i.e. no other sets in the partition). + Thus we can equivalently write \begin{align*} - y - & \in B = [x]_{R_\Pi} \\ - & = \{t \mid \pair{x, t} \in R_\Pi\} \\ - & = \{t \mid (\exists B_1 \in \Pi)(x \in B_1 \land t \in B_1)\}. - & \eqref{sub:exercise-3.38-eq1} + B + & = \{t \mid (\exists B_1 \in \Pi)(x \in B_1 \land t \in B_1)\} \\ + & = \{ t \mid \pair{x, t} \in R_\Pi \} \\ + & = [x]_{R_\Pi}. \end{align*} - Thus there exists some $B_1 \in \Pi$ such that $x \in B_1$ and - $y \in B_1$. - By definition of a \nameref{ref:partition}, $B_1 \in \Pi$ is the unique - member of $\Pi$ containing $y$. - Thus $B_1 = B'$ meaning $y \in B'$ as desired. + Therefore $B \in A / R_{\Pi}$. - \subparagraph{($\leftarrow$)}% - - Suppose $y \in B'$. - By construction, $x \in B'$. - Then there exists a set $B_1$ such that $x \in B_1$ and $y \in B_1$, - namely $B'$. - Therefore - \begin{align*} - y - & \in \{t \mid (\exists B_1 \in \Pi)(x \in B_1 \land t \in B_1)\} \\ - & = \{t \mid \pair{x, t} \in R_\Pi\} \\ - & = [x]_{R_\Pi} = B. - \end{align*} - - \subparagraph{Conclusion}% - - By the \nameref{ref:extensionality-axiom}, it follows $B = B'$. - Since $B' \in P$, it also follows $B \in P$. - - \paragraph{($\Leftarrow$)}% - - Let $B \in \Pi$. - By definition of a \nameref{ref:partition}, $B$ is nonempty. - Let $x \in B$. - By definition of a set, $B = \{t \mid x \in B \land t \in B\}$. - By definition of a \nameref{ref:partition}, every member of $B$ must belong - to only $B$ (i.e. no other sets in the partition). - Thus we can equivalently write - \begin{align*} - B - & = \{t \mid (\exists B_1 \in \Pi)(x \in B_1 \land t \in B_1)\} \\ - & = \{ t \mid \pair{x, t} \in R_\Pi \} \\ - & = [x]_{R_\Pi}. - \end{align*} - Therefore $B \in A / R_{\Pi}$. - -\end{proof} + \end{proof} \subsection{\verified{Exercise 3.39}}% \hyperlabel{sub:exercise-3.39} -Assume that we start with an equivalence relation $R$ on $A$ and define $\Pi$ to - be the partition $A / R$. -Show that $R_\Pi$, as defined in Exercise 37, is just $R$. + Assume that we start with an equivalence relation $R$ on $A$ and define $\Pi$ + to be the partition $A / R$. + Show that $R_\Pi$, as defined in Exercise 37, is just $R$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_39} - By definition, - \begin{equation} - \hyperlabel{sub:exercise-3.39-eq1} - R_\Pi = \{ (x, y) \mid (\exists B \in \Pi)(x \in B \land y \in B) \}. - \end{equation} - We prove that $R_\Pi = R$. - By the \nameref{ref:extensionality-axiom}, these two sets are equal when - $$(x, y) \in R_\Pi \iff (x, y) \in R.$$ - We prove both directions of this biconditional. + \begin{proof} + By definition, + \begin{equation} + \hyperlabel{sub:exercise-3.39-eq1} + R_\Pi = \{ (x, y) \mid (\exists B \in \Pi)(x \in B \land y \in B) \}. + \end{equation} + We prove that $R_\Pi = R$. + By the \nameref{ref:extensionality-axiom}, these two sets are equal when + $$(x, y) \in R_\Pi \iff (x, y) \in R.$$ + We prove both directions of this biconditional. - \paragraph{($\Rightarrow$)}% + \paragraph{($\Rightarrow$)}% - Let $(x, y) \in R_\Pi$. - By \eqref{sub:exercise-3.39-eq1}, there exists some $B \in \Pi$ such that - $x \in B$ and $y \in B$. - Since $\Pi = A / R = \{[x]_R \mid x \in A\}$, there must exist some - $z \in A$ such that $B = [z]_R$. - By definition of an \nameref{ref:equivalence-class}, $x \in [z]_R$ implies - that $zRx$ and $y \in [z]_R$ implies $zRy$. - Since $R$ is \nameref{ref:symmetric}, $xRz$. - Since $R$ is \nameref{ref:transitive}, $xRy$. + Let $(x, y) \in R_\Pi$. + By \eqref{sub:exercise-3.39-eq1}, there exists some $B \in \Pi$ such that + $x \in B$ and $y \in B$. + Since $\Pi = A / R = \{[x]_R \mid x \in A\}$, there must exist some + $z \in A$ such that $B = [z]_R$. + By definition of an \nameref{ref:equivalence-class}, $x \in [z]_R$ implies + that $zRx$ and $y \in [z]_R$ implies $zRy$. + Since $R$ is \nameref{ref:symmetric}, $xRz$. + Since $R$ is \nameref{ref:transitive}, $xRy$. - \paragraph{($\Leftarrow$)}% + \paragraph{($\Leftarrow$)}% - Let $(x, y) \in R$. - By definition of an \nameref{ref:equivalence-class}, $x \in [x]_R$ and - $y \in [x]_R$. - Note also that $[x]_R \in A / R = \Pi$. - Thus there exists some $B \in \Pi$ such that $x \in B$ and $y \in B$, namely - $B = [x]_R$. - By \eqref{sub:exercise-3.39-eq1}, $(x, y) \in R_\Pi$. - -\end{proof} + Let $(x, y) \in R$. + By definition of an \nameref{ref:equivalence-class}, $x \in [x]_R$ and + $y \in [x]_R$. + Note also that $[x]_R \in A / R = \Pi$. + Thus there exists some $B \in \Pi$ such that $x \in B$ and $y \in B$, + namely $B = [x]_R$. + By \eqref{sub:exercise-3.39-eq1}, $(x, y) \in R_\Pi$. + \end{proof} \subsection{\unverified{Exercise 3.40}}% \hyperlabel{sub:exercise-3.40} -Define an equivalence relation $R$ on the set $P$ of positive integers by - $$mRn \iff m \text{ and } n \text{ have the same number of prime factors}.$$ -Is there a function $f \colon P / R \rightarrow P / R$ such that - $f([n]_R) = [3n]_R$ for each $n$? + Define an equivalence relation $R$ on the set $P$ of positive integers by + $$mRn \iff m \text{ and } n \text{ have the same number of prime factors}.$$ + Is there a function $f \colon P / R \rightarrow P / R$ such that + $f([n]_R) = [3n]_R$ for each $n$? -\begin{proof} + \begin{proof} + Define $g \colon P \rightarrow P$ as $g(x) = 3x$ for all $x \in P$. + We first show that $g$ is \nameref{ref:compatible} with $R$. + Let $m, n \in P$ such that $mRn$. + Then $m$ and $n$ have the same prime factors. + Then $3m$ has one additional prime factor than $m$, namely $3$. + Likewise $3n$ has one additional prime factor than $n$, also $3$. + Thus $(3m)R(3n)$, i.e. $g$ is compatible with $R$. - Define $g \colon P \rightarrow P$ as $g(x) = 3x$ for all $x \in P$. - We first show that $g$ is \nameref{ref:compatible} with $R$. - Let $m, n \in P$ such that $mRn$. - Then $m$ and $n$ have the same prime factors. - Then $3m$ has one additional prime factor than $m$, namely $3$. - Likewise $3n$ has one additional prime factor than $n$, also $3$. - Thus $(3m)R(3n)$, i.e. $g$ is compatible with $R$. - - By \nameref{sub:theorem-3q}, it follows there exists a unique function - $f \colon P / R \rightarrow P / R$ such that $f([n]_R) = [g(n)]_R = [3n]_R$ - as expected. - -\end{proof} + By \nameref{sub:theorem-3q}, it follows there exists a unique function + $f \colon P / R \rightarrow P / R$ such that + $f([n]_R) = [g(n)]_R = [3n]_R$ as expected. + \end{proof} \subsection{\unverified{Exercise 3.41}}% \hyperlabel{sub:exercise-3.41} -Let $\mathbb{R}$ be the set of real numbers and define the relation $Q$ on - $\mathbb{R} \times \mathbb{R}$ by $\pair{u, v}Q\pair{x, y}$ iff - $u + y = x + v$. + Let $\mathbb{R}$ be the set of real numbers and define the relation $Q$ on + $\mathbb{R} \times \mathbb{R}$ by $\pair{u, v}Q\pair{x, y}$ iff + $u + y = x + v$. \subsubsection{\verified{Exercise 3.41a}}% \hyperlabel{ssub:exercise-3.41-a} -Show that $Q$ is an equivalence relation on $\mathbb{R} \times \mathbb{R}$. + Show that $Q$ is an equivalence relation on $\mathbb{R} \times \mathbb{R}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_41\_a} - We show (i) $Q$ is \nameref{ref:reflexive} on $\mathbb{R} \times \mathbb{R}$, - (ii) $Q$ is \nameref{ref:symmetric}, and (iii) $Q$ is - \nameref{ref:transitive}. + \begin{proof} + We show (i) $Q$ is \nameref{ref:reflexive} on + $\mathbb{R} \times \mathbb{R}$, (ii) $Q$ is \nameref{ref:symmetric}, and + (iii) $Q$ is \nameref{ref:transitive}. - \paragraph{(i)}% + \paragraph{(i)}% - Let $\pair{x, y} \in R \times R$. - Since $x + y = x + y$, it immediately follows $\pair{x, y}Q\pair{x, y}$. - Thus $Q$ is reflexive on $\mathbb{R}$. + Let $\pair{x, y} \in R \times R$. + Since $x + y = x + y$, it immediately follows $\pair{x, y}Q\pair{x, y}$. + Thus $Q$ is reflexive on $\mathbb{R}$. - \paragraph{(ii)}% + \paragraph{(ii)}% - Let $\pair{\pair{u, v}, \pair{x, y}} \in Q$. - Then $u + y = x + v$. - Likewise, $x + v = u + y$. - This immediately implies that $\pair{\pair{x, y}, \pair{u, v}} \in Q$. - Thus $Q$ is symmetric. + Let $\pair{\pair{u, v}, \pair{x, y}} \in Q$. + Then $u + y = x + v$. + Likewise, $x + v = u + y$. + This immediately implies that $\pair{\pair{x, y}, \pair{u, v}} \in Q$. + Thus $Q$ is symmetric. - \paragraph{(iii)}% + \paragraph{(iii)}% - Let $\pair{\pair{u, v}, \pair{x, y}} \in Q$ and - $\pair{\pair{x, y}, \pair{a, b}} \in Q$. - Then $u + y = x + v$ and $x + b = a + y$. - Rearranging terms, we have $u - v = x - y$ and $x - y = a - b$. - Thus $u - v = a - b$. - Rearranging terms once more yields $u + b = a + v$. - Thus $\pair{\pair{u, v}, \pair{a, b}} \in Q$. - Therefore $Q$ is transitive. + Let $\pair{\pair{u, v}, \pair{x, y}} \in Q$ and + $\pair{\pair{x, y}, \pair{a, b}} \in Q$. + Then $u + y = x + v$ and $x + b = a + y$. + Rearranging terms, we have $u - v = x - y$ and $x - y = a - b$. + Thus $u - v = a - b$. + Rearranging terms once more yields $u + b = a + v$. + Thus $\pair{\pair{u, v}, \pair{a, b}} \in Q$. + Therefore $Q$ is transitive. -\end{proof} + \end{proof} \subsubsection{\unverified{Exercise 3.41b}}% \hyperlabel{ssub:exercise-3.41-b} -Is there a function $G \colon (\mathbb{R} \times \mathbb{R}) / Q - \rightarrow (\mathbb{R} \times \mathbb{R}) / Q$ satisfying the equation - \begin{equation} - \hyperlabel{ssub:exercise-3.41-b-eq1} - G([\pair{x, y}]_Q) = [\pair{x + 2y, y + 2x}]_Q? - \end{equation} + Is there a function $G \colon (\mathbb{R} \times \mathbb{R}) / Q + \rightarrow (\mathbb{R} \times \mathbb{R}) / Q$ satisfying the equation + \begin{equation} + \hyperlabel{ssub:exercise-3.41-b-eq1} + G([\pair{x, y}]_Q) = [\pair{x + 2y, y + 2x}]_Q? + \end{equation} -\begin{proof} + \begin{proof} + Let $f \colon \mathbb{R} \times \mathbb{R} + \rightarrow \mathbb{R} \times \mathbb{R}$ be given by + $f(\pair{x, y}) = \pair{x + 2y, y + 2x}$. + We show (i) that $f$ is \nameref{ref:compatible} with $Q$ and then (ii) + there exists such a function satisfying \eqref{ssub:exercise-3.41-b-eq1}. - Let $f \colon \mathbb{R} \times \mathbb{R} - \rightarrow \mathbb{R} \times \mathbb{R}$ be given by - $f(\pair{x, y}) = \pair{x + 2y, y + 2x}$. - We show (i) that $f$ is \nameref{ref:compatible} with $Q$ and then (ii) - there exists such a function satisfying \eqref{ssub:exercise-3.41-b-eq1}. + \paragraph{(i)}% + \hyperlabel{par:exercise-3.41-b-i} - \paragraph{(i)}% - \hyperlabel{par:exercise-3.41-b-i} + Let $\pair{u, v}, \pair{x, y} \in \mathbb{R} \times \mathbb{R}$ such that + $\pair{u, v} Q \pair{x, y}$. + Thus + \begin{equation} + \hyperlabel{ssub:exercise-3.41-b-eq2} + u + y = x + v + \end{equation} + Next consider + \begin{align*} + f(\pair{u, v}) & = \pair{u + 2v, v + 2u}, \\ + f(\pair{x, y}) & = \pair{x + 2y, y + 2x}. + \end{align*} + Then + \begin{align*} + u + y & = x + v \\ + \iff 3u + 3y & = 3x + 3v \\ + \iff (u + y) + (2u + 2y) & = (x + v) + (2x + 2v) \\ + \iff (x + v) + (2u + 2y) & = (u + y) + (2x + 2v) + & \eqref{ssub:exercise-3.41-b-eq2} \\ + \iff (x + 2y) + (v + 2u) & = (u + 2v) + (y + 2x) \\ + \iff (u + 2v) + (y + 2x) & = (x + 2y) + (v + 2u). + \end{align*} + This last equality shows $f(\pair{u, v}) \,Q\, f(\pair{x, y})$. + Thus $f$ is compatible with $Q$. - Let $\pair{u, v}, \pair{x, y} \in \mathbb{R} \times \mathbb{R}$ such that - $\pair{u, v} Q \pair{x, y}$. - Thus - \begin{equation} - \hyperlabel{ssub:exercise-3.41-b-eq2} - u + y = x + v - \end{equation} - Next consider - \begin{align*} - f(\pair{u, v}) & = \pair{u + 2v, v + 2u}, \\ - f(\pair{x, y}) & = \pair{x + 2y, y + 2x}. - \end{align*} - Then - \begin{align*} - u + y & = x + v \\ - \iff 3u + 3y & = 3x + 3v \\ - \iff (u + y) + (2u + 2y) & = (x + v) + (2x + 2v) \\ - \iff (x + v) + (2u + 2y) & = (u + y) + (2x + 2v) - & \eqref{ssub:exercise-3.41-b-eq2} \\ - \iff (x + 2y) + (v + 2u) & = (u + 2v) + (y + 2x) \\ - \iff (u + 2v) + (y + 2x) & = (x + 2y) + (v + 2u). - \end{align*} - This last equality shows $f(\pair{u, v}) \,Q\, f(\pair{x, y})$. - Thus $f$ is compatible with $Q$. + \paragraph{(ii)}% - \paragraph{(ii)}% + By \nameref{par:exercise-3.41-b-i} and \nameref{sub:theorem-3q}, there + exists a unique $G \colon (\mathbb{R} \times \mathbb{R}) / Q \rightarrow + (\mathbb{R} \times \mathbb{R}) / Q$ satisfying + \eqref{ssub:exercise-3.41-b-eq1}. - By \nameref{par:exercise-3.41-b-i} and \nameref{sub:theorem-3q}, there - exists a unique $G \colon (\mathbb{R} \times \mathbb{R}) / Q \rightarrow - (\mathbb{R} \times \mathbb{R}) / Q$ satisfying - \eqref{ssub:exercise-3.41-b-eq1}. - -\end{proof} + \end{proof} \subsection{\sorry{Exercise 3.42}}% \hyperlabel{sub:exercise-3.42} -State precisely the "analogous results" mentioned in Theorem 3Q. -(This will require extending the concept of compatibility in a suitable way.) + State precisely the "analogous results" mentioned in Theorem 3Q. + (This will require extending the concept of compatibility in a suitable way.) -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\verified{Exercise 3.43}}% \hyperlabel{sub:exercise-3.43} -Assume that $R$ is a linear ordering on a set $A$. -Show that $R^{-1}$ is also a linear ordering on $A$. + Assume that $R$ is a linear ordering on a set $A$. + Show that $R^{-1}$ is also a linear ordering on $A$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_43} - Assume that $R$ is a \nameref{ref:linear-ordering} on a set $A$. - Then $R$ is \nameref{ref:transitive} and \nameref{ref:trichotomous}. - We show that (i) $R^{-1}$ is transitive and (ii) $R^{-1}$ is trichotomous. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:exercise-3.43-i} + Assume that $R$ is a \nameref{ref:linear-ordering} on a set $A$. + Then $R$ is \nameref{ref:transitive} and \nameref{ref:trichotomous}. + We show that (i) $R^{-1}$ is transitive and (ii) $R^{-1}$ is trichotomous. - Let $\pair{x, y}, \pair{y, z} \in R^{-1}$. - By definition of the \nameref{ref:inverse} of a set, - $\pair{y, x}$, $\pair{z, y} \in R$. - Since $R$ is transitive, it must be that $\pair{z, x} \in R$. - Then $\pair{x, z} \in R^{-1}$. - Thus $R^{-1}$ is transitive. + \paragraph{(i)}% + \hyperlabel{par:exercise-3.43-i} - \paragraph{(ii)}% - \hyperlabel{par:exercise-3.43-ii} + Let $\pair{x, y}, \pair{y, z} \in R^{-1}$. + By definition of the \nameref{ref:inverse} of a set, + $\pair{y, x}$, $\pair{z, y} \in R$. + Since $R$ is transitive, it must be that $\pair{z, x} \in R$. + Then $\pair{x, z} \in R^{-1}$. + Thus $R^{-1}$ is transitive. - Let $x, y \in A$. - Since $R$ is trichotomous on $A$, it follows that exactly one of the - following conditions hold: $$xRy, \quad x = y, \quad yRx.$$ - By definition of the \nameref{ref:inverse} of a set, the above possibilities - are equivalently expressed as - $$yR^{-1}x, \quad x = y, \quad xR^{-1}y.$$ - Thus $R^{-1}$ is trichotomous. + \paragraph{(ii)}% + \hyperlabel{par:exercise-3.43-ii} - \paragraph{Conclusion}% + Let $x, y \in A$. + Since $R$ is trichotomous on $A$, it follows that exactly one of the + following conditions hold: $$xRy, \quad x = y, \quad yRx.$$ + By definition of the \nameref{ref:inverse} of a set, the above + possibilities are equivalently expressed as + $$yR^{-1}x, \quad x = y, \quad xR^{-1}y.$$ + Thus $R^{-1}$ is trichotomous. - Since $R^{-1}$ is transitive by \nameref{par:exercise-3.43-i} and - trichotomous by \nameref{par:exercise-3.43-ii}, it follows $R^{-1}$ is a - linear ordering on $A$. + \paragraph{Conclusion}% -\end{proof} + Since $R^{-1}$ is transitive by \nameref{par:exercise-3.43-i} and + trichotomous by \nameref{par:exercise-3.43-ii}, it follows $R^{-1}$ is a + linear ordering on $A$. + + \end{proof} \subsection{\verified{Exercise 3.44}}% \hyperlabel{sub:exercise-3.44} -Assume that $<$ is a linear ordering on a set $A$. -Assume that $f \colon A \rightarrow A$ and that $f$ has the property that - whenever $x < y$, then $f(x) < f(y)$. -Show that $f$ is one-to-one and that whenever $f(x) < f(y)$, then $x < y$. - -\begin{proof} - - \statementpadding + Assume that $<$ is a linear ordering on a set $A$. + Assume that $f \colon A \rightarrow A$ and that $f$ has the property that + whenever $x < y$, then $f(x) < f(y)$. + Show that $f$ is one-to-one and that whenever $f(x) < f(y)$, then $x < y$. \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_44\_i} @@ -5883,180 +5423,184 @@ Show that $f$ is one-to-one and that whenever $f(x) < f(y)$, then $x < y$. \code{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_44\_ii} - We show that (i) $f$ is one-to-one and (ii) whenever $f(x) < f(y)$, then - $x < y$. + \begin{proof} - \paragraph{(i)}% + We show that (i) $f$ is one-to-one and (ii) whenever $f(x) < f(y)$, then + $x < y$. - Let $y \in \ran{f}$. - By definition of the \nameref{ref:range} of a set, there exists some - $x_1 \in A$ such that $f(x_1) = y$. - Suppose there exists some $x_2 \in A$ such that $f(x_2) = y$. - We prove $f$ is one-to-one by showing $x_1 = x_2$. - Because $<$ is a linear ordering on $A$, there exist three cases to - consider: + \paragraph{(i)}% - \subparagraph{Case 1}% + Let $y \in \ran{f}$. + By definition of the \nameref{ref:range} of a set, there exists some + $x_1 \in A$ such that $f(x_1) = y$. + Suppose there exists some $x_2 \in A$ such that $f(x_2) = y$. + We prove $f$ is one-to-one by showing $x_1 = x_2$. + Because $<$ is a linear ordering on $A$, there exist three cases to + consider: - Assume $x_1 < x_2$. - By hypothesis, $f$ is monotonic. - Thus $f(x_1) < f(x_2)$. - But $<$ is a trichotomous relation meaning it is not possible for - \textit{both} $f(x) = f(y)$ and $f(x) < f(y)$. - Thus our original assumption must be wrong. + \subparagraph{Case 1}% - \subparagraph{Case 2}% + Assume $x_1 < x_2$. + By hypothesis, $f$ is monotonic. + Thus $f(x_1) < f(x_2)$. + But $<$ is a trichotomous relation meaning it is not possible for + \textit{both} $f(x) = f(y)$ and $f(x) < f(y)$. + Thus our original assumption must be wrong. - Assume $x_1 = x_2$. - Then we are immediately finished. + \subparagraph{Case 2}% - \subparagraph{Case 3}% + Assume $x_1 = x_2$. + Then we are immediately finished. - Assume $x_1 > x_2$. - By hypothesis, $f$ is monotonic. - Thus $f(x_1) > f(x_2)$. - But $<$ is a trichotomous relation meaning it is not possible for - \textit{both} $f(x) = f(y)$ and $f(x) > f(y)$. - Thus our original assumption must be wrong. + \subparagraph{Case 3}% - \subparagraph{Conclusion}% + Assume $x_1 > x_2$. + By hypothesis, $f$ is monotonic. + Thus $f(x_1) > f(x_2)$. + But $<$ is a trichotomous relation meaning it is not possible for + \textit{both} $f(x) = f(y)$ and $f(x) > f(y)$. + Thus our original assumption must be wrong. - Since the above cases are exhaustive, the only possibility is $x_1 = x_2$. - Thus $f$ is one-to-one. + \subparagraph{Conclusion}% - \paragraph{(ii)}% + Since the above cases are exhaustive, the only possibility is + $x_1 = x_2$. + Thus $f$ is one-to-one. - Suppose $f(x) < f(y)$. - There are three cases to consider: + \paragraph{(ii)}% - \subparagraph{Case 1}% + Suppose $f(x) < f(y)$. + There are three cases to consider: - Assume $x < y$. - Then we are immediately finished. + \subparagraph{Case 1}% - \subparagraph{Case 2}% + Assume $x < y$. + Then we are immediately finished. - Assume $x = y$. - Then $f(x) = f(y)$. - But $<$ is a trichotomous relation meaning it is not possible for - \textit{both} $f(x) = f(y)$ and $f(x) < f(y)$. - Thus our original assumption must be wrong. + \subparagraph{Case 2}% - \subparagraph{Case 3}% + Assume $x = y$. + Then $f(x) = f(y)$. + But $<$ is a trichotomous relation meaning it is not possible for + \textit{both} $f(x) = f(y)$ and $f(x) < f(y)$. + Thus our original assumption must be wrong. - Assume $x > y$. - By hypothesis, $f$ is monotonic. - Thus $f(x) > f(y)$. - But $<$ is a trichotomous relation meaning it is not possible for - \textit{both} $f(x) < f(y)$ and $f(x) > f(y)$. - Thus our original assumption must be wrong. + \subparagraph{Case 3}% - \subparagraph{Conclusion}% + Assume $x > y$. + By hypothesis, $f$ is monotonic. + Thus $f(x) > f(y)$. + But $<$ is a trichotomous relation meaning it is not possible for + \textit{both} $f(x) < f(y)$ and $f(x) > f(y)$. + Thus our original assumption must be wrong. - Since the above cases are exhaustive, the only possibility is $x < y$. + \subparagraph{Conclusion}% -\end{proof} + Since the above cases are exhaustive, the only possibility is $x < y$. + + \end{proof} \subsection{\verified{Exercise 3.45}}% \hyperlabel{sub:exercise-3.45} -Assume that $<_A$ and $<_B$ are linear orderings on $A$ and $B$, respectively. -Define the binary relation $<_L$ on the Cartesian product $A \times B$ by: - $$\pair{a_1, b_1} <_L \pair{a_2, b_2} \quad\text{iff}\quad - \text{either } a_1 <_A a_2 \text{ or } (a_1 = a_2 \land b_1 <_B b_2).$$ -Show that $<_L$ is a linear ordering on $A \times B$. -(The relation $<_L$ is called \textit{lexicographic} ordering, being the - ordering used in making dictionaries.) + Assume that $<_A$ and $<_B$ are linear orderings on $A$ and $B$, respectively. + Define the binary relation $<_L$ on the Cartesian product $A \times B$ by: + $$\pair{a_1, b_1} <_L \pair{a_2, b_2} \quad\text{iff}\quad + \text{either } a_1 <_A a_2 \text{ or } (a_1 = a_2 \land b_1 <_B b_2).$$ + Show that $<_L$ is a linear ordering on $A \times B$. + (The relation $<_L$ is called \textit{lexicographic} ordering, being the + ordering used in making dictionaries.) -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_3} + \code*{Bookshelf/Enderton/Set/Chapter\_3} {Enderton.Set.Chapter\_3.exercise\_3\_45} - We show that $<_L$ is (i) \nameref{ref:transitive} and (ii) - \nameref{ref:trichotomous} on $A \times B$. + \begin{proof} - \paragraph{(i)}% + We show that $<_L$ is (i) \nameref{ref:transitive} and (ii) + \nameref{ref:trichotomous} on $A \times B$. - Let $\pair{a_1, b_1} <_L \pair{a_2, b_2}$ and - $\pair{a_2, b_2} <_L \pair{a_3, b_3}$. - Then either $a_1 <_A a_2$ or $a_1 = a_2 \land b_1 <_B b_2$. - Likewise, either $a_2 <_A a_3$ or $a_2 = a_3 \land b_2 <_B b_3$. - We consider each combination of cases in turn: + \paragraph{(i)}% - \subparagraph{Case 1}% + Let $\pair{a_1, b_1} <_L \pair{a_2, b_2}$ and + $\pair{a_2, b_2} <_L \pair{a_3, b_3}$. + Then either $a_1 <_A a_2$ or $a_1 = a_2 \land b_1 <_B b_2$. + Likewise, either $a_2 <_A a_3$ or $a_2 = a_3 \land b_2 <_B b_3$. + We consider each combination of cases in turn: - Suppose $a_1 <_A a_2$ and $a_2 <_A a_3$. - Since $<_A$ is a linear ordering, it follows $<_A$ is transitive. - Thus $a_1 <_A a_3$. - Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. + \subparagraph{Case 1}% - \subparagraph{Case 2}% + Suppose $a_1 <_A a_2$ and $a_2 <_A a_3$. + Since $<_A$ is a linear ordering, it follows $<_A$ is transitive. + Thus $a_1 <_A a_3$. + Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. - Suppose $a_1 <_A a_2$, $a_2 = a_3$, and $b_2 <_B b_3$. - Then $a_1 < a_3$. - Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. + \subparagraph{Case 2}% - \subparagraph{Case 3}% + Suppose $a_1 <_A a_2$, $a_2 = a_3$, and $b_2 <_B b_3$. + Then $a_1 < a_3$. + Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. - Suppose $a_1 = a_2$, $b_1 <_B b_2$, and $a_2 <_A a_3$. - Then $a_1 <_A a_3$. - Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. + \subparagraph{Case 3}% - \subparagraph{Case 4}% + Suppose $a_1 = a_2$, $b_1 <_B b_2$, and $a_2 <_A a_3$. + Then $a_1 <_A a_3$. + Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. - Suppose $a_1 = a_2$, $b_1 <_B b_2$, $a_2 = a_3$, and $b_2 <_B b_3$. - Then $a_1 = a_3$. - Since $<_B$ is a linear ordering, it follows $<_B$ is transitive. - Thus $b_1 <_B b_3$. - Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. + \subparagraph{Case 4}% - \subparagraph{Conclusion}% + Suppose $a_1 = a_2$, $b_1 <_B b_2$, $a_2 = a_3$, and $b_2 <_B b_3$. + Then $a_1 = a_3$. + Since $<_B$ is a linear ordering, it follows $<_B$ is transitive. + Thus $b_1 <_B b_3$. + Therefore $\pair{a_1, b_2} <_L \pair{a_3, b_3}$. - These four cases are exhaustive and each conclude that $<_L$ is - transitive. + \subparagraph{Conclusion}% - \paragraph{(ii)}% + These four cases are exhaustive and each conclude that $<_L$ is + transitive. - Let $\pair{a_1, b_1}, \pair{a_2, b_2} \in A \times B$. - Because $<_A$ and $<_B$ are linear orderings on $A$ and $B$ respectively, - it follows $<_A$ and $<_B$ are both trichotomous on their respective sets. - Thus exactly one of $$a_1 <_A a_2, \quad a_1 = a_2, \quad a_2 <_A a_1$$ - and $$b_1 <_B b_2, \quad b_1 = b_2, \quad b_2 <_B b_1$$ holds. - There are three cases we examine: + \paragraph{(ii)}% - \subparagraph{Case 1}% - \hyperlabel{spar:exercise-3.45-ii-case-1} + Let $\pair{a_1, b_1}, \pair{a_2, b_2} \in A \times B$. + Because $<_A$ and $<_B$ are linear orderings on $A$ and $B$ respectively, + it follows $<_A$ and $<_B$ are both trichotomous on their respective + sets. + Thus exactly one of $$a_1 <_A a_2, \quad a_1 = a_2, \quad a_2 <_A a_1$$ + and $$b_1 <_B b_2, \quad b_1 = b_2, \quad b_2 <_B b_1$$ holds. + There are three cases we examine: - Suppose $a_1 <_A a_2$. - Then $\pair{a_1, b_1} <_L \pair{a_2, b_2}$. - This is trivially the only possible relationship between the ordered - pairs. + \subparagraph{Case 1}% + \hyperlabel{spar:exercise-3.45-ii-case-1} - \subparagraph{Case 2}% + Suppose $a_1 <_A a_2$. + Then $\pair{a_1, b_1} <_L \pair{a_2, b_2}$. + This is trivially the only possible relationship between the ordered + pairs. - Suppose $a_1 = a_2$. - If $b_1 <_B b_2$, then $\pair{a_1, b_1} <_L \pair{a_2, b_2}$ is the only - possibility. - If $b_1 = b_2$, then $\pair{a_1, b_1} = \pair{a_2, b_2}$ is the only - possibility. - If $b_2 <_B b_1$, then $\pair{a_2, b_2} <_L \pair{a_1, b_1}$ is the only - possibility. + \subparagraph{Case 2}% - \subparagraph{Case 3}% + Suppose $a_1 = a_2$. + If $b_1 <_B b_2$, then $\pair{a_1, b_1} <_L \pair{a_2, b_2}$ is the only + possibility. + If $b_1 = b_2$, then $\pair{a_1, b_1} = \pair{a_2, b_2}$ is the only + possibility. + If $b_2 <_B b_1$, then $\pair{a_2, b_2} <_L \pair{a_1, b_1}$ is the only + possibility. - Suppose $a_2 <_A a_1$. - This case is analagous to \eqref{spar:exercise-3.45-ii-case-1}. + \subparagraph{Case 3}% - \subparagraph{Conclusion}% + Suppose $a_2 <_A a_1$. + This case is analagous to \eqref{spar:exercise-3.45-ii-case-1}. - In each of the above cases, we are always left with exactly one of - $$\pair{a_1, b_1} <_L \pair{a_2, b_2}, \quad - \pair{a_1, b_1} = \pair{a_2, b_2}, \quad - \pair{a_2, b_2} <_L \pair{a_1, b_1}.$$ - Thus $<_L$ is trichotomous. + \subparagraph{Conclusion}% -\end{proof} + In each of the above cases, we are always left with exactly one of + $$\pair{a_1, b_1} <_L \pair{a_2, b_2}, \quad + \pair{a_1, b_1} = \pair{a_2, b_2}, \quad + \pair{a_2, b_2} <_L \pair{a_1, b_1}.$$ + Thus $<_L$ is trichotomous. + + \end{proof} \chapter{Natural Numbers}% \hyperlabel{chap:natural-numbers} @@ -6067,92 +5611,83 @@ Show that $<_L$ is a linear ordering on $A \times B$. \subsection{\unverified{Theorem 4A}}% \hyperlabel{sub:theorem-4a} -\begin{theorem}[4A] + \begin{theorem}[4A] + There is a set whose members are exactly the natural numbers. + \end{theorem} - There is a set whose members are exactly the natural numbers. - -\end{theorem} - -\begin{proof} - - By the \nameref{ref:infinity-axiom}, there exists an - \nameref{ref:inductive-set} $A$. - By the \nameref{ref:subset-axioms}, there exists a set $B$ such that - $$x \in B \iff x \in A \land \left[\forall C, - (\emptyset \in C \land - (\forall c \in C) c^+ \in C) \Rightarrow x \in C\right].$$ - In other words, $x \in B$ if and only if $x \in A$ and $x$ is a natural - number. - Thus $B$ is the set whose members are exactly the natural numbers. - -\end{proof} + \begin{proof} + By the \nameref{ref:infinity-axiom}, there exists an + \nameref{ref:inductive-set} $A$. + By the \nameref{ref:subset-axioms}, there exists a set $B$ such that + $$x \in B \iff x \in A \land \left[\forall C, + (\emptyset \in C \land + (\forall c \in C) c^+ \in C) \Rightarrow x \in C\right].$$ + In other words, $x \in B$ if and only if $x \in A$ and $x$ is a natural + number. + Thus $B$ is the set whose members are exactly the natural numbers. + \end{proof} \subsection{\unverified{Theorem 4B}}% \hyperlabel{sub:theorem-4b} -\begin{theorem}[4B] + \begin{theorem}[4B] + $\omega$ is inductive, and is a subset of every other inductive set. + \end{theorem} - $\omega$ is inductive, and is a subset of every other inductive set. + \begin{proof} -\end{theorem} + $\omega$ denotes the set of \nameref{ref:natural-number}s. + We show $\omega$ is an \nameref{ref:inductive-set} by proving (i) + $\emptyset \in \omega$ and (ii) $\omega$ is closed under + \nameref{ref:successor}. -\begin{proof} + \paragraph{(i)}% + \hyperlabel{par:theorem-4b-i} - $\omega$ denotes the set of \nameref{ref:natural-number}s. - We show $\omega$ is an \nameref{ref:inductive-set} by proving (i) - $\emptyset \in \omega$ and (ii) $\omega$ is closed under - \nameref{ref:successor}. + By definition, $\emptyset$ is a member of every inductive set. + Thus $\emptyset$ is a natural number, i.e. a member of $\omega$. - \paragraph{(i)}% - \hyperlabel{par:theorem-4b-i} + \paragraph{(ii)}% + \hyperlabel{par:theorem-4b-ii} - By definition, $\emptyset$ is a member of every inductive set. - Thus $\emptyset$ is a natural number, i.e. a member of $\omega$. + Let $n \in \omega$. + That is, let $n$ be a natural number. + By definition, $n$ is a member of every inductive set. + By definition of an inductive set, $n^+$ is then a member of every + inductive set as well. + Thus $n^+$ is a natural number, i.e. $n^+ \in \omega$. - \paragraph{(ii)}% - \hyperlabel{par:theorem-4b-ii} + \paragraph{Conclusion}% - Let $n \in \omega$. - That is, let $n$ be a natural number. - By definition, $n$ is a member of every inductive set. - By definition of an inductive set, $n^+$ is then a member of every inductive - set as well. - Thus $n^+$ is a natural number, i.e. $n^+ \in \omega$. + By \nameref{par:theorem-4b-i} and \nameref{par:theorem-4b-ii}, it follows + $\omega$ is inductive. + It follows immediately from the definition of a natural number that + $\omega$ is a subset of every other inductive set. - \paragraph{Conclusion}% - - By \nameref{par:theorem-4b-i} and \nameref{par:theorem-4b-ii}, it follows - $\omega$ is inductive. - It follows immediately from the definition of a natural number that $\omega$ - is a subset of every other inductive set. - -\end{proof} + \end{proof} \subsection{\verified{Theorem 4C}}% \hyperlabel{sub:theorem-4c} -\begin{theorem}[4C] - - Every natural number except $0$ is the successor of some natural number. - -\end{theorem} - -\begin{proof} + \begin{theorem}[4C] + Every natural number except $0$ is the successor of some natural number. + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_4} {Enderton.Set.Chapter\_4.theorem\_4c} - Let $T = \{n \mid n = 0 \lor (\exists m) n = m^+\}$. - It trivially follows that $\emptyset \in T$. - Let $x \in T$. - Then $x^+ \in T$ since $(\exists m) x^+ = m^+$, namely $m = x$. - Therefore $T$ is inductive. - By \nameref{sub:theorem-4b}, $\omega$ is a subset of $T$. - Thus every natural number satisfies the condition written in $T$'s definition. - In other words, every natural number except $0$ is the successor of some - natural number. - -\end{proof} + \begin{proof} + Let $T = \{n \mid n = 0 \lor (\exists m) n = m^+\}$. + It trivially follows that $\emptyset \in T$. + Let $x \in T$. + Then $x^+ \in T$ since $(\exists m) x^+ = m^+$, namely $m = x$. + Therefore $T$ is inductive. + By \nameref{sub:theorem-4b}, $\omega$ is a subset of $T$. + Thus every natural number satisfies the condition written in $T$'s + definition. + In other words, every natural number except $0$ is the successor of some + natural number. + \end{proof} \section{Peano's Postulates}% \hyperlabel{sec:peanos-postulates} @@ -6160,172 +5695,165 @@ Show that $<_L$ is a linear ordering on $A \times B$. \subsection{\unverified{Theorem 4E}}% \hyperlabel{sub:theorem-4e} -\begin{theorem}[4E] + \begin{theorem}[4E] + For a transitive set $a$, $$\bigcup \left(a^+\right) = a.$$ + \end{theorem} - For a transitive set $a$, $$\bigcup \left(a^+\right) = a.$$ + \begin{proof} -\end{theorem} + Let $a$ be a \nameref{ref:transitive-set}. + We show that + \begin{equation} + \hyperlabel{sub:theorem-4e-eq1} + x \in \bigcup \left(a^+\right) \iff x \in a. + \end{equation} -\begin{proof} + \paragraph{($\Rightarrow$)}% - Let $a$ be a \nameref{ref:transitive-set}. - We show that - \begin{equation} - \hyperlabel{sub:theorem-4e-eq1} - x \in \bigcup \left(a^+\right) \iff x \in a. - \end{equation} + Suppose $x \in \bigcup \left(a^+\right)$. + By definition of \nameref{ref:successor}, + $x \in \bigcup \left(a \cup \{a\}\right)$. + Then there exists some $b \in a \cup \{a\}$ such that $x \in b$. + There are two cases to consider: - \paragraph{($\Rightarrow$)}% + \subparagraph{Case 1}% - Suppose $x \in \bigcup \left(a^+\right)$. - By definition of \nameref{ref:successor}, - $x \in \bigcup \left(a \cup \{a\}\right)$. - Then there exists some $b \in a \cup \{a\}$ such that $x \in b$. - There are two cases to consider: + Suppose $b \in a$. + By definition of a transitive set, $x \in b \in a$ means $x \in a$. - \subparagraph{Case 1}% + \subparagraph{Case 2}% - Suppose $b \in a$. - By definition of a transitive set, $x \in b \in a$ means $x \in a$. + Suppose $b \in \{a\}$. + Then $b = a$ and immediately $x \in b = a$. - \subparagraph{Case 2}% + \paragraph{($\Leftarrow$)}% - Suppose $b \in \{a\}$. - Then $b = a$ and immediately $x \in b = a$. + Suppose $x \in a$. + Then immediately $x \in a \cup \{a\}$. + Thus there exists some $b$ such that $b \in a \cup \{a\}$ and $x \in b$, + namely $b = \{a\}$. + Thus $x \in \bigcup \left(a^+\right)$. - \paragraph{($\Leftarrow$)}% + \paragraph{Conclusion}% - Suppose $x \in a$. - Then immediately $x \in a \cup \{a\}$. - Thus there exists some $b$ such that $b \in a \cup \{a\}$ and $x \in b$, - namely $b = \{a\}$. - Thus $x \in \bigcup \left(a^+\right)$. + We have shown both sides of \eqref{sub:theorem-4e-eq1} holds. + By the \nameref{ref:extensionality-axiom}, $\bigcup \left(a^+\right) = a$. - \paragraph{Conclusion}% - - We have shown both sides of \eqref{sub:theorem-4e-eq1} holds. - By the \nameref{ref:extensionality-axiom}, $\bigcup \left(a^+\right) = a$. - -\end{proof} + \end{proof} \subsection{\unverified{Theorem 4F}}% \hyperlabel{sub:theorem-4f} -\begin{theorem}[4F] + \begin{theorem}[4F] + Every natural number is a transitive set. + \end{theorem} - Every natural number is a transitive set. + \begin{proof} -\end{theorem} + Let $T = \{n \in \omega \mid n \text{ is a transitive set}\}$. + We (i) prove that $T$ is an \nameref{ref:inductive-set} and then (ii) every + natural number is a transitive set. -\begin{proof} + \paragraph{(i)}% + \hyperlabel{par:theorem-4f-i} - Let $T = \{n \in \omega \mid n \text{ is a transitive set}\}$. - We (i) prove that $T$ is an \nameref{ref:inductive-set} and then (ii) every - natural number is a transitive set. + First, $\emptyset \in T$ since it vacuously holds that a member of a + member of $\emptyset$ is itself a member of $\emptyset$. + Next, let $n \in T$ and consider whether $n^+ \in T$. + Since $n$ is a transitive set, \nameref{sub:theorem-4e} implies + $\bigcup \left(n^+\right) = n$. + But $n \subseteq n^+ = n \cup \{n\}$. + Thus $\bigcup \left(n^+\right) \subseteq n+$, i.e. $n^+$ is a transitive + set. + Therefore $n^+ \in T$. + Hence $T$ is inductive. - \paragraph{(i)}% - \hyperlabel{par:theorem-4f-i} + \paragraph{(ii)}% - First, $\emptyset \in T$ since it vacuously holds that a member of a - member of $\emptyset$ is itself a member of $\emptyset$. - Next, let $n \in T$ and consider whether $n^+ \in T$. - Since $n$ is a transitive set, \nameref{sub:theorem-4e} implies - $\bigcup \left(n^+\right) = n$. - But $n \subseteq n^+ = n \cup \{n\}$. - Thus $\bigcup \left(n^+\right) \subseteq n+$, i.e. $n^+$ is a transitive - set. - Therefore $n^+ \in T$. - Hence $T$ is inductive. + Notice $T \subseteq \omega$. + By \nameref{par:theorem-4f-i} and \nameref{sub:theorem-4b}, $T = \omega$. + Thus every natural number is a transitive set. - \paragraph{(ii)}% - - Notice $T \subseteq \omega$. - By \nameref{par:theorem-4f-i} and \nameref{sub:theorem-4b}, $T = \omega$. - Thus every natural number is a transitive set. - -\end{proof} + \end{proof} \subsection{\verified{Theorem 4D}}% \hyperlabel{sub:theorem-4d} -\begin{theorem}[4D] + \begin{theorem}[4D] + $\langle \omega, \sigma, 0 \rangle$ is a Peano system. + \end{theorem} - $\langle \omega, \sigma, 0 \rangle$ is a Peano system. - -\end{theorem} - -\begin{note} - This theorem depends on \nameref{sub:theorem-4e} and \nameref{sub:theorem-4f}. -\end{note} - -\begin{proof} + \begin{note} + This theorem depends on \nameref{sub:theorem-4e} and + \nameref{sub:theorem-4f}. + \end{note} \code{Common/Set/Peano}{Peano.instSystemNatUnivSuccOfNatInstOfNatNat} - Note $\sigma$ is defined as $\sigma = \{\pair{n, n^+} \mid n \in \omega\}$. - To prove $\langle \omega, \sigma, 0 \rangle$ is a \nameref{ref:peano-system}, - we must show that (i) $0 \not\in \ran{S}$, (ii) $\sigma$ is one-to-one, and - (iii) every subset $A$ of $\omega$ containing $0$ and closed under $\sigma$ - is $\omega$ itself. + \begin{proof} - \paragraph{(i)}% + Note $\sigma$ is defined as $\sigma = \{\pair{n, n^+} \mid n \in \omega\}$. + To prove $\langle \omega, \sigma, 0 \rangle$ is a + \nameref{ref:peano-system}, we must show that (i) $0 \not\in \ran{S}$, + (ii) $\sigma$ is one-to-one, and (iii) every subset $A$ of $\omega$ + containing $0$ and closed under $\sigma$ is $\omega$ itself. - This follows immediately from \nameref{sub:theorem-4c}. + \paragraph{(i)}% - \paragraph{(ii)}% + This follows immediately from \nameref{sub:theorem-4c}. - Let $m, n \in \omega$ and suppose $m^+ = n^+$. - Then $\bigcup \left(m^+\right) = \bigcup \left(n^+\right)$. - By \nameref{sub:theorem-4f}, every natural number is a - \nameref{ref:transitive-set}. - Therefore, by \nameref{sub:theorem-4e}, - $$\bigcup \left(m^+\right) = m = \bigcup \left(n^+\right) = n.$$ + \paragraph{(ii)}% - \paragraph{(iii)}% + Let $m, n \in \omega$ and suppose $m^+ = n^+$. + Then $\bigcup \left(m^+\right) = \bigcup \left(n^+\right)$. + By \nameref{sub:theorem-4f}, every natural number is a + \nameref{ref:transitive-set}. + Therefore, by \nameref{sub:theorem-4e}, + $$\bigcup \left(m^+\right) = m = \bigcup \left(n^+\right) = n.$$ - This follows immediately from \nameref{sub:theorem-4b}. + \paragraph{(iii)}% -\end{proof} + This follows immediately from \nameref{sub:theorem-4b}. + + \end{proof} \subsection{\unverified{Theorem 4G}}% \hyperlabel{sub:theorem-4g} -\begin{theorem}[4G] + \begin{theorem}[4G] + The set $\omega$ is a transitive set. + \end{theorem} - The set $\omega$ is a transitive set. + \begin{proof} -\end{theorem} + Let $T = \{n \in \omega \mid \forall t \in n, t \in \omega\}$. + We prove that (i) $T$ is an \nameref{ref:inductive-set} and then (ii) every + member of a natural number is itself a natural number. -\begin{proof} + \paragraph{(i)}% + \hyperlabel{par:theorem-4g-i} - Let $T = \{n \in \omega \mid \forall t \in n, t \in \omega\}$. - We prove that (i) $T$ is an \nameref{ref:inductive-set} and then (ii) every - member of a natural number is itself a natural number. + First, it vacuously holds that $\emptyset \in T$. + Next, let $n \in T$. + We must prove that $n^+ \in T$ as well. + By definition of the \nameref{ref:successor}, $n^+ = n \cup \{n\}$. + That is, either $n^+ = n$ or $n^+ = \{n\}$. + If the former, then every member of $n^+$ must be a natural number since + this already holds for $n$. + If the latter, the only member of $n^+$ is $n$ which is, by definition of + $T$, a natural number. + Thus $n^+ \in T$. + We conclude that $T$ is an inductive set. - \paragraph{(i)}% - \hyperlabel{par:theorem-4g-i} + \paragraph{(ii)}% - First, it vacuously holds that $\emptyset \in T$. - Next, let $n \in T$. - We must prove that $n^+ \in T$ as well. - By definition of the \nameref{ref:successor}, $n^+ = n \cup \{n\}$. - That is, either $n^+ = n$ or $n^+ = \{n\}$. - If the former, then every member of $n^+$ must be a natural number since - this already holds for $n$. - If the latter, the only member of $n^+$ is $n$ which is, by definition of - $T$, a natural number. - Thus $n^+ \in T$. - We conclude that $T$ is an inductive set. + Since $T \subseteq \omega$, \nameref{par:theorem-4g-i} and + \nameref{sub:theorem-4b} implies $T = \omega$. + Thus the member of every natural number is itself a natural number. + In other words, $\bigcup \omega \subseteq \omega$. + Therefore $\omega$ is indeed a \nameref{ref:transitive-set}. - \paragraph{(ii)}% - - Since $T \subseteq \omega$, \nameref{par:theorem-4g-i} and - \nameref{sub:theorem-4b} implies $T = \omega$. - Thus the member of every natural number is itself a natural number. - In other words, $\bigcup \omega \subseteq \omega$. - Therefore $\omega$ is indeed a \nameref{ref:transitive-set}. - -\end{proof} + \end{proof} \section{Recursion on \texorpdfstring{$\omega$}{the Natural Numbers}}% \hyperlabel{sec:recursion-natural-numbers} @@ -6334,202 +5862,198 @@ Show that $<_L$ is a linear ordering on $A \times B$. Recursion Theorem on \texorpdfstring{$\omega$}{the Natural Numbers}}}% \hyperlabel{sub:recursion-theorem-natural-numbers} -\begin{theorem} + \begin{theorem} + Let $A$ be a set, $a \in A$, and $F \colon A \rightarrow A$. + Then there exists a unique function $h \colon \omega \rightarrow A$ such + that $$h(0) = a,$$ and for every $n \in \omega$, $$h(n^+) = F(h(n)).$$ + \end{theorem} - Let $A$ be a set, $a \in A$, and $F \colon A \rightarrow A$. - Then there exists a unique function $h \colon \omega \rightarrow A$ such that - $$h(0) = a,$$ and for every $n \in \omega$, $$h(n^+) = F(h(n)).$$ + \begin{note} + This proof was written a few days after reading Enderton's proof as a means + of ensuring I remember the main arguments. + \end{note} -\end{theorem} + \begin{proof} -\begin{note} - This proof was written a few days after reading Enderton's proof as a means of - ensuring I remember the main arguments. -\end{note} + Define set + \begin{align*} + H = \{ v \mid & v \text{ is a function with } \\ + & \text{(a) } \dom{v} \subseteq \omega, \\ + & \text{(b) } \ran{v} \subseteq A, \\ + & \text{(c) if } 0 \in \dom{v}, \text{ then } v(0) = a, \text{ and} \\ + & \text{(d) if } n^+ \in \dom{v}, + \text{ then } n \in \dom{v} \text{ and } v(n^+) = F(v(n)) + \}. + \end{align*} + Define a function satisfying properties (a)-(d) above as + \textit{acceptable}. + That is, $H$ is the set of all acceptable functions. + Define $h = \bigcup H$. + We prove that (i) $h$ is a \nameref{ref:function}, (ii) $h \in H$, (iii) + $\dom{h} = \omega$, and (iv) $h$ is unique. -\begin{proof} + \paragraph{(i)}% + \hyperlabel{par:recursion-theorem-natural-numbers-i} - Define set - \begin{align*} - H = \{ v \mid & v \text{ is a function with } \\ - & \text{(a) } \dom{v} \subseteq \omega, \\ - & \text{(b) } \ran{v} \subseteq A, \\ - & \text{(c) if } 0 \in \dom{v}, \text{ then } v(0) = a, \text{ and} \\ - & \text{(d) if } n^+ \in \dom{v}, - \text{ then } n \in \dom{v} \text{ and } v(n^+) = F(v(n)) - \}. - \end{align*} - Define a function satisfying properties (a)-(d) above as \textit{acceptable}. - That is, $H$ is the set of all acceptable functions. - Define $h = \bigcup H$. - We prove that (i) $h$ is a \nameref{ref:function}, (ii) $h \in H$, (iii) - $\dom{h} = \omega$, and (iv) $h$ is unique. + We prove that $h$ is a function. + Consider set + $$S = \{x \in \omega \mid h(x) = y \text{ for at most one value } y\}.$$ + We show (1) that $0 \in S$ and (2) if $n \in S$ then $n^+ \in S$. - \paragraph{(i)}% - \hyperlabel{par:recursion-theorem-natural-numbers-i} + \subparagraph{(1)}% + \hyperlabel{spar:recursion-theorem-natural-numbers-i-1} - We prove that $h$ is a function. - Consider set - $$S = \{x \in \omega \mid h(x) = y \text{ for at most one value } y\}.$$ - We show (1) that $0 \in S$ and (2) if $n \in S$ then $n^+ \in S$. + Suppose $0 \in \dom{h}$. + By construction, there must exist some $y_1 \in A$ and acceptable + function $v_1$ such that $v_1(0) = y_1$. + Suppose there also exists a $y_2 \in A$ and acceptable function $v_2$ + such that $v_2(0) = y_2$. + By property (c), $v_1(0) = a$ and $v_2(0) = a$. + Thus $y_1 = a = y_2$ and $h(0) = a$. + Therefore $0 \in S$. - \subparagraph{(1)}% - \hyperlabel{spar:recursion-theorem-natural-numbers-i-1} + \subparagraph{(2)}% + \hyperlabel{spar:recursion-theorem-natural-numbers-i-2} - Suppose $0 \in \dom{h}$. - By construction, there must exist some $y_1 \in A$ and acceptable function - $v_1$ such that $v_1(0) = y_1$. - Suppose there also exists a $y_2 \in A$ and acceptable function $v_2$ such - that $v_2(0) = y_2$. - By property (c), $v_1(0) = a$ and $v_2(0) = a$. - Thus $y_1 = a = y_2$ and $h(0) = a$. - Therefore $0 \in S$. + Suppose $n$ and $n^+$ are members of $\dom{h}$. + By construction, there must exist some $y_1 \in A$ and acceptable + function $v_1$ such that $v_1(n^+) = y_1$. + Suppose there also exists a $y_2 \in A$ and acceptable function $v_2$ + such that $v_2(n^+) = y_2$. + By property (d), it follows $n \in \dom{v_1}$, $n \in \dom{v_2}$, + $v_1(n^+) = F(v_1(n))$, and $v_2(n^+) = F(v_2(n))$. + But $n \in S$ meaning there is at most one value $y$ such that + $v_1(n) = y = v_2(n)$. + Thus $F(v_1(n)) = F(y) = F(v_2(n))$ and $h(n^+) = F(y)$. + Therefore $n^+ \in S$. - \subparagraph{(2)}% - \hyperlabel{spar:recursion-theorem-natural-numbers-i-2} + \subparagraph{Conclusion}% - Suppose $n$ and $n^+$ are members of $\dom{h}$. - By construction, there must exist some $y_1 \in A$ and acceptable function - $v_1$ such that $v_1(n^+) = y_1$. - Suppose there also exists a $y_2 \in A$ and acceptable function $v_2$ such - that $v_2(n^+) = y_2$. - By property (d), it follows $n \in \dom{v_1}$, $n \in \dom{v_2}$, - $v_1(n^+) = F(v_1(n))$, and $v_2(n^+) = F(v_2(n))$. - But $n \in S$ meaning there is at most one value $y$ such that - $v_1(n) = y = v_2(n)$. - Thus $F(v_1(n)) = F(y) = F(v_2(n))$ and $h(n^+) = F(y)$. - Therefore $n^+ \in S$. + By \nameref{spar:recursion-theorem-natural-numbers-i-1} and + \nameref{spar:recursion-theorem-natural-numbers-i-2}, $S$ is an + \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Since $S = \omega$, it follows $h$ has at most one value for every + $x \in \omega$. + In other words, $h$ is a function. - \subparagraph{Conclusion}% + \paragraph{(ii)}% + \hyperlabel{par:recursion-theorem-natural-numbers-ii} - By \nameref{spar:recursion-theorem-natural-numbers-i-1} and - \nameref{spar:recursion-theorem-natural-numbers-i-2}, $S$ is an - \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Since $S = \omega$, it follows $h$ has at most one value for every - $x \in \omega$. - In other words, $h$ is a function. + We now prove $h \in H$, i.e. $h$ is an acceptable function. + It trivially holds that $\dom{h} \subseteq \omega$ and + $\ran{h} \subseteq A$. + Thus we are left with proving properties (c) and (d). - \paragraph{(ii)}% - \hyperlabel{par:recursion-theorem-natural-numbers-ii} + \subparagraph{(c)}% - We now prove $h \in H$, i.e. $h$ is an acceptable function. - It trivially holds that $\dom{h} \subseteq \omega$ and - $\ran{h} \subseteq A$. - Thus we are left with proving properties (c) and (d). + Note $\{\pair{0, a}\}$ is an acceptable function. + Thus $\pair{0, a} \in h$. + By \nameref{par:recursion-theorem-natural-numbers-i}, $h$ is a function. + Therefore $a$ is the only value $h(0)$ takes on. - \subparagraph{(c)}% + \subparagraph{(d)}% - Note $\{\pair{0, a}\}$ is an acceptable function. - Thus $\pair{0, a} \in h$. - By \nameref{par:recursion-theorem-natural-numbers-i}, $h$ is a function. - Therefore $a$ is the only value $h(0)$ takes on. + Suppose $n^+ \in \dom{h}$. + Then there exists some acceptable function $v$ such that + $v(n^+) = h(n^+)$. + By definition of acceptable, $\pair{n, v(n)} \in v$. + Since \nameref{par:recursion-theorem-natural-numbers-i} indicates $h$ is + a function, $n \in \dom{h}$ and $h(n) = v(n)$. + Also by definition of acceptable, $v(n^+) = F(v(n))$. + Therefore $$h(n^+) = v(n^+) = F(v(n)) = F(h(n)).$$ + Hence $h \in H$. - \subparagraph{(d)}% + \paragraph{(iii)}% + \hyperlabel{par:recursion-theorem-natural-numbers-iii} - Suppose $n^+ \in \dom{h}$. - Then there exists some acceptable function $v$ such that - $v(n^+) = h(n^+)$. - By definition of acceptable, $\pair{n, v(n)} \in v$. - Since \nameref{par:recursion-theorem-natural-numbers-i} indicates $h$ is a - function, $n \in \dom{h}$ and $h(n) = v(n)$. - Also by definition of acceptable, $v(n^+) = F(v(n))$. - Therefore $$h(n^+) = v(n^+) = F(v(n)) = F(h(n)).$$ - Hence $h \in H$. + We now prove that $\dom{h} = \omega$. + We show that (1) $0 \in \dom{h}$ and (2) if $n \in \dom{h}$ then + $n^+ \in \dom{h}$. - \paragraph{(iii)}% - \hyperlabel{par:recursion-theorem-natural-numbers-iii} + \subparagraph{(1)}% + \hyperlabel{spar:recursion-theorem-natural-numbers-iii-1} - We now prove that $\dom{h} = \omega$. - We show that (1) $0 \in \dom{h}$ and (2) if $n \in \dom{h}$ then - $n^+ \in \dom{h}$. + We note that $\{\pair{0, a}\}$ is an acceptable function. + By construction of $h$, $0 \in \dom{h}$. - \subparagraph{(1)}% - \label{spar:recursion-theorem-natural-numbers-iii-1} + \subparagraph{(2)}% + \hyperlabel{spar:recursion-theorem-natural-numbers-iii-2} - We note that $\{\pair{0, a}\}$ is an acceptable function. - By construction of $h$, $0 \in \dom{h}$. + Suppose $n \in \dom{h}$. + Since $n \in \dom{h}$ there exists an acceptable function $v$ with + $n \in \dom{v}$. + Define $$v' = v \cup \{\pair{n^+, F(v(n))}\}.$$ + We prove that $v'$ is acceptable: - \subparagraph{(2)}% - \label{spar:recursion-theorem-natural-numbers-iii-2} + \begin{enumerate}[(a)] + \item It trivially holds that $\dom{v'} \subseteq \omega$. + \item It trivially holds that $\ran{v'} \subseteq A$. + \item If $0 \in \dom{v'}$, then $v'(0) = v(0) = a$. + \item + Suppose $m^+ \in \dom{v'}$ for some $m \in \omega$. + If $m^+ = n^+$, then $m = n$ and $v'(m^+) = F(v(m))$ by + construction. + If $m^+ \neq n^+$, then $m^+ \in \dom{v}$. + Since $v$ is an acceptable function, + $v'(m^+) = v(m^+) = F(v(m)) = F(v(m^+))$. + \end{enumerate} + Since $v'$ is acceptable, $n^+ \in \dom{h}$. - Suppose $n \in \dom{h}$. - Since $n \in \dom{h}$ there exists an acceptable function $v$ with - $n \in \dom{v}$. - Define $$v' = v \cup \{\pair{n^+, F(v(n))}\}.$$ - We prove that $v'$ is acceptable: + \subparagraph{Conclusion}% - \begin{enumerate}[(a)] - \item It trivially holds that $\dom{v'} \subseteq \omega$. - \item It trivially holds that $\ran{v'} \subseteq A$. - \item If $0 \in \dom{v'}$, then $v'(0) = v(0) = a$. - \item - Suppose $m^+ \in \dom{v'}$ for some $m \in \omega$. - If $m^+ = n^+$, then $m = n$ and $v'(m^+) = F(v(m))$ by construction. - If $m^+ \neq n^+$, then $m^+ \in \dom{v}$. - Since $v$ is an acceptable function, - $v'(m^+) = v(m^+) = F(v(m)) = F(v(m^+))$. - \end{enumerate} - Since $v'$ is acceptable, $n^+ \in \dom{h}$. + By \nameref{spar:recursion-theorem-natural-numbers-iii-1} and + \nameref{spar:recursion-theorem-natural-numbers-iii-2}, + $\dom{h}$ is an inductive set. + \nameref{sub:theorem-4b} implies $\dom{h} = \omega$. - \subparagraph{Conclusion}% + \paragraph{(iv)}% + \hyperlabel{par:recursion-theorem-natural-numbers-iv} - By \nameref{spar:recursion-theorem-natural-numbers-iii-1} and - \nameref{spar:recursion-theorem-natural-numbers-iii-2}, - $\dom{h}$ is an inductive set. - \nameref{sub:theorem-4b} implies $\dom{h} = \omega$. + We now prove $h$ is a unique function. + Let $h_1$ and $h_2$ both satisfy the conclusion of the theorem. + Define $$S = \{n \in \omega \mid h_1(n) = h_2(n)\}.$$ + It suffices to prove $S$ is an inductive set, for \nameref{sub:theorem-4b} + would then imply $S = \omega$, i.e. $h_1$ and $h_2$ agree on all of + $\omega$. - \paragraph{(iv)}% - \label{par:recursion-theorem-natural-numbers-iv} + By definition of an acceptable function, $h_1(0) = a = h_2(0)$ meaning + $0 \in S$. + Next, suppose $n \in S$. + By \nameref{par:recursion-theorem-natural-numbers-iii}, it follows $n^+$ + in $\dom{h_1}$ and $\dom{h_2}$. + Since both $h_1$ and $h_2$ are acceptable, $h_1(n^+) = F(h_1(n))$ and + $h_2(n^+) = F(h_2(n))$. + Since $n \in S$, $h_1(n) = h_2(n)$. + Therefore $h_1$ and $h_2$ coincide with input $n^+$. + Thus $n^+ \in S$. + Hence $S$ is an inductive set. - We now prove $h$ is a unique function. - Let $h_1$ and $h_2$ both satisfy the conclusion of the theorem. - Define $$S = \{n \in \omega \mid h_1(n) = h_2(n)\}.$$ - It suffices to prove $S$ is an inductive set, for \nameref{sub:theorem-4b} - would then imply $S = \omega$, i.e. $h_1$ and $h_2$ agree on all of - $\omega$. + \paragraph{Conclusion}% - By definition of an acceptable function, $h_1(0) = a = h_2(0)$ meaning - $0 \in S$. - Next, suppose $n \in S$. - By \nameref{par:recursion-theorem-natural-numbers-iii}, it follows $n^+$ - in $\dom{h_1}$ and $\dom{h_2}$. - Since both $h_1$ and $h_2$ are acceptable, $h_1(n^+) = F(h_1(n))$ and - $h_2(n^+) = F(h_2(n))$. - Since $n \in S$, $h_1(n) = h_2(n)$. - Therefore $h_1$ and $h_2$ coincide with input $n^+$. - Thus $n^+ \in S$. - Hence $S$ is an inductive set. + By \nameref{par:recursion-theorem-natural-numbers-i}, + \nameref{par:recursion-theorem-natural-numbers-iii}, and + \nameref{par:recursion-theorem-natural-numbers-iv}, it follows $h$ is a + unique function mapping $\omega$ into $A$. + \nameref{par:recursion-theorem-natural-numbers-ii} shows $h$ satisfies the + desired conditions. - \paragraph{Conclusion}% - - By \nameref{par:recursion-theorem-natural-numbers-i}, - \nameref{par:recursion-theorem-natural-numbers-iii}, and - \nameref{par:recursion-theorem-natural-numbers-iv}, it follows $h$ is a - unique function mapping $\omega$ into $A$. - \nameref{par:recursion-theorem-natural-numbers-ii} shows $h$ satisfies the - desired conditions. - -\end{proof} + \end{proof} \subsection{\sorry{Theorem 4H}}% \hyperlabel{sub:theorem-4h} -\begin{theorem}[4H] + \begin{theorem}[4H] + Let $\langle N, S, e \rangle$ be a Peano system. + Then $\langle \omega, \sigma, 0 \rangle$ is isomorphic to + $\langle N, S, e \rangle$, i.e., there is a function $h$ mapping $\omega$ + one-to-one onto $N$ in a way that preserves the successor operation + $$h(\sigma(n)) = S(h(n))$$ and the zero element $$h(0) = e.$$ + \end{theorem} - Let $\langle N, S, e \rangle$ be a Peano system. - Then $\langle \omega, \sigma, 0 \rangle$ is isomorphic to - $\langle N, S, e \rangle$, i.e., there is a function $h$ mapping $\omega$ - one-to-one onto $N$ in a way that preserves the successor operation - $$h(\sigma(n)) = S(h(n))$$ and the zero element $$h(0) = e.$$ - -\end{theorem} - -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \section{Arithmetic}% \hyperlabel{sec:arithmetic} @@ -6537,652 +6061,624 @@ Show that $<_L$ is a linear ordering on $A \times B$. \subsection{\pending{Theorem 4I}} \hyperlabel{sub:theorem-4i} -\begin{theorem}[4I] + \begin{theorem}[4I] + For natural numbers $m$ and $n$, + \begin{align} + m + 0 & = m, \hyperlabel{sub:theorem-4i-eq1} \\ + m + n^+ & = (m + n)^+. \hyperlabel{sub:theorem-4i-eq2} + \end{align} + \end{theorem} - For natural numbers $m$ and $n$, - \begin{align} - m + 0 & = m, \hyperlabel{sub:theorem-4i-eq1} \\ - m + n^+ & = (m + n)^+. \hyperlabel{sub:theorem-4i-eq2} - \end{align} - -\end{theorem} - -\begin{proof} - - \statementpadding - - \lean*{Init/Data/Nat/Basic}{Nat.add\_zero} + \lean{Init/Data/Nat/Basic}{Nat.add\_zero} \lean{Init/Prelude}{Nat.add} - \paragraph{\eqref{sub:theorem-4i-eq1}}% + \begin{proof} - Let $m$ be a \nameref{ref:natural-number}. - By definition of \nameref{ref:addition}, $m + 0 = A_m(0)$. - By definition of $A_m$, $A_m(0) = m$. - Thus $m + 0 = m$. + \paragraph{\eqref{sub:theorem-4i-eq1}}% - \paragraph{\eqref{sub:theorem-4i-eq2}}% + Let $m$ be a \nameref{ref:natural-number}. + By definition of \nameref{ref:addition}, $m + 0 = A_m(0)$. + By definition of $A_m$, $A_m(0) = m$. + Thus $m + 0 = m$. - Let $m$ and $n$ be natural numbers. - By definition of \nameref{ref:addition}, - $$m + n^+ = A_m(n^+) = A_m(n)^+ = (m + n)^+.$$ + \paragraph{\eqref{sub:theorem-4i-eq2}}% -\end{proof} + Let $m$ and $n$ be natural numbers. + By definition of \nameref{ref:addition}, + $$m + n^+ = A_m(n^+) = A_m(n)^+ = (m + n)^+.$$ + + \end{proof} \subsection{\pending{Theorem 4J}} \hyperlabel{sub:theorem-4j} -\begin{theorem}[4J] + \begin{theorem}[4J] + For natural numbers $m$ and $n$, + \begin{align} + m \cdot 0 & = 0, \hyperlabel{sub:theorem-4j-eq1} \\ + m \cdot n^+ & = m \cdot n + m. \hyperlabel{sub:theorem-4j-eq2} + \end{align} + \end{theorem} - For natural numbers $m$ and $n$, - \begin{align} - m \cdot 0 & = 0, \hyperlabel{sub:theorem-4j-eq1} \\ - m \cdot n^+ & = m \cdot n + m. \hyperlabel{sub:theorem-4j-eq2} - \end{align} - -\end{theorem} - -\begin{proof} - - \statementpadding - - \lean*{Init/Data/Nat/Basic}{Nat.mul\_zero} + \lean{Init/Data/Nat/Basic}{Nat.mul\_zero} \lean{Init/Prelude}{Nat.mul} - \paragraph{\eqref{sub:theorem-4j-eq1}}% + \begin{proof} - Let $m$ be a \nameref{ref:natural-number}. - By definition of \nameref{ref:multiplication}, $$m \cdot 0 = M_m(0) = 0.$$ + \paragraph{\eqref{sub:theorem-4j-eq1}}% - \paragraph{\eqref{sub:theorem-4j-eq2}}% + Let $m$ be a \nameref{ref:natural-number}. + By definition of \nameref{ref:multiplication}, $$m \cdot 0 = M_m(0) = 0.$$ - Let $m$ and $n$ be natural numbers. - By definition of \nameref{ref:multiplication}, - $$m \cdot n^+ = M_m(n^+) = M_m(n) + m = m \cdot n + m.$$ + \paragraph{\eqref{sub:theorem-4j-eq2}}% -\end{proof} + Let $m$ and $n$ be natural numbers. + By definition of \nameref{ref:multiplication}, + $$m \cdot n^+ = M_m(n^+) = M_m(n) + m = m \cdot n + m.$$ + + \end{proof} \subsection{\pending{Left Additive Identity}}% \hyperlabel{sub:left-additive-identity} -\begin{lemma} - - For all $n \in \omega$, $A_0(n) = n$. - In other words, $$0 + n = n.$$ - -\end{lemma} - -\begin{proof} + \begin{lemma} + For all $n \in \omega$, $A_0(n) = n$. + In other words, $$0 + n = n.$$ + \end{lemma} \lean{Init/Data/Nat/Basic}{Nat.zero\_add} - Let $S = \{n \in \omega \mid 0 + n = n\}$. - We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:left-additive-identity-i} + Let $S = \{n \in \omega \mid 0 + n = n\}$. + We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. + Afterwards we show that (iii) our theorem holds. - By \nameref{sub:theorem-4i}, $0 + 0 = 0$. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:left-additive-identity-i} - \paragraph{(ii)}% - \hyperlabel{par:left-additive-identity-ii} + By \nameref{sub:theorem-4i}, $0 + 0 = 0$. + Thus $0 \in S$. - Suppose $n \in S$. - By \nameref{sub:theorem-4i}, $0 + n^+ = (0 + n)^+$. - Since $n \in S$, $0 + n = n$ which in turn implies that $(0 + n)^+ = n^+$. - Thus $n^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:left-additive-identity-ii} - \paragraph{(iii)}% + Suppose $n \in S$. + By \nameref{sub:theorem-4i}, $0 + n^+ = (0 + n)^+$. + Since $n \in S$, $0 + n = n$ which in turn implies that $(0 + n)^+ = n^+$. + Thus $n^+ \in S$. - By \nameref{par:left-additive-identity-i} and - \nameref{par:left-additive-identity-ii}, $S$ is an - \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $n \in \omega$, $0 + n = n$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:left-additive-identity-i} and + \nameref{par:left-additive-identity-ii}, $S$ is an + \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $n \in \omega$, $0 + n = n$. + + \end{proof} \subsection{\pending{Lemma 3}}% \hyperlabel{sub:lemma-3} \hyperlabel{sub:succ-add-eq-add-succ} -\begin{lemma} - - For all $m, n \in \omega$, $A_{m^+}(n) = A_m(n^+)$. - In other words, $$m^+ + n = m + n^+.$$ - -\end{lemma} - -\begin{proof} + \begin{lemma} + For all $m, n \in \omega$, $A_{m^+}(n) = A_m(n^+)$. + In other words, $$m^+ + n = m + n^+.$$ + \end{lemma} \lean{Std/Data/Nat/Lemmas}{Nat.succ\_add\_eq\_succ\_add} - Let $m \in \omega$ and define - $$S = \{n \in \omega \mid m^+ + n = m + n^+\}.$$ - We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:lemma-3-i} + Let $m \in \omega$ and define + $$S = \{n \in \omega \mid m^+ + n = m + n^+\}.$$ + We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. + Afterwards we show that (iii) our theorem holds. - By \nameref{sub:theorem-4i}, $m^+ + 0 = m^+$. - Likewise, $m + 0^+ = (m + 0)^+ = m^+$. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:lemma-3-i} - \paragraph{(ii)}% - \hyperlabel{par:lemma-3-ii} + By \nameref{sub:theorem-4i}, $m^+ + 0 = m^+$. + Likewise, $m + 0^+ = (m + 0)^+ = m^+$. + Thus $0 \in S$. - Suppose $n \in S$. - By \nameref{sub:theorem-4i}, $m^+ + n^+ = (m^+ + n)^+$. - Since $n \in S$, $m^+ + n = m + n^+$. - Therefore $(m^+ + n)^+ = (m + n^+)^+ = m + n^{++}$. - Thus $n^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:lemma-3-ii} - \paragraph{(iii)}% + Suppose $n \in S$. + By \nameref{sub:theorem-4i}, $m^+ + n^+ = (m^+ + n)^+$. + Since $n \in S$, $m^+ + n = m + n^+$. + Therefore $(m^+ + n)^+ = (m + n^+)^+ = m + n^{++}$. + Thus $n^+ \in S$. - By \nameref{par:lemma-3-i} and \nameref{par:lemma-3-ii}, $S$ is inductive. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $n \in \omega$, $m^+ + n = m + n^+$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:lemma-3-i} and \nameref{par:lemma-3-ii}, $S$ is inductive. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $n \in \omega$, $m^+ + n = m + n^+$. + + \end{proof} \subsection{\pending{Theorem 4K-1}}% -\label{sub:theorem-4k-1} +\hyperlabel{sub:theorem-4k-1} -\begin{theorem}[4K-1] - - Associative law for addition. - For $m, n, p \in \omega$, $$m + (n + p) = (m + n) + p.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[4K-1] + Associative law for addition. + For $m, n, p \in \omega$, $$m + (n + p) = (m + n) + p.$$ + \end{theorem} \lean{Mathlib/Algebra/Group/Defs}{add\_assoc} - Fix $n, p \in \omega$ and define - \begin{equation} - \hyperlabel{sub:theorem-4k-1-eq1} - S = \{m \in \omega \mid m + (n + p) = (m + n) + p\}. - \end{equation} - We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. - Afterward we show that (iii) the associative law for addition holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-4k-1-i} + Fix $n, p \in \omega$ and define + \begin{equation} + \hyperlabel{sub:theorem-4k-1-eq1} + S = \{m \in \omega \mid m + (n + p) = (m + n) + p\}. + \end{equation} + We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. + Afterward we show that (iii) the associative law for addition holds. - By \nameref{sub:left-additive-identity}, - $$0 + (n + p) = n + p = (0 + n) + p.$$ - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:theorem-4k-1-i} - \paragraph{(ii)}% - \hyperlabel{par:theorem-4k-1-ii} + By \nameref{sub:left-additive-identity}, + $$0 + (n + p) = n + p = (0 + n) + p.$$ + Thus $0 \in S$. - Suppose $m \in S$. - Then - \begin{align*} - m^+ + (n + p) - & = m + (n + p)^+ & \textref{sub:succ-add-eq-add-succ} \\ - & = (m + (n + p))^+ & \textref{sub:theorem-4i} \\ - & = ((m + n) + p)^+ & \eqref{sub:theorem-4k-1-eq1} \\ - & = (m + n) + p^+ & \textref{sub:theorem-4i} \\ - & = (m + n)^+ + p & \textref{sub:succ-add-eq-add-succ} \\ - & = (m + n^+) + p & \textref{sub:theorem-4i} \\ - & = (m^+ + n) + p. & \textref{sub:succ-add-eq-add-succ} - \end{align*} - Thus $m^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:theorem-4k-1-ii} - \paragraph{(iii)}% - \hyperlabel{par:theorem-4k-1-iii} + Suppose $m \in S$. + Then + \begin{align*} + m^+ + (n + p) + & = m + (n + p)^+ & \textref{sub:succ-add-eq-add-succ} \\ + & = (m + (n + p))^+ & \textref{sub:theorem-4i} \\ + & = ((m + n) + p)^+ & \eqref{sub:theorem-4k-1-eq1} \\ + & = (m + n) + p^+ & \textref{sub:theorem-4i} \\ + & = (m + n)^+ + p & \textref{sub:succ-add-eq-add-succ} \\ + & = (m + n^+) + p & \textref{sub:theorem-4i} \\ + & = (m^+ + n) + p. & \textref{sub:succ-add-eq-add-succ} + \end{align*} + Thus $m^+ \in S$. - By \nameref{par:theorem-4k-1-i} and \nameref{par:theorem-4k-1-ii}, $S$ is an - \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m, n, p \in \omega$, $m + (n + p) = (m + n) + p$. + \paragraph{(iii)}% + \hyperlabel{par:theorem-4k-1-iii} -\end{proof} + By \nameref{par:theorem-4k-1-i} and \nameref{par:theorem-4k-1-ii}, $S$ is + an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m, n, p \in \omega$, $m + (n + p) = (m + n) + p$. + + \end{proof} \subsection{\pending{Theorem 4K-2}}% -\label{sub:theorem-4k-2} +\hyperlabel{sub:theorem-4k-2} -\begin{theorem}[4K-2] - - Commutative law for addition. - For $m, n \in \omega$, $$m + n = n + m.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[4K-2] + Commutative law for addition. + For $m, n \in \omega$, $$m + n = n + m.$$ + \end{theorem} \lean{Mathlib/Algebra/Group/Defs}{add\_comm} - Fix $n \in \omega$ and define - \begin{equation} - \hyperlabel{sub:theorem-4k-2-eq1} - S = \{m \in \omega \mid m + n = n + m\}. - \end{equation} - We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. - Afterward we show that (iii) the commutative law for addition holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-4k-2-i} + Fix $n \in \omega$ and define + \begin{equation} + \hyperlabel{sub:theorem-4k-2-eq1} + S = \{m \in \omega \mid m + n = n + m\}. + \end{equation} + We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. + Afterward we show that (iii) the commutative law for addition holds. - By definition of \nameref{ref:addition} and - \nameref{sub:left-additive-identity}, $$0 + n = n = n + 0.$$ - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:theorem-4k-2-i} - \paragraph{(ii)}% - \hyperlabel{par:theorem-4k-2-ii} + By definition of \nameref{ref:addition} and + \nameref{sub:left-additive-identity}, $$0 + n = n = n + 0.$$ + Thus $0 \in S$. - Suppose $m \in S$. - Then - \begin{align*} - m^+ + n - & = m + n^+ & \textref{sub:succ-add-eq-add-succ} \\ - & = (m + n)^+ & \textref{sub:theorem-4i} \\ - & = (n + m)^+ & \eqref{sub:theorem-4k-2-eq1} \\ - & = n + m^+. & \textref{sub:theorem-4i} - \end{align*} - Thus $m^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:theorem-4k-2-ii} - \paragraph{(iii)}% + Suppose $m \in S$. + Then + \begin{align*} + m^+ + n + & = m + n^+ & \textref{sub:succ-add-eq-add-succ} \\ + & = (m + n)^+ & \textref{sub:theorem-4i} \\ + & = (n + m)^+ & \eqref{sub:theorem-4k-2-eq1} \\ + & = n + m^+. & \textref{sub:theorem-4i} + \end{align*} + Thus $m^+ \in S$. - By \nameref{par:theorem-4k-2-i} and \nameref{par:theorem-4k-2-ii}, $S$ - is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m, n \in \omega$, $m + n = n + m$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:theorem-4k-2-i} and \nameref{par:theorem-4k-2-ii}, $S$ + is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m, n \in \omega$, $m + n = n + m$. + + \end{proof} \subsection{\pending{Zero Multiplicand}}% \hyperlabel{sub:zero-multiplicand} -\begin{lemma} - - For all $n \in \omega$, $M_0(n) = 0$. - In other words, $$0 \cdot n = 0.$$ - -\end{lemma} - -\begin{proof} + \begin{lemma} + For all $n \in \omega$, $M_0(n) = 0$. + In other words, $$0 \cdot n = 0.$$ + \end{lemma} \lean{Init/Data/Nat/Basic}{Nat.zero\_mul} - Define - \begin{equation} - \hyperlabel{sub:zero-multiplicand-eq1} - S = \{n \in \omega \mid 0 \cdot n = 0\}. - \end{equation} - We prove that (i) $0 \in S$ and (ii) that if $n \in S$, then $n^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:zero-multiplicand-i} + Define + \begin{equation} + \hyperlabel{sub:zero-multiplicand-eq1} + S = \{n \in \omega \mid 0 \cdot n = 0\}. + \end{equation} + We prove that (i) $0 \in S$ and (ii) that if $n \in S$, then $n^+ \in S$. + Afterwards we show that (iii) our theorem holds. - By \nameref{sub:theorem-4j}, $0 \cdot 0 = 0$. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:zero-multiplicand-i} - \paragraph{(ii)}% - \hyperlabel{par:zero-multiplicand-ii} + By \nameref{sub:theorem-4j}, $0 \cdot 0 = 0$. + Thus $0 \in S$. - Suppose $n \in S$. - Then - \begin{align*} - 0 \cdot n^+ - & = 0 \cdot n + 0 & \textref{sub:theorem-4j} \\ - & = 0 + 0 & \eqref{sub:zero-multiplicand-eq1} \\ - & = 0. & \textref{ref:addition} - \end{align*} - Thus $n^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:zero-multiplicand-ii} - \paragraph{(iii)}% + Suppose $n \in S$. + Then + \begin{align*} + 0 \cdot n^+ + & = 0 \cdot n + 0 & \textref{sub:theorem-4j} \\ + & = 0 + 0 & \eqref{sub:zero-multiplicand-eq1} \\ + & = 0. & \textref{ref:addition} + \end{align*} + Thus $n^+ \in S$. - By \nameref{par:zero-multiplicand-i} and \nameref{par:zero-multiplicand-ii}, - $S$ is an \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $n \in \omega$, $0 \cdot n = 0$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:zero-multiplicand-i} and + \nameref{par:zero-multiplicand-ii}, $S$ is an + \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $n \in \omega$, $0 \cdot n = 0$. + + \end{proof} \subsection{\pending{Successor Distribution}}% \hyperlabel{sub:successor-distribution} -\begin{lemma} - - For all $m, n \in \omega$, $M_{m^+}(n) = M_m(n) + n$. - In other words, $$m^+ \cdot n = m \cdot n + n.$$ - -\end{lemma} - -\begin{proof} + \begin{lemma} + For all $m, n \in \omega$, $M_{m^+}(n) = M_m(n) + n$. + In other words, $$m^+ \cdot n = m \cdot n + n.$$ + \end{lemma} \lean{Init/Data/Nat/Basic}{Nat.succ\_mul} - Let $m \in \omega$ and define - \begin{equation} - \hyperlabel{sub:successor-distribution-eq1} - S = \{n \in \omega \mid m^+ \cdot n = m \cdot n + n\}. - \end{equation} - We prove that (i) $0 \in S$ and (ii) that if $n \in S$, then $n^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:successor-distribution-i} + Let $m \in \omega$ and define + \begin{equation} + \hyperlabel{sub:successor-distribution-eq1} + S = \{n \in \omega \mid m^+ \cdot n = m \cdot n + n\}. + \end{equation} + We prove that (i) $0 \in S$ and (ii) that if $n \in S$, then $n^+ \in S$. + Afterwards we show that (iii) our theorem holds. - By \nameref{sub:theorem-4j}, $m^+ \cdot 0 = 0$. - Likewise, by \nameref{sub:theorem-4i}, $m \cdot 0 + 0 = 0$. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:successor-distribution-i} - \paragraph{(ii)}% - \hyperlabel{par:successor-distribution-ii} + By \nameref{sub:theorem-4j}, $m^+ \cdot 0 = 0$. + Likewise, by \nameref{sub:theorem-4i}, $m \cdot 0 + 0 = 0$. + Thus $0 \in S$. - Suppose $n \in S$. - Then - \begin{align*} - m^+ \cdot n^+ - & = m^+ \cdot n + m^+ & \textref{sub:theorem-4j} \\ - & = (m \cdot n + n) + m^+ & \eqref{sub:successor-distribution-eq1} \\ - & = m \cdot n + (n + m^+) & \textref{sub:theorem-4k-1} \\ - & = m \cdot n + (n^+ + m) & \textref{sub:succ-add-eq-add-succ} \\ - & = m \cdot n + (m + n^+) & \textref{sub:theorem-4k-2} \\ - & = (m \cdot n + m) + n^+ & \textref{sub:theorem-4k-1} \\ - & = m \cdot n^+ + n^+. & \textref{sub:theorem-4j} - \end{align*} - Thus $n^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:successor-distribution-ii} - \paragraph{(iii)}% + Suppose $n \in S$. + Then + \begin{align*} + m^+ \cdot n^+ + & = m^+ \cdot n + m^+ & \textref{sub:theorem-4j} \\ + & = (m \cdot n + n) + m^+ & \eqref{sub:successor-distribution-eq1} \\ + & = m \cdot n + (n + m^+) & \textref{sub:theorem-4k-1} \\ + & = m \cdot n + (n^+ + m) & \textref{sub:succ-add-eq-add-succ} \\ + & = m \cdot n + (m + n^+) & \textref{sub:theorem-4k-2} \\ + & = (m \cdot n + m) + n^+ & \textref{sub:theorem-4k-1} \\ + & = m \cdot n^+ + n^+. & \textref{sub:theorem-4j} + \end{align*} + Thus $n^+ \in S$. - By \nameref{par:successor-distribution-i} and - \nameref{par:successor-distribution-ii}, $S$ is an - \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m, n \in \omega$, $m^+ \cdot n = m \cdot n + n$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:successor-distribution-i} and + \nameref{par:successor-distribution-ii}, $S$ is an + \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m, n \in \omega$, $m^+ \cdot n = m \cdot n + n$. + + \end{proof} \subsection{\pending{Theorem 4K-3}} \hyperlabel{sub:theorem-4k-3} -\begin{theorem}[4K-3] - - Distributive law. - For $m, n, p \in \omega$, $$m \cdot (n + p) = m \cdot n + m \cdot p.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[4K-3] + Distributive law. + For $m, n, p \in \omega$, $$m \cdot (n + p) = m \cdot n + m \cdot p.$$ + \end{theorem} \lean{Init/Data/Nat/Basic}{Nat.left\_distrib} - Fix $n, p \in \omega$ and define - \begin{equation} - \hyperlabel{sub:theorem-4k-3-eq1} - S = \{m \in \omega \mid m \cdot (n + p) = m \cdot n + m \cdot p\}. - \end{equation} - We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. - Afterward we show that (iii) the distributive law holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-4k-3-i} + Fix $n, p \in \omega$ and define + \begin{equation} + \hyperlabel{sub:theorem-4k-3-eq1} + S = \{m \in \omega \mid m \cdot (n + p) = m \cdot n + m \cdot p\}. + \end{equation} + We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. + Afterward we show that (iii) the distributive law holds. - By definition of \nameref{ref:multiplication} and \nameref{ref:addition}, - \begin{align*} - 0 \cdot (n + p) - & = 0 & \textref{sub:zero-multiplicand} \\ - & = 0 + 0 & \textref{ref:addition} \\ - & = 0 \cdot n + 0 \cdot p. & \textref{sub:zero-multiplicand} - \end{align*} - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:theorem-4k-3-i} - \paragraph{(ii)}% - \hyperlabel{par:theorem-4k-3-ii} + By definition of \nameref{ref:multiplication} and \nameref{ref:addition}, + \begin{align*} + 0 \cdot (n + p) + & = 0 & \textref{sub:zero-multiplicand} \\ + & = 0 + 0 & \textref{ref:addition} \\ + & = 0 \cdot n + 0 \cdot p. & \textref{sub:zero-multiplicand} + \end{align*} + Thus $0 \in S$. - Suppose $m \in S$. - By definition of \nameref{ref:multiplication} and \nameref{ref:addition}, - \begin{align*} - m^+ \cdot (n + p) - & = m \cdot (n + p) + (n + p) - & \textref{sub:successor-distribution} \\ - & = m \cdot (n + p) + n + p & \textref{sub:theorem-4k-1} \\ - & = m \cdot n + m \cdot p + n + p - & \eqref{sub:theorem-4k-3-eq1} \\ - & = m \cdot n + n + m \cdot p + p & \textref{sub:theorem-4k-2} \\ - & = m^+ \cdot n + m^+ \cdot p. & \textref{sub:successor-distribution} - \end{align*} - Thus $m^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:theorem-4k-3-ii} - \paragraph{(iii)}% + Suppose $m \in S$. + By definition of \nameref{ref:multiplication} and \nameref{ref:addition}, + \begin{align*} + m^+ \cdot (n + p) + & = m \cdot (n + p) + (n + p) + & \textref{sub:successor-distribution} \\ + & = m \cdot (n + p) + n + p & \textref{sub:theorem-4k-1} \\ + & = m \cdot n + m \cdot p + n + p + & \eqref{sub:theorem-4k-3-eq1} \\ + & = m \cdot n + n + m \cdot p + p & \textref{sub:theorem-4k-2} \\ + & = m^+ \cdot n + m^+ \cdot p. + & \textref{sub:successor-distribution} + \end{align*} + Thus $m^+ \in S$. - By \nameref{par:theorem-4k-3-i} and \nameref{par:theorem-4k-3-ii}, $S$ - is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m, n, p \in \omega$, - $m \cdot (n + p) = m \cdot n + m \cdot p$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:theorem-4k-3-i} and \nameref{par:theorem-4k-3-ii}, $S$ + is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m, n, p \in \omega$, + $m \cdot (n + p) = m \cdot n + m \cdot p$. + + \end{proof} \subsection{\pending{Successor Identity}}% \hyperlabel{sub:successor-identity} -\begin{lemma} - - For all $m \in \omega$, $A_m(1) = m^+$. - In other words, $$m + 1 = m^+.$$ - -\end{lemma} - -\begin{proof} + \begin{lemma} + For all $m \in \omega$, $A_m(1) = m^+$. + In other words, $$m + 1 = m^+.$$ + \end{lemma} \lean{Std/Data/Nat/Lemmas}{Nat.succ\_eq\_one\_add} - Let - \begin{equation} - \hyperlabel{sub:successor-identity-eq1} - S = \{m \in \omega \mid m + 1 = m^+\}. - \end{equation} - We prove that (i) $0 \in S$ and (ii) if $m \in S$, then $m^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:successor-identity-i} + Let + \begin{equation} + \hyperlabel{sub:successor-identity-eq1} + S = \{m \in \omega \mid m + 1 = m^+\}. + \end{equation} + We prove that (i) $0 \in S$ and (ii) if $m \in S$, then $m^+ \in S$. + Afterwards we show that (iii) our theorem holds. - By \nameref{sub:left-additive-identity}, $0 + 1 = 1$. - By definition of the \nameref{ref:successor}, - $0^+ = \emptyset \cup \{\emptyset\} = 1$. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:successor-identity-i} - \paragraph{(ii)}% - \hyperlabel{par:successor-identity-ii} + By \nameref{sub:left-additive-identity}, $0 + 1 = 1$. + By definition of the \nameref{ref:successor}, + $0^+ = \emptyset \cup \{\emptyset\} = 1$. + Thus $0 \in S$. - Let $m \in S$. - Then - \begin{align*} - m^+ + 1 - & = m + 1^+ & \textref{sub:succ-add-eq-add-succ} \\ - & = (m + 1)^+ & \textref{sub:theorem-4i} \\ - & = (m^+)^+. & \eqref{sub:successor-identity-eq1} - \end{align*} - Thus $m^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:successor-identity-ii} - \paragraph{(iii)}% + Let $m \in S$. + Then + \begin{align*} + m^+ + 1 + & = m + 1^+ & \textref{sub:succ-add-eq-add-succ} \\ + & = (m + 1)^+ & \textref{sub:theorem-4i} \\ + & = (m^+)^+. & \eqref{sub:successor-identity-eq1} + \end{align*} + Thus $m^+ \in S$. - By \nameref{par:successor-identity-i} and - \nameref{par:successor-identity-ii}, $S$ is an - \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $m \in \omega$, $m + 1 = m^+$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:successor-identity-i} and + \nameref{par:successor-identity-ii}, $S$ is an + \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $m \in \omega$, $m + 1 = m^+$. + + \end{proof} \subsection{\pending{Right Multiplicative Identity}}% \hyperlabel{sub:right-multiplicative-identity} -\begin{lemma} - - For all $m \in \omega$, $M_m(1) = m$. - In other words, $$m \cdot 1 = m.$$ - -\end{lemma} - -\begin{proof} + \begin{lemma} + For all $m \in \omega$, $M_m(1) = m$. + In other words, $$m \cdot 1 = m.$$ + \end{lemma} \lean{Init/Data/Nat/Basic}{mul\_one} - Let - \begin{equation} - \hyperlabel{sub:right-multiplicative-identity-eq1} - S = \{m \in \omega \mid m \cdot 1 = m\}. - \end{equation} - We prove that (i) $0 \in S$ and (ii) if $m \in S$, then $m^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:right-multiplicative-identity-i} + Let + \begin{equation} + \hyperlabel{sub:right-multiplicative-identity-eq1} + S = \{m \in \omega \mid m \cdot 1 = m\}. + \end{equation} + We prove that (i) $0 \in S$ and (ii) if $m \in S$, then $m^+ \in S$. + Afterwards we show that (iii) our theorem holds. - By \nameref{sub:zero-multiplicand}, $0 \cdot 1 = 0$. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:right-multiplicative-identity-i} - \paragraph{(ii)}% - \hyperlabel{par:right-multiplicative-identity-ii} + By \nameref{sub:zero-multiplicand}, $0 \cdot 1 = 0$. + Thus $0 \in S$. - Suppose $m \in S$. - Then - \begin{align*} - m^+ \cdot 1 - & = m \cdot 1 + 1 & \textref{sub:successor-distribution} \\ - & = m + 1 & \eqref{sub:right-multiplicative-identity-eq1} \\ - & = m^+. & \textref{sub:successor-identity} - \end{align*} - Thus $m^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:right-multiplicative-identity-ii} - \paragraph{(iii)}% + Suppose $m \in S$. + Then + \begin{align*} + m^+ \cdot 1 + & = m \cdot 1 + 1 & \textref{sub:successor-distribution} \\ + & = m + 1 & \eqref{sub:right-multiplicative-identity-eq1} \\ + & = m^+. & \textref{sub:successor-identity} + \end{align*} + Thus $m^+ \in S$. - By \nameref{par:right-multiplicative-identity-i} and - \nameref{par:right-multiplicative-identity-ii}, $S$ - is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m \in \omega$, $m \cdot 1 = m$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:right-multiplicative-identity-i} and + \nameref{par:right-multiplicative-identity-ii}, $S$ + is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m \in \omega$, $m \cdot 1 = m$. + + \end{proof} \subsection{\pending{Theorem 4K-5}} \hyperlabel{sub:theorem-4k-5} -\begin{theorem}[4K-5] + \begin{theorem}[4K-5] + Commutative law for multiplication. + For $m, n \in \omega$, $$m \cdot n = n \cdot m.$$ + \end{theorem} - Commutative law for multiplication. - For $m, n \in \omega$, $$m \cdot n = n \cdot m.$$ - -\end{theorem} - -\begin{note} - We prove commutativity before associativity, though Enderton orders these - two properties in the opposite direction. -\end{note} - -\begin{proof} + \begin{note} + We prove commutativity before associativity, though Enderton orders these + two properties in the opposite direction. + \end{note} \lean{Mathlib/Algebra/Group/Defs}{mul\_comm} - Fix $n \in \omega$ and define - \begin{equation} - \hyperlabel{sub:theorem-4k-5-eq1} - S = \{m \in \omega \mid m \cdot n = n \cdot m\}. - \end{equation} - We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. - Afterward we show that (iii) the commutative law for multiplication holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-4k-5-i} + Fix $n \in \omega$ and define + \begin{equation} + \hyperlabel{sub:theorem-4k-5-eq1} + S = \{m \in \omega \mid m \cdot n = n \cdot m\}. + \end{equation} + We show that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. + Afterward we show that (iii) the commutative law for multiplication holds. - By \nameref{sub:theorem-4j} and \nameref{sub:zero-multiplicand}, - $$0 \cdot n = 0 = n \cdot 0.$$ - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:theorem-4k-5-i} - \paragraph{(ii)}% - \hyperlabel{par:theorem-4k-5-ii} + By \nameref{sub:theorem-4j} and \nameref{sub:zero-multiplicand}, + $$0 \cdot n = 0 = n \cdot 0.$$ + Thus $0 \in S$. - Suppose $m \in S$. - Then - \begin{align*} - m^+ \cdot n - & = m \cdot n + n & \textref{sub:successor-distribution} \\ - & = n \cdot m + n & \eqref{sub:theorem-4k-5-eq1} \\ - & = n \cdot m + n \cdot 1 - & \textref{sub:right-multiplicative-identity} \\ - & = n \cdot (m + 1) & \textref{sub:theorem-4k-3} \\ - & = n \cdot m^+. & \textref{sub:successor-identity} - \end{align*} - Thus $m^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:theorem-4k-5-ii} - \paragraph{(iii)}% - \hyperlabel{par:theorem-4k-5-iii} + Suppose $m \in S$. + Then + \begin{align*} + m^+ \cdot n + & = m \cdot n + n & \textref{sub:successor-distribution} \\ + & = n \cdot m + n & \eqref{sub:theorem-4k-5-eq1} \\ + & = n \cdot m + n \cdot 1 + & \textref{sub:right-multiplicative-identity} \\ + & = n \cdot (m + 1) & \textref{sub:theorem-4k-3} \\ + & = n \cdot m^+. & \textref{sub:successor-identity} + \end{align*} + Thus $m^+ \in S$. - By \nameref{par:theorem-4k-5-i} and \nameref{par:theorem-4k-5-ii}, $S$ - is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m, n \in \omega$, $m \cdot n = n \cdot m$. + \paragraph{(iii)}% + \hyperlabel{par:theorem-4k-5-iii} -\end{proof} + By \nameref{par:theorem-4k-5-i} and \nameref{par:theorem-4k-5-ii}, $S$ + is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m, n \in \omega$, $m \cdot n = n \cdot m$. + + \end{proof} \subsection{\pending{Theorem 4K-4}}% \hyperlabel{sub:theorem-4k-4} -\begin{theorem}[4K-4] - - Associative law for multiplication. - For $m, n, p \in \omega$, $$m \cdot (n \cdot p) = (m \cdot n) \cdot p.$$ - -\end{theorem} - -\begin{proof} + \begin{theorem}[4K-4] + Associative law for multiplication. + For $m, n, p \in \omega$, $$m \cdot (n \cdot p) = (m \cdot n) \cdot p.$$ + \end{theorem} \lean{Mathlib/Algebra/Group/Defs}{mul\_assoc} - Fix $m, n \in \omega$ and define - \begin{equation} - \hyperlabel{sub:theorem-4k-4-eq1} - S = \{p \in \omega \mid m \cdot (n \cdot p) = (m \cdot n) \cdot p\}. - \end{equation} - We show that (i) $0 \in S$ and (ii) if $p \in S$ then $p^+ \in S$. - Afterward we show that (iii) the associative law for multiplication holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-4k-4-i} + Fix $m, n \in \omega$ and define + \begin{equation} + \hyperlabel{sub:theorem-4k-4-eq1} + S = \{p \in \omega \mid m \cdot (n \cdot p) = (m \cdot n) \cdot p\}. + \end{equation} + We show that (i) $0 \in S$ and (ii) if $p \in S$ then $p^+ \in S$. + Afterward we show that (iii) the associative law for multiplication holds. - By \nameref{sub:theorem-4j}, - $$m \cdot (n \cdot 0) = 0 = (m \cdot n) \cdot 0.$$ - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:theorem-4k-4-i} - \paragraph{(ii)}% - \hyperlabel{par:theorem-4k-4-ii} + By \nameref{sub:theorem-4j}, + $$m \cdot (n \cdot 0) = 0 = (m \cdot n) \cdot 0.$$ + Thus $0 \in S$. - Suppose $p \in S$. - Then - \begin{align*} - m \cdot (n \cdot p^+) - & = m \cdot (n \cdot p + n) & \textref{sub:theorem-4j} \\ - & = m \cdot (n \cdot p) + m \cdot n & \textref{sub:theorem-4k-3} \\ - & = (m \cdot n) \cdot p + m \cdot n & \eqref{sub:theorem-4k-4-eq1} \\ - & = p \cdot (m \cdot n) + m \cdot n & \textref{sub:theorem-4k-5} \\ - & = p^+ \cdot (m \cdot n) & \textref{sub:successor-distribution} \\ - & = (m \cdot n) \cdot p^+ & \textref{sub:theorem-4k-5} - \end{align*} - Thus $p^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:theorem-4k-4-ii} - \paragraph{(iii)}% + Suppose $p \in S$. + Then + \begin{align*} + m \cdot (n \cdot p^+) + & = m \cdot (n \cdot p + n) & \textref{sub:theorem-4j} \\ + & = m \cdot (n \cdot p) + m \cdot n & \textref{sub:theorem-4k-3} \\ + & = (m \cdot n) \cdot p + m \cdot n & \eqref{sub:theorem-4k-4-eq1} \\ + & = p \cdot (m \cdot n) + m \cdot n & \textref{sub:theorem-4k-5} \\ + & = p^+ \cdot (m \cdot n) & \textref{sub:successor-distribution} \\ + & = (m \cdot n) \cdot p^+ & \textref{sub:theorem-4k-5} + \end{align*} + Thus $p^+ \in S$. - By \nameref{par:theorem-4k-4-i} and \nameref{par:theorem-4k-4-ii}, $S$ - is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m, n, p \in \omega$, - $m \cdot (n \cdot p) = (m \cdot n) \cdot p$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:theorem-4k-4-i} and \nameref{par:theorem-4k-4-ii}, $S$ + is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m, n, p \in \omega$, + $m \cdot (n \cdot p) = (m \cdot n) \cdot p$. + + \end{proof} \section{Ordering on \texorpdfstring{$\omega$}{Natural Numbers}}% \hyperlabel{sec:ordering-natural-numbers} @@ -7190,618 +6686,580 @@ Show that $<_L$ is a linear ordering on $A \times B$. \subsection{\pending{Ordering on Successor}}% \hyperlabel{sub:ordering-successor} -\begin{lemma} - - Let $m, n \in \omega$. - Then $m < n^+ \iff m \leq n$. - -\end{lemma} - -\begin{proof} + \begin{lemma} + Let $m, n \in \omega$. + Then $m < n^+ \iff m \leq n$. + \end{lemma} \lean{Std/Data/Nat/Lemmas}{Nat.lt\_succ} - Let $m, n \in \omega$. - By \nameref{ref:ordering-natural-numbers}, - \begin{align*} - m < n^+ - & \iff m \in n^+ \\ - & \iff m \in n \cup \{n\} & \textref{ref:successor} \\ - & \iff m \in n \lor m \in \{n\} \\ - & \iff m \in n \lor m = n \\ - & \iff m \leq n. - \end{align*} - -\end{proof} + \begin{proof} + Let $m, n \in \omega$. + By \nameref{ref:ordering-natural-numbers}, + \begin{align*} + m < n^+ + & \iff m \in n^+ \\ + & \iff m \in n \cup \{n\} & \textref{ref:successor} \\ + & \iff m \in n \lor m \in \{n\} \\ + & \iff m \in n \lor m = n \\ + & \iff m \leq n. + \end{align*} + \end{proof} \subsection{\unverified{Members of Natural Numbers}}% \hyperlabel{sub:members-natural-numbers} -\begin{lemma} + \begin{lemma} + Every natural number is the set of all smaller natural numbers. + \end{lemma} - Every natural number is the set of all smaller natural numbers. - -\end{lemma} - -\begin{proof} - - Let $n \in \omega$. - Consider $m \in n$. - By \nameref{sub:theorem-4b}, $\omega$ is a \nameref{ref:transitive-set}. - Thus $m \in n$ implies $m \in \omega$. - Thus $m \in n \iff m \in \omega \land m \in n$. - -\end{proof} + \begin{proof} + Let $n \in \omega$. + Consider $m \in n$. + By \nameref{sub:theorem-4b}, $\omega$ is a \nameref{ref:transitive-set}. + Thus $m \in n$ implies $m \in \omega$. + Thus $m \in n \iff m \in \omega \land m \in n$. + \end{proof} \subsection{\pending{Lemma 4L(a)}}% \hyperlabel{sub:lemma-4l-a} -\begin{lemma}[4L(a)] + \begin{lemma}[4L(a)] + For any natural numbers $m$ and $n$, $$m \in n \iff m^+ \in n^+.$$ + \end{lemma} - For any natural numbers $m$ and $n$, $$m \in n \iff m^+ \in n^+.$$ - -\end{lemma} - -\begin{note} - Here I referred to Enderton's proof in the forward direction. -\end{note} - -\begin{proof} + \begin{note} + Here I referred to Enderton's proof in the forward direction. + \end{note} \lean{Std/Data/Nat/Lemmas}{Nat.succ\_lt\_succ\_iff} - Let $m$ and $n$ be \nameref{ref:natural-number}s. + \begin{proof} - \paragraph{($\Rightarrow$)}% + Let $m$ and $n$ be \nameref{ref:natural-number}s. - Define $$S = \{n \in \omega \mid (\forall m \in n) m^+ \in n^+\}.$$ - We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. - Afterwards we show that (iii) the forward direction of the stated - biconditional holds. + \paragraph{($\Rightarrow$)}% - \subparagraph{(i)}% - \hyperlabel{spar:lemma-4l-a-i} + Define $$S = \{n \in \omega \mid (\forall m \in n) m^+ \in n^+\}.$$ + We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. + Afterwards we show that (iii) the forward direction of the stated + biconditional holds. - $0 \in S$ vacuously. - That is, there are no members of $0 = \emptyset$ by definition. + \subparagraph{(i)}% + \hyperlabel{spar:lemma-4l-a-i} - \subparagraph{(ii)}% - \hyperlabel{spar:lemma-4l-a-ii} + $0 \in S$ vacuously. + That is, there are no members of $0 = \emptyset$ by definition. - Suppose $n \in S$. - We need to show for all $m \in n^+$, $m^+ \in n^{++}$. - Let $m \in n^+ = n \cup \{n\}$. - Then $m \in n$ or $m \in \{n\}$. + \subparagraph{(ii)}% + \hyperlabel{spar:lemma-4l-a-ii} - If $m \in n$, then $n \in S$ implies $m^+ \in n^+ \in n^{++}$. - By \nameref{sub:theorem-4f}, every natural number is a - \nameref{ref:transitive-set}. - Therefore $m^+ \in n^{++}$. - On the other hand, if $m \in \{n\}$, then $m = n$. - Since $n^+ \in n^{++}$, it immediately follows $m^+ \in n^{++}$. - Hence $n^+ \in S$. + Suppose $n \in S$. + We need to show for all $m \in n^+$, $m^+ \in n^{++}$. + Let $m \in n^+ = n \cup \{n\}$. + Then $m \in n$ or $m \in \{n\}$. - \subparagraph{(iii)}% + If $m \in n$, then $n \in S$ implies $m^+ \in n^+ \in n^{++}$. + By \nameref{sub:theorem-4f}, every natural number is a + \nameref{ref:transitive-set}. + Therefore $m^+ \in n^{++}$. + On the other hand, if $m \in \{n\}$, then $m = n$. + Since $n^+ \in n^{++}$, it immediately follows $m^+ \in n^{++}$. + Hence $n^+ \in S$. - By \nameref{spar:lemma-4l-a-i} and \nameref{spar:lemma-4l-a-ii}, $S$ is an - \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $n \in \omega$, $m \in n \Rightarrow m^+ \in n^+$. + \subparagraph{(iii)}% - \paragraph{($\Leftarrow$)}% + By \nameref{spar:lemma-4l-a-i} and \nameref{spar:lemma-4l-a-ii}, $S$ is + an \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $n \in \omega$, $m \in n \Rightarrow m^+ \in n^+$. - Suppose $m^+ \in n^+$. - The definition of \nameref{ref:successor} immediately implies that - $m \in m^+$. - By \nameref{sec:ordering-natural-numbers}, $m^+ \in n^+$ implies $m^+ \in n$ - or $m^+ = n$. - If the latter, $m \in n$ immediately follows. - If the former, we note $n$ is a transitive set by \nameref{sub:theorem-4f}. - Thus $m \in m^+ \in n$ implies $m \in n$. + \paragraph{($\Leftarrow$)}% -\end{proof} + Suppose $m^+ \in n^+$. + The definition of \nameref{ref:successor} immediately implies that + $m \in m^+$. + By \nameref{sec:ordering-natural-numbers}, $m^+ \in n^+$ implies + $m^+ \in n$ or $m^+ = n$. + If the latter, $m \in n$ immediately follows. + If the former, we note $n$ is a transitive set by + \nameref{sub:theorem-4f}. + Thus $m \in m^+ \in n$ implies $m \in n$. + + \end{proof} \subsection{\pending{Lemma 4L(b)}}% \hyperlabel{sub:lemma-4l-b} -\begin{lemma}[4L(b)] - - No natural number is a member of itself. - -\end{lemma} - -\begin{proof} + \begin{lemma}[4L(b)] + No natural number is a member of itself. + \end{lemma} \lean{Init/Prelude}{Nat.lt\_irrefl} - Define - \begin{equation} - \hyperlabel{sub:lemma-4l-b-eq1} - S = \{n \in \omega \mid n \not\in n\}. - \end{equation} - We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:lemma-4l-b-i} + Define + \begin{equation} + \hyperlabel{sub:lemma-4l-b-eq1} + S = \{n \in \omega \mid n \not\in n\}. + \end{equation} + We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. + Afterwards we show that (iii) our theorem holds. - By definition, $0 = \emptyset$. - It obviously holds that $\emptyset \not\in \emptyset$ since $\emptyset$, - by definition, has no members. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:lemma-4l-b-i} - \paragraph{(ii)}% - \hyperlabel{par:lemma-4l-b-ii} + By definition, $0 = \emptyset$. + It obviously holds that $\emptyset \not\in \emptyset$ since $\emptyset$, + by definition, has no members. + Thus $0 \in S$. - Suppose $n \in S$. - By \eqref{sub:lemma-4l-b-eq1}, $n \not\in n$. - By \nameref{sub:lemma-4l-a}, it follows $n^+ \not\in n^+$. - Thus $n^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:lemma-4l-b-ii} - \paragraph{(iii)}% + Suppose $n \in S$. + By \eqref{sub:lemma-4l-b-eq1}, $n \not\in n$. + By \nameref{sub:lemma-4l-a}, it follows $n^+ \not\in n^+$. + Thus $n^+ \in S$. - By \nameref{par:lemma-4l-b-i} and \nameref{par:lemma-4l-b-ii}, $S$ is an - \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $n \in \omega$, $n \not\in n$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:lemma-4l-b-i} and \nameref{par:lemma-4l-b-ii}, $S$ is an + \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $n \in \omega$, $n \not\in n$. + + \end{proof} \subsection{\verified{\texorpdfstring{$0$}{Zero} is the Least Natural Number}}% \hyperlabel{sub:zero-least-natural-number} -\begin{lemma} - - For every natural number $n \neq 0$, $0 \in n$. - -\end{lemma} - -\begin{proof} + \begin{lemma} + For every natural number $n \neq 0$, $0 \in n$. + \end{lemma} \code{Bookshelf/Enderton/Set/Chapter\_4} {Enderton.Set.Chapter\_4.zero\_least\_nat} - Let $$S = \{n \in \omega \mid n = 0 \lor 0 \in n\}.$$ - We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:zero-least-natural-number-i} + Let $$S = \{n \in \omega \mid n = 0 \lor 0 \in n\}.$$ + We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. + Afterwards we show that (iii) our theorem holds. - This trivially holds by definition of $S$. + \paragraph{(i)}% + \hyperlabel{par:zero-least-natural-number-i} - \paragraph{(ii)}% - \hyperlabel{par:zero-least-natural-number-ii} + This trivially holds by definition of $S$. - Suppose $n \in S$. - By definition of the \nameref{ref:successor} function, $n^+ = n \cup \{n\}$. - Thus $n \in n^+$. - By \nameref{sub:theorem-4f}, $n^+$ is a \nameref{ref:transitive-set}. - Since $0 \in n$ and $n \in n^+$, it follows $0 \in n^+$. - Thus $n^+ \in S$. + \paragraph{(ii)}% + \hyperlabel{par:zero-least-natural-number-ii} - \paragraph{(iii)}% + Suppose $n \in S$. + By definition of the \nameref{ref:successor} function, + $n^+ = n \cup \{n\}$. + Thus $n \in n^+$. + By \nameref{sub:theorem-4f}, $n^+$ is a \nameref{ref:transitive-set}. + Since $0 \in n$ and $n \in n^+$, it follows $0 \in n^+$. + Thus $n^+ \in S$. - By \nameref{par:zero-least-natural-number-i} and - \nameref{par:zero-least-natural-number-ii}, $S$ is an - \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $n \in \omega$, either $n = 0$ or $0 \in n$. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:zero-least-natural-number-i} and + \nameref{par:zero-least-natural-number-ii}, $S$ is an + \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $n \in \omega$, either $n = 0$ or $0 \in n$. + + \end{proof} \subsection{\verified{% Trichotomy Law for \texorpdfstring{$\omega$}{Natural Numbers}}}% \hyperlabel{sub:trichotomy-law-natural-numbers} -\begin{theorem} - - For any natural numbers $m$ and $n$, exactly one of the three conditions - $$m \in n, \quad m = n, \quad n \in m$$ holds. - -\end{theorem} - -\begin{proof} + \begin{theorem} + For any natural numbers $m$ and $n$, exactly one of the three conditions + $$m \in n, \quad m = n, \quad n \in m$$ holds. + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_4} {Enderton.Set.Chapter\_4.trichotomy\_law\_for\_nat} - Let $n \in \omega$ and define - \begin{equation} - \hyperlabel{sub:trichotomy-law-natural-numbers-eq1} - S = \{m \in \omega \mid m \in n \lor m = n \lor n \in m\}. - \end{equation} - We prove that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. - Afterwards we show that (iii) our theorem holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:trichotomy-law-natural-numbers-i} + Let $n \in \omega$ and define + \begin{equation} + \hyperlabel{sub:trichotomy-law-natural-numbers-eq1} + S = \{m \in \omega \mid m \in n \lor m = n \lor n \in m\}. + \end{equation} + We prove that (i) $0 \in S$ and (ii) if $m \in S$ then $m^+ \in S$. + Afterwards we show that (iii) our theorem holds. - If $n = 0$, then it trivially follows $0 \in S$. - Otherwise \nameref{sub:zero-least-natural-number} implies $0 \in n$. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:trichotomy-law-natural-numbers-i} - \paragraph{(ii)}% - \hyperlabel{par:trichotomy-law-natural-numbers-ii} + If $n = 0$, then it trivially follows $0 \in S$. + Otherwise \nameref{sub:zero-least-natural-number} implies $0 \in n$. + Thus $0 \in S$. - Suppose $m \in S$. - By \eqref{sub:trichotomy-law-natural-numbers-eq1}, there are three cases to - consider: + \paragraph{(ii)}% + \hyperlabel{par:trichotomy-law-natural-numbers-ii} - \subparagraph{Case 1}% + Suppose $m \in S$. + By \eqref{sub:trichotomy-law-natural-numbers-eq1}, there are three cases + to consider: - Suppose $m \in n$. - By \nameref{sub:lemma-4l-a}, $m^+ \in n^+ = n \cup \{n\}$. - By definition of the \nameref{ref:successor}, $m^+ \in n$ or $m^+ = n$. - Either way, $m^+ \in S$. + \subparagraph{Case 1}% - \subparagraph{Case 2}% + Suppose $m \in n$. + By \nameref{sub:lemma-4l-a}, $m^+ \in n^+ = n \cup \{n\}$. + By definition of the \nameref{ref:successor}, $m^+ \in n$ or $m^+ = n$. + Either way, $m^+ \in S$. - Suppose $m = n$. - Since $m \in m^+$, it follows $n \in m^+$. - Thus $m^+ \in S$. + \subparagraph{Case 2}% - \subparagraph{Case 3}% + Suppose $m = n$. + Since $m \in m^+$, it follows $n \in m^+$. + Thus $m^+ \in S$. - Suppose $n \in m$. - Then $n \in m \cup \{m\} = m^+$. - Thus $m^+ \in S$. + \subparagraph{Case 3}% - \subparagraph{Conclusion}% + Suppose $n \in m$. + Then $n \in m \cup \{m\} = m^+$. + Thus $m^+ \in S$. - Since the above three cases are exhaustive, it follows $m^+ \in S$. + \subparagraph{Conclusion}% - \paragraph{(iii)}% + Since the above three cases are exhaustive, it follows $m^+ \in S$. - By \nameref{par:trichotomy-law-natural-numbers-i} and - \nameref{par:trichotomy-law-natural-numbers-ii}, $S$ is an - \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Thus for all $m, n \in \omega$, $$m \in n \lor m = n \lor n \in m.$$ - We now prove that - $$\in_\omega = \{\pair{m, n} \in \omega \times \omega \mid m \in n\}$$ - is \nameref{ref:irreflexive} and \nameref{ref:connected}. - Irreflexivity immediately follows from \nameref{sub:lemma-4l-b}. - Connectivity follows immediately from the fact $S = \omega$. - Furthermore, it is not possible both $m \in n$ and $n \in m$ since, by - \nameref{sub:theorem-4f}, $m$ and $n$ are \nameref{ref:transitive-set}s. - This would otherwise imply $m \in m$, an immediate contradiction to - irreflexivity. - Thus $\in_\omega$ is a \nameref{ref:trichotomous} relation. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:trichotomy-law-natural-numbers-i} and + \nameref{par:trichotomy-law-natural-numbers-ii}, $S$ is an + \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Thus for all $m, n \in \omega$, $$m \in n \lor m = n \lor n \in m.$$ + We now prove that + $$\in_\omega = \{\pair{m, n} \in \omega \times \omega \mid m \in n\}$$ + is \nameref{ref:irreflexive} and \nameref{ref:connected}. + Irreflexivity immediately follows from \nameref{sub:lemma-4l-b}. + Connectivity follows immediately from the fact $S = \omega$. + Furthermore, it is not possible both $m \in n$ and $n \in m$ since, by + \nameref{sub:theorem-4f}, $m$ and $n$ are \nameref{ref:transitive-set}s. + This would otherwise imply $m \in m$, an immediate contradiction to + irreflexivity. + Thus $\in_\omega$ is a \nameref{ref:trichotomous} relation. + + \end{proof} \subsection{\verified{% Linear Ordering on \texorpdfstring{$\omega$}{Natural Numbers}}}% \hyperlabel{sub:linear-ordering-natural-numbers} -\begin{theorem} - - Relation - \begin{equation} - \hyperlabel{sub:linear-ordering-natural-numbers-eq1} - \in_\omega = \{\pair{m, n} \in \omega \times \omega \mid m \in n\} - \end{equation} - is a linear ordering on $\omega$. - -\end{theorem} - -\begin{proof} + \begin{theorem} + Relation + \begin{equation} + \hyperlabel{sub:linear-ordering-natural-numbers-eq1} + \in_\omega = \{\pair{m, n} \in \omega \times \omega \mid m \in n\} + \end{equation} + is a linear ordering on $\omega$. + \end{theorem} \code{Bookshelf/Enderton/Set/Chapter\_4} {Enderton.Set.Chapter\_4.linear\_ordering\_on\_nat} - By definition, \eqref{sub:linear-ordering-natural-numbers-eq1} is a - \nameref{ref:linear-ordering} on $\omega$ if it is (i) transitive and - (ii) trichotomous. + \begin{proof} - \paragraph{(i)}% + By definition, \eqref{sub:linear-ordering-natural-numbers-eq1} is a + \nameref{ref:linear-ordering} on $\omega$ if it is (i) transitive and + (ii) trichotomous. - Suppose $p, q, r \in \omega$ such that $p \in q$ and $q \in r$. - By \nameref{sub:theorem-4f}, $p$, $q$, and $r$ are - \nameref{ref:transitive-set}s. - By definition of a transitive set, it follows $p \in r$. - Hence \eqref{sub:linear-ordering-natural-numbers-eq1} is - \nameref{ref:transitive}. + \paragraph{(i)}% - \paragraph{(ii)}% + Suppose $p, q, r \in \omega$ such that $p \in q$ and $q \in r$. + By \nameref{sub:theorem-4f}, $p$, $q$, and $r$ are + \nameref{ref:transitive-set}s. + By definition of a transitive set, it follows $p \in r$. + Hence \eqref{sub:linear-ordering-natural-numbers-eq1} is + \nameref{ref:transitive}. - By \nameref{sub:trichotomy-law-natural-numbers}, - \eqref{sub:linear-ordering-natural-numbers-eq1} is trichotomous. + \paragraph{(ii)}% -\end{proof} + By \nameref{sub:trichotomy-law-natural-numbers}, + \eqref{sub:linear-ordering-natural-numbers-eq1} is trichotomous. + + \end{proof} \subsection{\unverified{Corollary 4M}}% \hyperlabel{sub:corollary-4m} -\begin{corollary}[4M] + \begin{corollary}[4M] + For any natural numbers $m$ and $n$, + \begin{equation} + \hyperlabel{sub:corollary-4m-eq1} + m \in n \iff m \subset n + \end{equation} + and + \begin{equation} + \hyperlabel{sub:corollary-4m-eq2} + m \ineq n \iff m \subseteq n. + \end{equation} + \end{corollary} - For any natural numbers $m$ and $n$, - \begin{equation} - \hyperlabel{sub:corollary-4m-eq1} - m \in n \iff m \subset n - \end{equation} - and - \begin{equation} - \hyperlabel{sub:corollary-4m-eq2} - m \ineq n \iff m \subseteq n. - \end{equation} + \begin{proof} -\end{corollary} + \paragraph{\eqref{sub:corollary-4m-eq1}}% -\begin{proof} + We prove both directions of the biconditional specified in + \eqref{sub:corollary-4m-eq1}: - \paragraph{\eqref{sub:corollary-4m-eq1}}% + \subparagraph{($\Rightarrow$)}% - We prove both directions of the biconditional specified in - \eqref{sub:corollary-4m-eq1}: + Suppose $m \in n$ and $t \in m$. + By \nameref{sub:theorem-4f}, $n$ is a \nameref{ref:transitive-set}. + Therefore $t \in n$. + Hence $m \subseteq n$. + Since $m \in n$, \nameref{sub:linear-ordering-natural-numbers} implies + $m \neq n$. + Thus, by definition of \nameref{ref:proper-subset}, $m \subset n$. - \subparagraph{($\Rightarrow$)}% + \subparagraph{($\Leftarrow$)}% - Suppose $m \in n$ and $t \in m$. - By \nameref{sub:theorem-4f}, $n$ is a \nameref{ref:transitive-set}. - Therefore $t \in n$. - Hence $m \subseteq n$. - Since $m \in n$, \nameref{sub:linear-ordering-natural-numbers} implies - $m \neq n$. - Thus, by definition of \nameref{ref:proper-subset}, $m \subset n$. + Suppose $m \subset n$. + By \nameref{sub:linear-ordering-natural-numbers}, exactly one of + $$m \in n, \quad m = n, \quad n \in m$$ holds. + By definition of \nameref{ref:proper-subset}, $m \subseteq n$ and + $m \neq n$. + Furthermore, it cannot be that $n \in m$ since otherwise $n \in n$, + contradicting \nameref{sub:lemma-4l-b}. + Thus $m \in n$ is the only possibility. - \subparagraph{($\Leftarrow$)}% + \paragraph{\eqref{sub:corollary-4m-eq2}}% - Suppose $m \subset n$. - By \nameref{sub:linear-ordering-natural-numbers}, exactly one of - $$m \in n, \quad m = n, \quad n \in m$$ holds. - By definition of \nameref{ref:proper-subset}, $m \subseteq n$ and - $m \neq n$. - Furthermore, it cannot be that $n \in m$ since otherwise $n \in n$, - contradicting \nameref{sub:lemma-4l-b}. - Thus $m \in n$ is the only possibility. + We prove both directions of the biconditional specified in + \eqref{sub:corollary-4m-eq2}: - \paragraph{\eqref{sub:corollary-4m-eq2}}% + \subparagraph{($\Rightarrow$)}% - We prove both directions of the biconditional specified in - \eqref{sub:corollary-4m-eq2}: + Suppose $m \ineq n$. + By definition, $m \in n$ or $m = n$. + Let $p \in m$. + Then $p \in m \in n$ or $p \in m = n$. + By \nameref{sub:theorem-4f}, $n$ is a \nameref{ref:transitive-set}. + Thus $p \in n$ in either case. + Hence $m \subseteq n$. - \subparagraph{($\Rightarrow$)}% + \subparagraph{($\Leftarrow$)}% - Suppose $m \ineq n$. - By definition, $m \in n$ or $m = n$. - Let $p \in m$. - Then $p \in m \in n$ or $p \in m = n$. - By \nameref{sub:theorem-4f}, $n$ is a \nameref{ref:transitive-set}. - Thus $p \in n$ in either case. - Hence $m \subseteq n$. + Suppose $m \subseteq n$. + By \nameref{sub:linear-ordering-natural-numbers}, exactly one of + $$m \in n, \quad m = n, \quad n \in m$$ holds. + But it cannot be that $n \in m$ since that would imply $n \in n$, + contradicting \nameref{sub:lemma-4l-b}. + Therefore $m \in n$ or $m = n$. + Hence $m \ineq n$. - \subparagraph{($\Leftarrow$)}% - - Suppose $m \subseteq n$. - By \nameref{sub:linear-ordering-natural-numbers}, exactly one of - $$m \in n, \quad m = n, \quad n \in m$$ holds. - But it cannot be that $n \in m$ since that would imply $n \in n$, - contradicting \nameref{sub:lemma-4l-b}. - Therefore $m \in n$ or $m = n$. - Hence $m \ineq n$. - -\end{proof} + \end{proof} \subsection{\pending{Theorem 4N}}% \hyperlabel{sub:theorem-4n} -\begin{theorem}[4N] + \begin{theorem}[4N] + For any natural numbers $n$, $m$, and $p$, $$m \in n \iff m + p \in n + p.$$ + If, in addition, $p \neq 0$, then $$m \in n \iff m \cdot p \in n \cdot p.$$ + \end{theorem} - For any natural numbers $n$, $m$, and $p$, $$m \in n \iff m + p \in n + p.$$ - If, in addition, $p \neq 0$, then $$m \in n \iff m \cdot p \in n \cdot p.$$ - -\end{theorem} - -\begin{proof} - - \statementpadding - - \lean*{Std/Data/Nat/Lemmas}{Nat.add\_lt\_add\_iff\_right} + \lean{Std/Data/Nat/Lemmas}{Nat.add\_lt\_add\_iff\_right} \lean{Init/Data/Nat/Basic}{Nat.mul\_lt\_mul\_of\_pos\_right} - We prove that (i) $m \in n$ iff $m + p \in n + p$ and, - (ii) if $p \neq 0$, then $m \in n$ iff $m \cdot p \in n \cdot p$. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:theorem-4n-i} + We prove that (i) $m \in n$ iff $m + p \in n + p$ and, + (ii) if $p \neq 0$, then $m \in n$ iff $m \cdot p \in n \cdot p$. - Let $m$ and $n$ be \nameref{ref:natural-number}s. + \paragraph{(i)}% + \hyperlabel{par:theorem-4n-i} - \subparagraph{($\Rightarrow$)}% - \hyperlabel{spar:theorem-4n-i-right} + Let $m$ and $n$ be \nameref{ref:natural-number}s. - Suppose $m \in n$. - Let $$S = \{p \in \omega \mid m + p \in n + p\}.$$ - It trivially follows that $0 \in S$. - Next, suppose $p \in S$. - That is, suppose $m + p \in n + p$. - By \nameref{sub:lemma-4l-a}, this holds if and only if - $(m + p)^+ \in (n + p)^+$. - \nameref{sub:theorem-4i} then implies that $m + p^+ \in n + p^+$ meaning - $p^+ \in S$. + \subparagraph{($\Rightarrow$)}% + \hyperlabel{spar:theorem-4n-i-right} - Thus $S$ is an \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - Therefore, for all $p \in \omega$, $m \in n$ implies $m + p \in n + p$. + Suppose $m \in n$. + Let $$S = \{p \in \omega \mid m + p \in n + p\}.$$ + It trivially follows that $0 \in S$. + Next, suppose $p \in S$. + That is, suppose $m + p \in n + p$. + By \nameref{sub:lemma-4l-a}, this holds if and only if + $(m + p)^+ \in (n + p)^+$. + \nameref{sub:theorem-4i} then implies that $m + p^+ \in n + p^+$ meaning + $p^+ \in S$. - \subparagraph{($\Leftarrow$)}% + Thus $S$ is an \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + Therefore, for all $p \in \omega$, $m \in n$ implies $m + p \in n + p$. - Let $p$ be a natural number and suppose $m + p \in n + p$. - By the \nameref{sub:trichotomy-law-natural-numbers}, there are two - cases to consider regarding how $m$ and $n$ relate to one another: + \subparagraph{($\Leftarrow$)}% - \vspace{8pt} - \textbf{Case 1}: Suppose $m = n$. - Then $m + p \in n + p = m + p$. - \nameref{sub:lemma-4l-b} shows this is impossible. + Let $p$ be a natural number and suppose $m + p \in n + p$. + By the \nameref{sub:trichotomy-law-natural-numbers}, there are two + cases to consider regarding how $m$ and $n$ relate to one another: - \vspace{8pt} - \textbf{Case 2}: Suppose $n \in m$. - Then \nameref{spar:theorem-4n-i-right} indicates $n + p \in m + p$. - But this contradicts \nameref{sub:trichotomy-law-natural-numbers} since, - by hypothesis, $m + p \in n + p$. + \vspace{8pt} + \textbf{Case 1}: Suppose $m = n$. + Then $m + p \in n + p = m + p$. + \nameref{sub:lemma-4l-b} shows this is impossible. - \vspace{8pt} - \textbf{Conclusion}: By trichotomy, it follows $m \in n$. + \vspace{8pt} + \textbf{Case 2}: Suppose $n \in m$. + Then \nameref{spar:theorem-4n-i-right} indicates $n + p \in m + p$. + But this contradicts \nameref{sub:trichotomy-law-natural-numbers} since, + by hypothesis, $m + p \in n + p$. - \paragraph{(ii)}% - \hyperlabel{par:theorem-4n-ii} + \vspace{8pt} + \textbf{Conclusion}: By trichotomy, it follows $m \in n$. - Let $m$ and $n$ be \nameref{ref:natural-number}s. + \paragraph{(ii)}% + \hyperlabel{par:theorem-4n-ii} - \subparagraph{($\Rightarrow$)}% - \hyperlabel{spar:theorem-4n-ii-right} + Let $m$ and $n$ be \nameref{ref:natural-number}s. - Suppose $m \in n$. - Let $$S = \{p \in \omega \mid m \cdot p^+ \in n \cdot p^+\}.$$ - $0 \in S$ by \nameref{sub:right-multiplicative-identity}. - Next, suppose $p \in S$. - That is, $m \cdot p^+ \in n \cdot p^+$. - Then - \begin{align*} - m \cdot p^{++} - & = m \cdot p^+ + m & \textref{sub:theorem-4j} \\ - & \in n \cdot p^+ + m & \textref{par:theorem-4n-i} \\ - & = m + n \cdot p^+ & \textref{sub:theorem-4k-2} \\ - & \in n + n \cdot p^+ & \textref{par:theorem-4n-i} \\ - & = n \cdot p^+ + n & \textref{sub:theorem-4k-2} \\ - & = n \cdot p^{++}. & \textref{sub:theorem-4j} - \end{align*} - Therefore $p^+ \in S$. + \subparagraph{($\Rightarrow$)}% + \hyperlabel{spar:theorem-4n-ii-right} - Thus $S$ is an \nameref{ref:inductive-set}. - Hence \nameref{sub:theorem-4b} implies $S = \omega$. - By \nameref{sub:theorem-4c}, every natural number except 0 is the - successor of some natural number. - Therefore, for all $p \in \omega$ such that $p \neq 0$, $m \in n$ implies - $m \cdot p \in n \cdot p$. + Suppose $m \in n$. + Let $$S = \{p \in \omega \mid m \cdot p^+ \in n \cdot p^+\}.$$ + $0 \in S$ by \nameref{sub:right-multiplicative-identity}. + Next, suppose $p \in S$. + That is, $m \cdot p^+ \in n \cdot p^+$. + Then + \begin{align*} + m \cdot p^{++} + & = m \cdot p^+ + m & \textref{sub:theorem-4j} \\ + & \in n \cdot p^+ + m & \textref{par:theorem-4n-i} \\ + & = m + n \cdot p^+ & \textref{sub:theorem-4k-2} \\ + & \in n + n \cdot p^+ & \textref{par:theorem-4n-i} \\ + & = n \cdot p^+ + n & \textref{sub:theorem-4k-2} \\ + & = n \cdot p^{++}. & \textref{sub:theorem-4j} + \end{align*} + Therefore $p^+ \in S$. - \subparagraph{($\Leftarrow$)}% + Thus $S$ is an \nameref{ref:inductive-set}. + Hence \nameref{sub:theorem-4b} implies $S = \omega$. + By \nameref{sub:theorem-4c}, every natural number except 0 is the + successor of some natural number. + Therefore, for all $p \in \omega$ such that $p \neq 0$, $m \in n$ + implies $m \cdot p \in n \cdot p$. - Let $p \neq 0$ be a natural number and suppose $m \cdot p \in n \cdot p$. - By the \nameref{sub:trichotomy-law-natural-numbers}, there are two - cases to consider regarding how $m$ and $n$ relate to one another: + \subparagraph{($\Leftarrow$)}% - \vspace{8pt} - \textbf{Case 1}: Suppose $m = n$. - Then $m \cdot p \in n \cdot p = m \cdot p$. - \nameref{sub:lemma-4l-b} shows this is impossible. + Let $p \neq 0$ be a natural number and suppose $m \cdot p \in n \cdot p$. + By the \nameref{sub:trichotomy-law-natural-numbers}, there are two + cases to consider regarding how $m$ and $n$ relate to one another: - \vspace{8pt} - \textbf{Case 2}: Suppose $n \in m$. - Then \nameref{spar:theorem-4n-ii-right} indicates - $n \cdot p \in m \cdot p$. - But this contradicts \nameref{sub:trichotomy-law-natural-numbers} since, - by hypothesis, $m \cdot p \in n \cdot p$. + \vspace{8pt} + \textbf{Case 1}: Suppose $m = n$. + Then $m \cdot p \in n \cdot p = m \cdot p$. + \nameref{sub:lemma-4l-b} shows this is impossible. - \vspace{8pt} - \textbf{Conclusion}: By trichotomy, it follows $m \in n$. + \vspace{8pt} + \textbf{Case 2}: Suppose $n \in m$. + Then \nameref{spar:theorem-4n-ii-right} indicates + $n \cdot p \in m \cdot p$. + But this contradicts \nameref{sub:trichotomy-law-natural-numbers} since, + by hypothesis, $m \cdot p \in n \cdot p$. -\end{proof} + \vspace{8pt} + \textbf{Conclusion}: By trichotomy, it follows $m \in n$. + + \end{proof} \subsection{\pending{Corollary 4P}}% \hyperlabel{sub:corollary-4p} -\begin{corollary}[4P] + \begin{corollary}[4P] + The following cancellation laws hold for $m$, $n$, and $p$ in $\omega$: + \begin{align} + m + p = n + p & \Rightarrow m = n, + & \hyperlabel{sub:corollary-4p-eq1} \\ + m \cdot p = n \cdot p \land p \neq 0 & \Rightarrow m = n. + & \hyperlabel{sub:corollary-4p-eq2} + \end{align} + \end{corollary} - The following cancellation laws hold for $m$, $n$, and $p$ in $\omega$: - \begin{align} - m + p = n + p & \Rightarrow m = n, - & \hyperlabel{sub:corollary-4p-eq1} \\ - m \cdot p = n \cdot p \land p \neq 0 & \Rightarrow m = n. - & \hyperlabel{sub:corollary-4p-eq2} - \end{align} - -\end{corollary} - -\begin{proof} - - \statementpadding - - \lean*{Init/Data/Nat/Basic}{Nat.add\_right\_cancel} + \lean{Init/Data/Nat/Basic}{Nat.add\_right\_cancel} \code{Common/Nat/Basic}{Nat.mul\_right\_cancel} - \paragraph{\eqref{sub:corollary-4p-eq1}}% + \begin{proof} - Suppose $m + p = n + p$. - By the \nameref{sub:trichotomy-law-natural-numbers}, there are two - cases to consider regarding how $m$ and $n$ relate to one another. - If $m \in n$, then \nameref{sub:theorem-4n} implies $m + p \in n + p$. - If $n \in m$, then \nameref{sub:theorem-4n} implies $n + p \in m + p$. - Both of these contradict the \nameref{sub:trichotomy-law-natural-numbers} of - $m + p$ and $n + p$. - Thus $m = n$ is the only remaining possibility. + \paragraph{\eqref{sub:corollary-4p-eq1}}% - \paragraph{\eqref{sub:corollary-4p-eq2}}% + Suppose $m + p = n + p$. + By the \nameref{sub:trichotomy-law-natural-numbers}, there are two + cases to consider regarding how $m$ and $n$ relate to one another. + If $m \in n$, then \nameref{sub:theorem-4n} implies $m + p \in n + p$. + If $n \in m$, then \nameref{sub:theorem-4n} implies $n + p \in m + p$. + Both of these contradict the \nameref{sub:trichotomy-law-natural-numbers} + of $m + p$ and $n + p$. + Thus $m = n$ is the only remaining possibility. - Suppose $m \cdot p = n \cdot p$ and $p \neq 0$. - By the \nameref{sub:trichotomy-law-natural-numbers}, there are two - cases to consider regarding how $m$ and $n$ relate to one another. - If $m \in n$, then \nameref{sub:theorem-4n} implies - $m \cdot p \in n \cdot p$. - If $n \in m$, then \nameref{sub:theorem-4n} implies - $n \cdot p \in m \cdot p$. - Both of these contradict the \nameref{sub:trichotomy-law-natural-numbers} of - $m \cdot p$ and $n \cdot p$. - Thus $m = n$ is the only remaining possibility. + \paragraph{\eqref{sub:corollary-4p-eq2}}% -\end{proof} + Suppose $m \cdot p = n \cdot p$ and $p \neq 0$. + By the \nameref{sub:trichotomy-law-natural-numbers}, there are two + cases to consider regarding how $m$ and $n$ relate to one another. + If $m \in n$, then \nameref{sub:theorem-4n} implies + $m \cdot p \in n \cdot p$. + If $n \in m$, then \nameref{sub:theorem-4n} implies + $n \cdot p \in m \cdot p$. + Both of these contradict the \nameref{sub:trichotomy-law-natural-numbers} + of $m \cdot p$ and $n \cdot p$. + Thus $m = n$ is the only remaining possibility. + + \end{proof} \subsection{\sorry{% Well Ordering of \texorpdfstring{$\omega$}{Natural Numbers}}}% \hyperlabel{sub:well-ordering-natural-numbers} -\begin{theorem} + \begin{theorem} + Let $A$ be a nonempty subset of $\omega$. + Then there is some $m \in A$ such that $m \ineq n$ for all $n \in A$. + \end{theorem} - Let $A$ be a nonempty subset of $\omega$. - Then there is some $m \in A$ such that $m \ineq n$ for all $n \in A$. - -\end{theorem} - -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Corollary 4Q}}% \hyperlabel{sub:corollary-4q} -\begin{corollary}[4Q] + \begin{corollary}[4Q] + There is no function $f \colon \omega \rightarrow \omega$ such that + $f(n^+) \in f(n)$ for every natural number $n$. + \end{corollary} - There is no function $f \colon \omega \rightarrow \omega$ such that - $f(n^+) \in f(n)$ for every natural number $n$. - -\end{corollary} - -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{% Strong Induction Principle for \texorpdfstring{$\omega$}{Natural Numbers}}}% \hyperlabel{sub:strong-induction-principle-natural-numbers} -\begin{theorem} + \begin{theorem} + Let $A$ be a subset of $\omega$, and assume that for every $n \in \omega$, + $$\text{if every number less than } n \text{ is in } A, + \text{ then } n \in A.$$ + Then $A = \omega$. + \end{theorem} - Let $A$ be a subset of $\omega$, and assume that for every $n \in \omega$, - $$\text{if every number less than } n \text{ is in } A, - \text{ then } n \in A.$$ - Then $A = \omega$. - -\end{theorem} - -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \section{Exercises 4}% \hyperlabel{sec:exercises-4} @@ -7809,713 +7267,671 @@ Show that $<_L$ is a linear ordering on $A \times B$. \subsection{\verified{Exercise 4.1}}% \hyperlabel{sub:exercise-4.1} -Show that $1 \neq 3$ i.e., that $\emptyset^+ \neq \emptyset^{+++}$. + Show that $1 \neq 3$ i.e., that $\emptyset^+ \neq \emptyset^{+++}$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_4} + \code*{Bookshelf/Enderton/Set/Chapter\_4} {Enderton.Set.Chapter\_4.exercise\_4\_1} - By definition, - \begin{align*} - 1 & = \{\emptyset\} \\ - 3 & = \{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}. - \end{align*} - By the \nameref{ref:extensionality-axiom}, these two sets are trivially not - equal to one another. - -\end{proof} + \begin{proof} + By definition, + \begin{align*} + 1 & = \{\emptyset\} \\ + 3 & = \{\emptyset, \{\emptyset\}, \{\emptyset, \{\emptyset\}\}\}. + \end{align*} + By the \nameref{ref:extensionality-axiom}, these two sets are trivially not + equal to one another. + \end{proof} \subsection{\unverified{Exercise 4.2}}% \hyperlabel{sub:exercise-4.2} -Show that if $a$ is a transitive set, then $a^+$ is also a transitive set. + Show that if $a$ is a transitive set, then $a^+$ is also a transitive set. -\begin{proof} - - Suppose $a$ is a \nameref{ref:transitive-set}. - By \nameref{sub:theorem-4e}, it follows $\bigcup \left(a^+\right) = a$. - By definition of a \nameref{ref:successor}, $a^+ = a \cup \{a\}$. - Thus it immediately follows - $$\bigcup \left(a^+\right) = a \subseteq a \cup \{a\} = a^+.$$ - Therefore $a^+$ is indeed a transitive set. - -\end{proof} + \begin{proof} + Suppose $a$ is a \nameref{ref:transitive-set}. + By \nameref{sub:theorem-4e}, it follows $\bigcup \left(a^+\right) = a$. + By definition of a \nameref{ref:successor}, $a^+ = a \cup \{a\}$. + Thus it immediately follows + $$\bigcup \left(a^+\right) = a \subseteq a \cup \{a\} = a^+.$$ + Therefore $a^+$ is indeed a transitive set. + \end{proof} \subsection{\unverified{Exercise 4.3}}% \hyperlabel{sub:exercise-4.3} -\begin{enumerate}[(a)] - \item Show that if $a$ is a transitive set, then $\powerset{a}$ is also a - transitive set. - \item Show that if $\powerset{a}$ is a transitive set, then $a$ is also a - transitive set. -\end{enumerate} + \begin{enumerate}[(a)] + \item Show that if $a$ is a transitive set, then $\powerset{a}$ is also a + transitive set. + \item Show that if $\powerset{a}$ is a transitive set, then $a$ is also a + transitive set. + \end{enumerate} -\begin{proof} + \begin{proof} - \paragraph{(a)}% + \paragraph{(a)}% - Suppose $a$ is a \nameref{ref:transitive-set}. - We show that $\bigcup \powerset{a} \subseteq \powerset{a}$. - Let $t \in \bigcup \powerset{a}$. - By definition of the \nameref{ref:power-set}, there exists some - $X \subseteq a$ such that $t \in X$. - Thus $t \in a$. - Because $a$ is a transitive set, every member of $t$ is a member of $a$. - In other words, $t \subseteq a$. - Equivalently, $t \in \powerset{a}$. + Suppose $a$ is a \nameref{ref:transitive-set}. + We show that $\bigcup \powerset{a} \subseteq \powerset{a}$. + Let $t \in \bigcup \powerset{a}$. + By definition of the \nameref{ref:power-set}, there exists some + $X \subseteq a$ such that $t \in X$. + Thus $t \in a$. + Because $a$ is a transitive set, every member of $t$ is a member of $a$. + In other words, $t \subseteq a$. + Equivalently, $t \in \powerset{a}$. - \paragraph{(b)}% + \paragraph{(b)}% - Suppose $\powerset{a}$ is a transitive set. - We show that $\bigcup a \subseteq a$. - Let $t \in \bigcup a$. - Then there exists some $b \in a$ such that $t \in b$. - Since $\{b\}$ is a member of $\powerset{a}$ and $\powerset{a}$ is a - transitive set, $b \in \powerset{a}$. - That is, $b \subseteq a$. - Thus $t \in a$. + Suppose $\powerset{a}$ is a transitive set. + We show that $\bigcup a \subseteq a$. + Let $t \in \bigcup a$. + Then there exists some $b \in a$ such that $t \in b$. + Since $\{b\}$ is a member of $\powerset{a}$ and $\powerset{a}$ is a + transitive set, $b \in \powerset{a}$. + That is, $b \subseteq a$. + Thus $t \in a$. -\end{proof} + \end{proof} \subsection{\unverified{Exercise 4.4}}% \hyperlabel{sub:exercise-4.4} -Show that if $a$ is a transitive set, then $\bigcup a$ is also a transitive set. + Show that if $a$ is a transitive set, then $\bigcup a$ is also a transitive set. -\begin{proof} - - Suppose $a$ is a transitive set. - We show that $\bigcup\bigcup{a} \subseteq \bigcup a$. - Let $t \in \bigcup\bigcup{a}$. - Then there exists some $b \in \bigcup{a}$ such that $t \in b$. - Since $a$ is transitive, $\bigcup{a} \subseteq a$. - Thus $b \in a$ and $t \in \bigcup a$. - -\end{proof} + \begin{proof} + Suppose $a$ is a transitive set. + We show that $\bigcup\bigcup{a} \subseteq \bigcup a$. + Let $t \in \bigcup\bigcup{a}$. + Then there exists some $b \in \bigcup{a}$ such that $t \in b$. + Since $a$ is transitive, $\bigcup{a} \subseteq a$. + Thus $b \in a$ and $t \in \bigcup a$. + \end{proof} \subsection{\unverified{Exercise 4.5}}% \hyperlabel{sub:exercise-4.5} -Assume that every member of $\mathscr{A}$ is a transitive set. + Assume that every member of $\mathscr{A}$ is a transitive set. + \begin{enumerate}[(a)] + \item Show that $\bigcup\mathscr{A}$ is a transitive set. + \item Show that $\bigcap\mathscr{A}$ is a transitive set (assume that + $\mathscr{A}$ is nonempty). + \end{enumerate} -\begin{enumerate}[(a)] - \item Show that $\bigcup\mathscr{A}$ is a transitive set. - \item Show that $\bigcap\mathscr{A}$ is a transitive set (assume that - $\mathscr{A}$ is nonempty). -\end{enumerate} + \begin{proof} -\begin{proof} + \paragraph{(a)}% - \paragraph{(a)}% + Suppose every member of $\mathscr{A}$ is a transitive set. + We show that $\bigcup\bigcup{\mathscr{A}} \subseteq \bigcup{\mathscr{A}}$. + Let $t \in \bigcup\bigcup{\mathscr{A}}$. + Then there exists some $b_1 \in \bigcup{\mathscr{A}}$ such that + $t \in b_1$. + Likewise there exists some $b_2 \in \mathscr{A}$ such that $b_1 \in b_2$. + By hypothesis, $b_2$ is transitive meaning $t \in b_2$. + Thus $t \in \bigcup{\mathscr{A}}$. - Suppose every member of $\mathscr{A}$ is a transitive set. - We show that $\bigcup\bigcup{\mathscr{A}} \subseteq \bigcup{\mathscr{A}}$. - Let $t \in \bigcup\bigcup{\mathscr{A}}$. - Then there exists some $b_1 \in \bigcup{\mathscr{A}}$ such that $t \in b_1$. - Likewise there exists some $b_2 \in \mathscr{A}$ such that $b_1 \in b_2$. - By hypothesis, $b_2$ is transitive meaning $t \in b_2$. - Thus $t \in \bigcup{\mathscr{A}}$. + \paragraph{(b)}% - \paragraph{(b)}% + Suppose every member of nonempty set $\mathscr{A}$ is a transitive set. + We show that $\bigcup\bigcap{\mathscr{A}} \subseteq \bigcap{\mathscr{A}}$. + Let $t \in \bigcup\bigcap{\mathscr{A}}$. + Then there exists some $b \in \bigcap{\mathscr{A}}$ such that $t \in b$. + Thus $b$ is a member of every member of $\mathscr{A}$. + By hypothesis, every member of $\mathscr{A}$ is a transitive set meaning + $t$ must be a member of every member of $\mathscr{A}$. + In other words, $t \in \bigcap{\mathscr{A}}$. - Suppose every member of nonempty set $\mathscr{A}$ is a transitive set. - We show that $\bigcup\bigcap{\mathscr{A}} \subseteq \bigcap{\mathscr{A}}$. - Let $t \in \bigcup\bigcap{\mathscr{A}}$. - Then there exists some $b \in \bigcap{\mathscr{A}}$ such that $t \in b$. - Thus $b$ is a member of every member of $\mathscr{A}$. - By hypothesis, every member of $\mathscr{A}$ is a transitive set meaning - $t$ must be a member of every member of $\mathscr{A}$. - In other words, $t \in \bigcap{\mathscr{A}}$. - -\end{proof} + \end{proof} \subsection{\unverified{Exercise 4.6}}% \hyperlabel{sub:exercise-4.6} -Prove the converse to \nameref{sub:theorem-4e}: If - $\bigcup \left(a^+\right) = a$, then $a$ is a transitive set. + Prove the converse to \nameref{sub:theorem-4e}: If + $\bigcup \left(a^+\right) = a$, then $a$ is a transitive set. -\begin{proof} - - Let $a$ be a set such that $\bigcup \left(a^+\right) = a$. - Then - \begin{align*} - \bigcup \left(a^+\right) - & = \bigcup (a \cup \{a\}) & \textref{ref:successor} \\ - & = \bigcup a \cup \bigcup \{a\} & \textref{sub:exercise-2.21} \\ - & = a. & \text{by hypothesis} - \end{align*} - But $$\bigcup{a} \subseteq \bigcup a \cup \bigcup \{a\} = a.$$ - Thus $a$ is indeed a \nameref{ref:transitive-set}. - -\end{proof} + \begin{proof} + Let $a$ be a set such that $\bigcup \left(a^+\right) = a$. + Then + \begin{align*} + \bigcup \left(a^+\right) + & = \bigcup (a \cup \{a\}) & \textref{ref:successor} \\ + & = \bigcup a \cup \bigcup \{a\} & \textref{sub:exercise-2.21} \\ + & = a. & \text{by hypothesis} + \end{align*} + But $$\bigcup{a} \subseteq \bigcup a \cup \bigcup \{a\} = a.$$ + Thus $a$ is indeed a \nameref{ref:transitive-set}. + \end{proof} \subsection{\unverified{Exercise 4.7}}% \hyperlabel{sub:exercise-4.7} -Complete part 4 of the proof of the - \nameref{sub:recursion-theorem-natural-numbers}. + Complete part 4 of the proof of the + \nameref{sub:recursion-theorem-natural-numbers}. -\begin{proof} - - Refer to \nameref{par:recursion-theorem-natural-numbers-iv}. - -\end{proof} + \begin{proof} + Refer to \nameref{par:recursion-theorem-natural-numbers-iv}. + \end{proof} \subsection{\unverified{Exercise 4.8}}% \hyperlabel{sub:exercise-4.8} -Let $f$ be a one-to-one function from $A$ into $A$, and assume that - $c \in A - \ran{f}$. -Define $h \colon \omega \rightarrow A$ by recursion: - \begin{align*} - h(0) & = c, \\ - h(n^+) & = f(h(n)). - \end{align*} -Show that $h$ is one-to-one. + Let $f$ be a one-to-one function from $A$ into $A$, and assume that + $c \in A - \ran{f}$. + Define $h \colon \omega \rightarrow A$ by recursion: + \begin{align*} + h(0) & = c, \\ + h(n^+) & = f(h(n)). + \end{align*} + Show that $h$ is one-to-one. -\begin{proof} + \begin{proof} - Let - $$S = \{x \in \omega \mid \forall y, - \left[ h(x) = h(y) \Rightarrow x = y \right]\}.$$ - We prove that (i) $S$ is an \nameref{ref:inductive-set} and (ii) that $h$ is - one-to-one. + Let + $$S = \{x \in \omega \mid \forall y, + \left[ h(x) = h(y) \Rightarrow x = y \right]\}.$$ + We prove that (i) $S$ is an \nameref{ref:inductive-set} and (ii) that $h$ is + one-to-one. - \paragraph{(i)}% - \label{par:exercise-4.8-i} + \paragraph{(i)}% + \hyperlabel{par:exercise-4.8-i} - We first show that $0 \in S$. - Suppose there exists some $n \in \omega$ such that $h(0) = c = h(n)$. - For the sake of contradiction, suppose $n \neq 0$. - By \nameref{sub:theorem-4c}, there exists some $m$ such that $m^+ = n$. - Then $$h(n) = h(m^+) = f(h(m)) = c.$$ - But $c \in A - \ran{f}$, meaning the previous identity is an impossibility. - Thus $n = 0$, i.e. $0 \in S$. + We first show that $0 \in S$. + Suppose there exists some $n \in \omega$ such that $h(0) = c = h(n)$. + For the sake of contradiction, suppose $n \neq 0$. + By \nameref{sub:theorem-4c}, there exists some $m$ such that $m^+ = n$. + Then $$h(n) = h(m^+) = f(h(m)) = c.$$ + But $c \in A - \ran{f}$, meaning the previous identity is an + impossibility. + Thus $n = 0$, i.e. $0 \in S$. - Next, suppose $y, n \in \omega$ such that $n \in S$ and $h(n^+) = h(y)$. - We must show $n^+ \in S$. - There are two cases to consider: + Next, suppose $y, n \in \omega$ such that $n \in S$ and $h(n^+) = h(y)$. + We must show $n^+ \in S$. + There are two cases to consider: - \subparagraph{Case 1}% + \subparagraph{Case 1}% - Suppose $y = 0$. - Then $h(y) = h(0) = c = h(n^+) = f(h(n))$. - Since $c \in A - \ran{f}$, $f(h(n)) \neq c$. - Thus $y \neq 0$, a contradiction. + Suppose $y = 0$. + Then $h(y) = h(0) = c = h(n^+) = f(h(n))$. + Since $c \in A - \ran{f}$, $f(h(n)) \neq c$. + Thus $y \neq 0$, a contradiction. - \subparagraph{Case 2}% + \subparagraph{Case 2}% - Suppose $y \neq 0$. - \nameref{sub:theorem-4c} implies there exists some $z \in \omega$ such - that $z^+ = y$. - Thus $$h(n^+) = f(h(n)) = f(h(z)) = h(z^+).$$ - But $f$ is one-to-one meaning $h(n) = h(z)$. - Since $n \in S$, $h(n) = h(z)$ implies $n = z$ which in turn implies - $n^+ = z^+ = y$. - Thus $n^+$ is in $S$. + Suppose $y \neq 0$. + \nameref{sub:theorem-4c} implies there exists some $z \in \omega$ such + that $z^+ = y$. + Thus $$h(n^+) = f(h(n)) = f(h(z)) = h(z^+).$$ + But $f$ is one-to-one meaning $h(n) = h(z)$. + Since $n \in S$, $h(n) = h(z)$ implies $n = z$ which in turn implies + $n^+ = z^+ = y$. + Thus $n^+$ is in $S$. - \paragraph{(ii)}% + \paragraph{(ii)}% - By \nameref{par:exercise-4.8-i}, $S \subseteq \omega$ is an inductive set. - Then \nameref{sub:theorem-4b} states $S = \omega$. - Hence $h$ is one-to-one. + By \nameref{par:exercise-4.8-i}, $S \subseteq \omega$ is an inductive set. + Then \nameref{sub:theorem-4b} states $S = \omega$. + Hence $h$ is one-to-one. -\end{proof} + \end{proof} \subsection{\unverified{Exercise 4.9}}% \hyperlabel{sub:exercise-4.9} -Let $f$ be a function from $B$ into $B$, and assume that $A \subseteq B$. -We have two possible methods for constructing the "closure" $C$ of $A$ under - $f$. -First define $C^*$ to be the intersection of the closed supersets of $A$: - \begin{equation} - \label{sub:exercise-4.9-eq1} - C^* = \bigcap\{X \mid - A \subseteq X \subseteq B \land \img{f}{X} \subseteq X\}. - \end{equation} -Alternatively, we could apply the recursion theorem to obtain the function $h$ - for which - \begin{align*} - h(0) & = A, \\ - h(n^+) & = h(n) \cup \img{f}{h(n)}. - \end{align*} -Clearly $h(0) \subseteq h(1) \subseteq \cdots$; define $C_*$ to be - $\bigcup\ran{h}$; in other words - \begin{equation} - \label{sub:exercise-4.9-eq2} - C_* = \bigcup_{i \in \omega} h(i). - \end{equation} -Show that $C^* = C_*$. -[\textit{Suggestion}: -To show that $C^* \subseteq C_*$, show that $\img{f}{C_*} \subseteq C_*$. -To show that $C_* \subseteq C^*$, use induction to show that - $h(n) \subseteq C^*$.] + Let $f$ be a function from $B$ into $B$, and assume that $A \subseteq B$. + We have two possible methods for constructing the "closure" $C$ of $A$ under + $f$. + First define $C^*$ to be the intersection of the closed supersets of $A$: + \begin{equation} + \hyperlabel{sub:exercise-4.9-eq1} + C^* = \bigcap\{X \mid + A \subseteq X \subseteq B \land \img{f}{X} \subseteq X\}. + \end{equation} + Alternatively, we could apply the recursion theorem to obtain the function $h$ + for which + \begin{align*} + h(0) & = A, \\ + h(n^+) & = h(n) \cup \img{f}{h(n)}. + \end{align*} + Clearly $h(0) \subseteq h(1) \subseteq \cdots$; define $C_*$ to be + $\bigcup\ran{h}$; in other words + \begin{equation} + \hyperlabel{sub:exercise-4.9-eq2} + C_* = \bigcup_{i \in \omega} h(i). + \end{equation} + Show that $C^* = C_*$. + [\textit{Suggestion}: + To show that $C^* \subseteq C_*$, show that $\img{f}{C_*} \subseteq C_*$. + To show that $C_* \subseteq C^*$, use induction to show that + $h(n) \subseteq C^*$.] -\begin{proof} + \begin{proof} - We show that $C^* \subseteq C_*$ and $C^* \supseteq C_*$. + We show that $C^* \subseteq C_*$ and $C^* \supseteq C_*$. - \paragraph{($\subseteq$)}% + \paragraph{($\subseteq$)}% - It suffices to show $\img{f}{C_*} \subseteq C_*$ since then $C_*$ is a - member of the family of sets being intersected in - \eqref{sub:exercise-4.9-eq1}. - Let $t \in \img{f}{C_*}$. - By definition of the \nameref{ref:image} of a set, there exists some - $u \in C_*$ such that $f(u) = t$. - By \eqref{sub:exercise-4.9-eq2}, there exists some $i \in \omega$ such that - $u \in h(i)$. - Then $t \in \img{f}{h(i)} \subseteq h(i) \cup \img{f}{h(i)} = h(i^+)$. - Therefore \eqref{sub:exercise-4.9-eq2} indicates $t \in C_*$. - - \paragraph{($\supseteq$)}% - - Define $$S = \{n \in \omega \mid h(n) \subseteq C^*\}.$$ - We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. - Afterward we prove that (iii) $C_* \subseteq C^*$. - - \subparagraph{(i)}% - \label{spar:exercise-4.9-i} - - By construction, $h(0) = A$. - It trivially follows that $A \subseteq C^*$ by + It suffices to show $\img{f}{C_*} \subseteq C_*$ since then $C_*$ is a + member of the family of sets being intersected in \eqref{sub:exercise-4.9-eq1}. - Thus $h(0) \subseteq C^*$ meaning $0 \in S$. + Let $t \in \img{f}{C_*}$. + By definition of the \nameref{ref:image} of a set, there exists some + $u \in C_*$ such that $f(u) = t$. + By \eqref{sub:exercise-4.9-eq2}, there exists some $i \in \omega$ such + that $u \in h(i)$. + Then $t \in \img{f}{h(i)} \subseteq h(i) \cup \img{f}{h(i)} = h(i^+)$. + Therefore \eqref{sub:exercise-4.9-eq2} indicates $t \in C_*$. - \subparagraph{(ii)}% - \label{spar:exercise-4.9-ii} + \paragraph{($\supseteq$)}% - Suppose $n \in S$. - That is, $h(n) \subseteq C^*$. - We must prove that $h(n^+) \subseteq C^*$. - Let $$t \in h(n^+) = h(n) \cup \img{f}{h(n)}.$$ - Then either $t \in h(n)$ or $t \in \img{f}{h(n)}$. - If $t \in h(n)$, it immediately follows $t \in C^*$. - If $t \in \img{f}{h(n)}$, then the definition of the \nameref{ref:image} - of a set implies there exists some $u \in h(n)$ such that $f(u) = t$. - Since $h(n) \subseteq C^*$, \eqref{sub:exercise-4.9-eq1} indicates that - $$\forall X, A \subseteq X \subseteq B \land - \img{f}{X} \subseteq X \Rightarrow u \in X.$$ - But then closure under image yields - $$\forall X, A \subseteq X \subseteq B \land - \img{f}{X} \subseteq X \Rightarrow f(u) \in X.$$ - Since $f(u) = t$, $t \in C^*$. - Thus $h(n^+) \subseteq C^*$, i.e. $n^+ \in S$. + Define $$S = \{n \in \omega \mid h(n) \subseteq C^*\}.$$ + We prove that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$. + Afterward we prove that (iii) $C_* \subseteq C^*$. - \subparagraph{(iii)}% + \subparagraph{(i)}% + \label{spar:exercise-4.9-i} - By \nameref{spar:exercise-4.9-i} and \nameref{spar:exercise-4.9-ii}, - $S \subseteq \omega$ is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - That is, for all $n \in \omega$, $h(n) \subseteq C^*$. - Thus $$C_* = \bigcup_{i \in \omega} h(i) \subseteq C^*.$$ + By construction, $h(0) = A$. + It trivially follows that $A \subseteq C^*$ by + \eqref{sub:exercise-4.9-eq1}. + Thus $h(0) \subseteq C^*$ meaning $0 \in S$. - \paragraph{Conclusion}% + \subparagraph{(ii)}% + \label{spar:exercise-4.9-ii} - Since $C^* \subseteq C_*$ and $C_* \subseteq C^*$, it follows $C^* = C_*$. + Suppose $n \in S$. + That is, $h(n) \subseteq C^*$. + We must prove that $h(n^+) \subseteq C^*$. + Let $$t \in h(n^+) = h(n) \cup \img{f}{h(n)}.$$ + Then either $t \in h(n)$ or $t \in \img{f}{h(n)}$. + If $t \in h(n)$, it immediately follows $t \in C^*$. + If $t \in \img{f}{h(n)}$, then the definition of the \nameref{ref:image} + of a set implies there exists some $u \in h(n)$ such that $f(u) = t$. + Since $h(n) \subseteq C^*$, \eqref{sub:exercise-4.9-eq1} indicates that + $$\forall X, A \subseteq X \subseteq B \land + \img{f}{X} \subseteq X \Rightarrow u \in X.$$ + But then closure under image yields + $$\forall X, A \subseteq X \subseteq B \land + \img{f}{X} \subseteq X \Rightarrow f(u) \in X.$$ + Since $f(u) = t$, $t \in C^*$. + Thus $h(n^+) \subseteq C^*$, i.e. $n^+ \in S$. -\end{proof} + \subparagraph{(iii)}% + + By \nameref{spar:exercise-4.9-i} and \nameref{spar:exercise-4.9-ii}, + $S \subseteq \omega$ is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + That is, for all $n \in \omega$, $h(n) \subseteq C^*$. + Thus $$C_* = \bigcup_{i \in \omega} h(i) \subseteq C^*.$$ + + \paragraph{Conclusion}% + + Since $C^* \subseteq C_*$ and $C_* \subseteq C^*$, it follows $C^* = C_*$. + + \end{proof} \subsection{\unverified{Exercise 4.10}}% \hyperlabel{sub:exercise-4.10} -In Exercise 9, assume that $B$ is the set of real numbers, $f(x) = x^2$, and $A$ - is the closed interval $\icc{\frac{1}{2}}{1}$. -What is the set called $C^*$ and $C_*$? + In Exercise 9, assume that $B$ is the set of real numbers, $f(x) = x^2$, and + $A$ is the closed interval $\icc{\frac{1}{2}}{1}$. + What is the set called $C^*$ and $C_*$? -\begin{proof} - - By \nameref{sub:exercise-4.9}, $C^* = C_*$. - By definition, - $$C^* = \bigcap \{X \mid - \icc{\frac{1}{2}}{1} \subseteq X \subseteq \mathbb{R} \land - \img{f}{X} \subseteq X\}.$$ - Since $f(x)$ converges to $0$ for all values $x < 1$, it follows - $C^* = C_* = \ioc{0}{1}$. - -\end{proof} + \begin{proof} + By \nameref{sub:exercise-4.9}, $C^* = C_*$. + By definition, + $$C^* = \bigcap \{X \mid + \icc{\frac{1}{2}}{1} \subseteq X \subseteq \mathbb{R} \land + \img{f}{X} \subseteq X\}.$$ + Since $f(x)$ converges to $0$ for all values $x < 1$, it follows + $C^* = C_* = \ioc{0}{1}$. + \end{proof} \subsection{\unverified{Exercise 4.11}}% \hyperlabel{sub:exercise-4.11} -In Exercise 9, assume that $B$ is the set of real numbers, $f(x) = x - 1$, and - $A = \{0\}$. -What is the set called $C^*$ and $C_*$? + In Exercise 9, assume that $B$ is the set of real numbers, $f(x) = x - 1$, and + $A = \{0\}$. + What is the set called $C^*$ and $C_*$? -\begin{proof} - - By \nameref{sub:exercise-4.9}, $C^* = C_*$. - By definition, $$C_* = \bigcup_{i \in \omega} h(i)$$ where - \begin{align*} - h(0) & = A = \{0\}, \\ - h(n^+) & = h(n) \cup \img{f}{h(n)}. - \end{align*} - Thus $C_* = C^* = \{x \in \mathbb{Z} \mid x \leq 0\}$. - -\end{proof} + \begin{proof} + By \nameref{sub:exercise-4.9}, $C^* = C_*$. + By definition, $$C_* = \bigcup_{i \in \omega} h(i)$$ where + \begin{align*} + h(0) & = A = \{0\}, \\ + h(n^+) & = h(n) \cup \img{f}{h(n)}. + \end{align*} + Thus $C_* = C^* = \{x \in \mathbb{Z} \mid x \leq 0\}$. + \end{proof} \subsection{\sorry{Exercise 4.12}}% \hyperlabel{sub:exercise-4.12} -Formulate an analogue to Exercise 9 for a function - $f \colon B \times B \rightarrow B$. + Formulate an analogue to Exercise 9 for a function + $f \colon B \times B \rightarrow B$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\verified{Exercise 4.13}}% \hyperlabel{sub:exercise-4.13} -Let $m$ and $n$ be natural numbers such that $m \cdot n = 0$. -Show that either $m = 0$ or $n = 0$. + Let $m$ and $n$ be natural numbers such that $m \cdot n = 0$. + Show that either $m = 0$ or $n = 0$. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_4} + \code*{Bookshelf/Enderton/Set/Chapter\_4} {Enderton.Set.Chapter\_4.exercise\_4\_13} - Suppose $m \cdot n = 0$. - For the sake of contradiction, assume $m \neq 0$ and $n \neq 0$. - By \nameref{sub:theorem-4c}, there exists some $p, q \in \omega$ such that - $p^+ = m$ and $q^+ = n$. - Thus - \begin{align*} - m \cdot n - & = m \cdot q^+ \\ - & = m \cdot q + m & \textref{sub:theorem-4j} \\ - & = m \cdot q + p^+ \\ - & = (m \cdot q + p)^+. & \textref{sub:theorem-4i} - \end{align*} - By definition of a \nameref{ref:successor}, - $m \cdot n = (m \cdot q + p)^+ \neq \emptyset = 0$, a contradiction. - Therefore our original assumption was wrong. - Hence $m = 0$ or $n = 0$. - -\end{proof} + \begin{proof} + Suppose $m \cdot n = 0$. + For the sake of contradiction, assume $m \neq 0$ and $n \neq 0$. + By \nameref{sub:theorem-4c}, there exists some $p, q \in \omega$ such that + $p^+ = m$ and $q^+ = n$. + Thus + \begin{align*} + m \cdot n + & = m \cdot q^+ \\ + & = m \cdot q + m & \textref{sub:theorem-4j} \\ + & = m \cdot q + p^+ \\ + & = (m \cdot q + p)^+. & \textref{sub:theorem-4i} + \end{align*} + By definition of a \nameref{ref:successor}, + $m \cdot n = (m \cdot q + p)^+ \neq \emptyset = 0$, a contradiction. + Therefore our original assumption was wrong. + Hence $m = 0$ or $n = 0$. + \end{proof} \subsection{\verified{Exercise 4.14}}% \hyperlabel{sub:exercise-4.14} -Call a natural number \textit{even} if it has the form $2 \cdot m$ for some $m$. -Call it \textit{odd} if it has the form $(2 \cdot p) + 1$ for some $p$. -Show that each natural number is either even or odd, but never both. + Call a natural number \textit{even} if it has the form $2 \cdot m$ for some + $m$. + Call it \textit{odd} if it has the form $(2 \cdot p) + 1$ for some $p$. + Show that each natural number is either even or odd, but never both. -\begin{proof} - - \code{Bookshelf/Enderton/Set/Chapter\_4} + \code*{Bookshelf/Enderton/Set/Chapter\_4} {Enderton.Set.Chapter\_4.exercise\_4\_14} - Let $$S = \{n \in \omega \mid n \text{ is even or odd but not both}\}.$$ - We show that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$ as well. - Afterward we prove (iii) that the theorem statement holds. + \begin{proof} - \paragraph{(i)}% - \hyperlabel{par:exercise-4.14a-i} + Let $$S = \{n \in \omega \mid n \text{ is even or odd but not both}\}.$$ + We show that (i) $0 \in S$ and (ii) if $n \in S$ then $n^+ \in S$ as well. + Afterward we prove (iii) that the theorem statement holds. - $0$ is even since $2 \cdot 0 = 0$ by \nameref{sub:theorem-4j}. - Furthermore, $0$ is not odd since that would imply there exists some - $p$ such that $(2 \cdot p)^+ = 0$. - By definition of \nameref{ref:successor}, this is not possible. - Thus $0 \in S$. + \paragraph{(i)}% + \hyperlabel{par:exercise-4.14a-i} - \paragraph{(ii)}% - \hyperlabel{par:exercise-4.14a-ii} + $0$ is even since $2 \cdot 0 = 0$ by \nameref{sub:theorem-4j}. + Furthermore, $0$ is not odd since that would imply there exists some + $p$ such that $(2 \cdot p)^+ = 0$. + By definition of \nameref{ref:successor}, this is not possible. + Thus $0 \in S$. - Suppose $n \in S$. - Then $n$ is even or odd but not both. + \paragraph{(ii)}% + \hyperlabel{par:exercise-4.14a-ii} - \subparagraph{Case 1}% + Suppose $n \in S$. + Then $n$ is even or odd but not both. - Suppose $n$ is even and not odd. - Then there exists some $m \in \omega$ such that $2 \cdot m = n$. - Therefore $(2 \cdot m)^+ = n^+$. - Hence $n^+$ is odd. + \subparagraph{Case 1}% - For the sake of contradiction, suppose $n^+$ is even. - Then there exists some $p$ such that $2 \cdot p = n^+$. - We consider two additional cases: + Suppose $n$ is even and not odd. + Then there exists some $m \in \omega$ such that $2 \cdot m = n$. + Therefore $(2 \cdot m)^+ = n^+$. + Hence $n^+$ is odd. - \vspace{8pt}\quad - \textbf{Case 1a}: Suppose $p = 0$. - Then, by \nameref{sub:theorem-4j}, $2 \cdot p = 0 = n^+$. - By definition of \nameref{ref:successor}, this is not possible. + For the sake of contradiction, suppose $n^+$ is even. + Then there exists some $p$ such that $2 \cdot p = n^+$. + We consider two additional cases: - \vspace{8pt}\quad - \textbf{Case 1b}: Suppose $p \neq 0$. - Then \nameref{sub:theorem-4c} implies there exists some $q$ such that - $q^+ = p$. - Thus - \begin{align*} - n^+ - & = 2 \cdot p \\ - & = 2 \cdot q^+ \\ - & = q^+ + q^+ \\ - & = (q^+ + q)^+. & \textref{sub:theorem-4i} - \end{align*} - By \nameref{sub:theorem-4d}, the \nameref{ref:successor} operation is - one-to-one meaning $n = q^+ + q$. - But then - \begin{align*} - n - & = q^+ + q \\ - & = q + q^+ & \textref{sub:theorem-4k-2} \\ - & = (q + q)^+ & \textref{sub:theorem-4i} \\ - & = (2 \cdot q)^+, - \end{align*} - indicating $n$ is odd. - This is a contradiction. + \vspace{8pt}\quad + \textbf{Case 1a}: Suppose $p = 0$. + Then, by \nameref{sub:theorem-4j}, $2 \cdot p = 0 = n^+$. + By definition of \nameref{ref:successor}, this is not possible. - \vspace{8pt}\quad - \textbf{Conclusion}: Since the above two cases are exhaustive, it follows - our original assumption is wrong. - That is, $n^+$ is odd but not even. + \vspace{8pt}\quad + \textbf{Case 1b}: Suppose $p \neq 0$. + Then \nameref{sub:theorem-4c} implies there exists some $q$ such that + $q^+ = p$. + Thus + \begin{align*} + n^+ + & = 2 \cdot p \\ + & = 2 \cdot q^+ \\ + & = q^+ + q^+ \\ + & = (q^+ + q)^+. & \textref{sub:theorem-4i} + \end{align*} + By \nameref{sub:theorem-4d}, the \nameref{ref:successor} operation is + one-to-one meaning $n = q^+ + q$. + But then + \begin{align*} + n + & = q^+ + q \\ + & = q + q^+ & \textref{sub:theorem-4k-2} \\ + & = (q + q)^+ & \textref{sub:theorem-4i} \\ + & = (2 \cdot q)^+, + \end{align*} + indicating $n$ is odd. + This is a contradiction. - \subparagraph{Case 2}% + \vspace{8pt}\quad + \textbf{Conclusion}: Since the above two cases are exhaustive, it + follows our original assumption is wrong. + That is, $n^+$ is odd but not even. - Suppose $n$ is odd and not even. - Then there exists some $p \in \omega$ such that $(2 \cdot p)^+ = n$. - Therefore $(2 \cdot p)^{++} = (2 \cdot p^+) = n^+$. - Hence $n^+$ is even. + \subparagraph{Case 2}% - For the sake of contradiction, suppose $n^+$ is odd. - Then there exists some $q$ such that $(2 \cdot q)^+ = n^+$. - By \nameref{sub:theorem-4d}, the \nameref{ref:successor} operation is - one-to-one meaning $2 \cdot q = n$. - But this implies $n$ is even, a contradiction. - Thus our original assumption is wrong. - That is, $n^+$ is even but not odd. + Suppose $n$ is odd and not even. + Then there exists some $p \in \omega$ such that $(2 \cdot p)^+ = n$. + Therefore $(2 \cdot p)^{++} = (2 \cdot p^+) = n^+$. + Hence $n^+$ is even. - \subparagraph{Conclusion}% + For the sake of contradiction, suppose $n^+$ is odd. + Then there exists some $q$ such that $(2 \cdot q)^+ = n^+$. + By \nameref{sub:theorem-4d}, the \nameref{ref:successor} operation is + one-to-one meaning $2 \cdot q = n$. + But this implies $n$ is even, a contradiction. + Thus our original assumption is wrong. + That is, $n^+$ is even but not odd. - Since the foregoing cases are exhaustive, it follows $n^+ \in S$. + \subparagraph{Conclusion}% - \paragraph{(iii)}% + Since the foregoing cases are exhaustive, it follows $n^+ \in S$. - By \nameref{par:exercise-4.14a-i} and \nameref{par:exercise-4.14a-ii}, - $S$ is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus every natural number is either even or odd, but not both. + \paragraph{(iii)}% -\end{proof} + By \nameref{par:exercise-4.14a-i} and \nameref{par:exercise-4.14a-ii}, + $S$ is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus every natural number is either even or odd, but not both. + + \end{proof} \subsection{\verified{Exercise 4.15}}% \hyperlabel{sub:exercise-4.15} -Complete the proof of \nameref{sub:theorem-4k-1}. + Complete the proof of \nameref{sub:theorem-4k-1}. -\begin{proof} - - Refer to \nameref{sub:theorem-4k-1}. - -\end{proof} + \begin{proof} + Refer to \nameref{sub:theorem-4k-1}. + \end{proof} \subsection{\verified{Exercise 4.16}}% \hyperlabel{sub:exercise-4.16} -Complete the proof of \nameref{sub:theorem-4k-5}. + Complete the proof of \nameref{sub:theorem-4k-5}. -\begin{proof} - - Refer to \nameref{sub:theorem-4k-5}. - -\end{proof} + \begin{proof} + Refer to \nameref{sub:theorem-4k-5}. + \end{proof} \subsection{\pending{Exercise 4.17}}% \hyperlabel{sub:exercise-4.17} -Prove that $m^{n+p} = m^n \cdot m^p$. + Prove that $m^{n+p} = m^n \cdot m^p$. -\begin{proof} + \lean*{Data/Nat/Lemmas}{Nat.pow\_add} - \lean{Data/Nat/Lemmas}{Nat.pow\_add} + \begin{proof} - Let $m$ and $n$ be \nameref{ref:natural-number}s and define - \begin{equation} - \hyperlabel{sub:exercise-4.17-eq1} - S = \{p \in \omega \mid m^{n+p} = m^n \cdot m^p\}. - \end{equation} - We prove that (i) $0 \in S$ and (ii) if $p \in S$ then $p^+ \in S$. - Afterwards we show that (iii) our theorem holds. + Let $m$ and $n$ be \nameref{ref:natural-number}s and define + \begin{equation} + \hyperlabel{sub:exercise-4.17-eq1} + S = \{p \in \omega \mid m^{n+p} = m^n \cdot m^p\}. + \end{equation} + We prove that (i) $0 \in S$ and (ii) if $p \in S$ then $p^+ \in S$. + Afterwards we show that (iii) our theorem holds. - \paragraph{(i)}% - \hyperlabel{par:exercise-4.17-i} + \paragraph{(i)}% + \hyperlabel{par:exercise-4.17-i} - Consider $m^{n+0}$: - \begin{align*} - m^{n+0} - & = m^n & \textref{sub:theorem-4i} \\ - & = m^n \cdot 1 & \textref{sub:right-multiplicative-identity} \\ - & = m^n \cdot m^0. & \textref{ref:exponentiation} - \end{align*} - Thus $0 \in S$. + Consider $m^{n+0}$: + \begin{align*} + m^{n+0} + & = m^n & \textref{sub:theorem-4i} \\ + & = m^n \cdot 1 & \textref{sub:right-multiplicative-identity} \\ + & = m^n \cdot m^0. & \textref{ref:exponentiation} + \end{align*} + Thus $0 \in S$. - \paragraph{(ii)}% - \hyperlabel{par:exercise-4.17-ii} + \paragraph{(ii)}% + \hyperlabel{par:exercise-4.17-ii} - Suppose $p \in S$. - Now consider $m^{n+p^+}$: - \begin{align*} - m^{n+p^+} - & = m^{(n + p)^+} & \textref{sub:theorem-4i} \\ - & = E_m(n + p) \cdot m & \textref{ref:exponentiation} \\ - & = m^n \cdot m^p \cdot m & \eqref{sub:exercise-4.17-eq1} \\ - & = m^n \cdot (m^p \cdot m) & \textref{sub:theorem-4k-4} \\ - & = m^n \cdot m^{p^+}. & \textref{ref:exponentiation} - \end{align*} - Thus $p^+ \in S$. + Suppose $p \in S$. + Now consider $m^{n+p^+}$: + \begin{align*} + m^{n+p^+} + & = m^{(n + p)^+} & \textref{sub:theorem-4i} \\ + & = E_m(n + p) \cdot m & \textref{ref:exponentiation} \\ + & = m^n \cdot m^p \cdot m & \eqref{sub:exercise-4.17-eq1} \\ + & = m^n \cdot (m^p \cdot m) & \textref{sub:theorem-4k-4} \\ + & = m^n \cdot m^{p^+}. & \textref{ref:exponentiation} + \end{align*} + Thus $p^+ \in S$. - \paragraph{(iii)}% + \paragraph{(iii)}% - By \nameref{par:exercise-4.17-i} and \nameref{par:exercise-4.17-ii}, - $S \subseteq \omega$ is an \nameref{ref:inductive-set}. - By \nameref{sub:theorem-4b}, $S = \omega$. - Thus for all $m, n, p \in \omega$, it follows that - $m^{n+p} = m^n \cdot m^p$. + By \nameref{par:exercise-4.17-i} and \nameref{par:exercise-4.17-ii}, + $S \subseteq \omega$ is an \nameref{ref:inductive-set}. + By \nameref{sub:theorem-4b}, $S = \omega$. + Thus for all $m, n, p \in \omega$, it follows that + $m^{n+p} = m^n \cdot m^p$. -\end{proof} + \end{proof} \subsection{\sorry{Exercise 4.18}}% \hyperlabel{sub:exercise-4.18} -Simplify $\img{\in_\omega^{-1}}{\{7, 8\}}$. + Simplify $\img{\in_\omega^{-1}}{\{7, 8\}}$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.19}}% \hyperlabel{sub:exercise-4.19} -Prove that if $m$ is a natural number and $d$ is a nonzero number, then there - exist numbers $q$ and $r$ such that $m = (d \cdot q) + r$ and $r$ is less than - $d$. + Prove that if $m$ is a natural number and $d$ is a nonzero number, then there + exist numbers $q$ and $r$ such that $m = (d \cdot q) + r$ and $r$ is less than + $d$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.20}}% \hyperlabel{sub:exercise-4.20} -Let $A$ be a nonempty subset of $\omega$ such that $\bigcup A = A$. -Show that $A = \omega$. + Let $A$ be a nonempty subset of $\omega$ such that $\bigcup A = A$. + Show that $A = \omega$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.21}}% \hyperlabel{sub:exercise-4.21} -Show that no natural number is a subset of any of its elements. + Show that no natural number is a subset of any of its elements. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.22}}% \hyperlabel{sub:exercise-4.22} -Show that for any natural numbers $m$ and $p$ we have $m \in m + p^+$. + Show that for any natural numbers $m$ and $p$ we have $m \in m + p^+$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.23}}% \hyperlabel{sub:exercise-4.23} -Assume that $m$ and $n$ are natural numbers with $m$ less than $n$. -Show that there is some $p$ in $\omega$ for which $m + p^+ = n$. -(It follows form this and the preceding exercise that $m$ is less than $n$ iff - $(\exists p \in \omega)m + p^+ = n$.) + Assume that $m$ and $n$ are natural numbers with $m$ less than $n$. + Show that there is some $p$ in $\omega$ for which $m + p^+ = n$. + (It follows form this and the preceding exercise that $m$ is less than $n$ iff + $(\exists p \in \omega)m + p^+ = n$.) -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.24}}% \hyperlabel{sub:exercise-4.24} -Assume that $m + n = p + q$. -Show that $$m \in p \iff n \in q.$$ + Assume that $m + n = p + q$. + Show that $$m \in p \iff n \in q.$$ -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.25}}% \hyperlabel{sub:exercise-4.25} -Assume that $n \in m$ and $q \in p$. -Show that $$(m \cdot q) + (n \cdot p) \in (m \cdot p) + (n \cdot q).$$ -[\textit{Suggestion:} Use \nameref{sub:exercise-4.23}.] + Assume that $n \in m$ and $q \in p$. + Show that $$(m \cdot q) + (n \cdot p) \in (m \cdot p) + (n \cdot q).$$ + [\textit{Suggestion:} Use \nameref{sub:exercise-4.23}.] -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.26}}% \hyperlabel{sub:exercise-4.26} -Assume that $n \in \omega$ and $f \colon n^+ \rightarrow \omega$. -Show that $\ran{f}$ has a largest element. + Assume that $n \in \omega$ and $f \colon n^+ \rightarrow \omega$. + Show that $\ran{f}$ has a largest element. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.27}}% \hyperlabel{sub:exercise-4.27} -Assume that $A$ is a set, $G$ is a function, and $f_1$ and $f_2$ map $\omega$ - into $A$. -Further assume that for each $n \in \omega$ both $f_1 \restriction n$ and - $f_2 \restriction n$ belong to $\dom{G}$ and - $$f_1(n) = G(f_1 \restriction n) \land f_2(n) = G(f_2 \restriction n).$$ -Show that $f_1 = f_2$. + Assume that $A$ is a set, $G$ is a function, and $f_1$ and $f_2$ map $\omega$ + into $A$. + Further assume that for each $n \in \omega$ both $f_1 \restriction n$ and + $f_2 \restriction n$ belong to $\dom{G}$ and + $$f_1(n) = G(f_1 \restriction n) \land f_2(n) = G(f_2 \restriction n).$$ + Show that $f_1 = f_2$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \subsection{\sorry{Exercise 4.28}}% \hyperlabel{sub:exercise-4.28} -Rewrite the proof of \nameref{sub:theorem-4g} using, in place of induction, the - well-ordering of $\omega$. + Rewrite the proof of \nameref{sub:theorem-4g} using, in place of induction, + the well-ordering of $\omega$. -\begin{proof} - - TODO - -\end{proof} + \begin{proof} + TODO + \end{proof} \end{document} diff --git a/Bookshelf/Enderton/Set/Chapter_2.lean b/Bookshelf/Enderton/Set/Chapter_2.lean index 2386f27..c604ed9 100644 --- a/Bookshelf/Enderton/Set/Chapter_2.lean +++ b/Bookshelf/Enderton/Set/Chapter_2.lean @@ -38,6 +38,153 @@ theorem commutative_law_ii (A B : Set α) exact and_comm _ = B ∩ A := rfl +/-! #### Associative Laws + +For any sets `A`, `B`, and `C`, +``` +A ∪ (B ∪ C) = (A ∪ B) ∪ C +A ∩ (B ∩ C) = (A ∩ B) ∩ C +``` +-/ + +#check Set.union_assoc + +theorem associative_law_i (A B C : Set α) + : A ∪ (B ∪ C) = (A ∪ B) ∪ C := calc A ∪ (B ∪ C) + _ = { x | x ∈ A ∨ x ∈ B ∪ C } := rfl + _ = { x | x ∈ A ∨ (x ∈ B ∨ x ∈ C) } := rfl + _ = { x | (x ∈ A ∨ x ∈ B) ∨ x ∈ C } := by + ext _ + simp only [Set.mem_setOf_eq] + rw [← or_assoc] + _ = { x | x ∈ A ∪ B ∨ x ∈ C } := rfl + _ = (A ∪ B) ∪ C := rfl + +#check Set.inter_assoc + +theorem associative_law_ii (A B C : Set α) + : A ∩ (B ∩ C) = (A ∩ B) ∩ C := calc A ∩ (B ∩ C) + _ = { x | x ∈ A ∧ (x ∈ B ∩ C) } := rfl + _ = { x | x ∈ A ∧ (x ∈ B ∧ x ∈ C) } := rfl + _ = { x | (x ∈ A ∧ x ∈ B) ∧ x ∈ C } := by + ext _ + simp only [Set.mem_setOf_eq] + rw [← and_assoc] + _ = { x | x ∈ A ∩ B ∧ x ∈ C } := rfl + _ = (A ∩ B) ∩ C := rfl + +/-! #### Distributive Laws + +For any sets `A`, `B`, and `C`, +``` +A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C) +A ∪ (B ∩ C) = (A ∪ B) ∩ (A ∪ C) +``` +-/ + +#check Set.inter_distrib_left + +theorem distributive_law_i (A B C : Set α) + : A ∩ (B ∪ C) = (A ∩ B) ∪ (A ∩ C) := calc A ∩ (B ∪ C) + _ = { x | x ∈ A ∧ x ∈ B ∪ C } := rfl + _ = { x | x ∈ A ∧ (x ∈ B ∨ x ∈ C) } := rfl + _ = { x | (x ∈ A ∧ x ∈ B) ∨ (x ∈ A ∧ x ∈ C) } := by + ext _ + exact and_or_left + _ = { x | x ∈ A ∩ B ∨ x ∈ A ∩ C } := rfl + _ = (A ∩ B) ∪ (A ∩ C) := rfl + +#check Set.union_distrib_left + +theorem distributive_law_ii (A B C : Set α) + : A ∪ (B ∩ C) = (A ∪ B) ∩ (A ∪ C) := calc A ∪ (B ∩ C) + _ = { x | x ∈ A ∨ x ∈ B ∩ C } := rfl + _ = { x | x ∈ A ∨ (x ∈ B ∧ x ∈ C) } := rfl + _ = { x | (x ∈ A ∨ x ∈ B) ∧ (x ∈ A ∨ x ∈ C) } := by + ext _ + exact or_and_left + _ = { x | x ∈ A ∪ B ∧ x ∈ A ∪ C } := rfl + _ = (A ∪ B) ∩ (A ∪ C) := rfl + +/-! #### De Morgan's Laws + +For any sets `A`, `B`, and `C`, +``` +C - (A ∪ B) = (C - A) ∩ (C - B) +C - (A ∩ B) = (C - A) ∪ (C - B) +``` +-/ + +#check Set.diff_inter_diff + +theorem de_morgans_law_i (A B C : Set α) + : C \ (A ∪ B) = (C \ A) ∩ (C \ B) := calc C \ (A ∪ B) + _ = { x | x ∈ C ∧ x ∉ A ∪ B } := rfl + _ = { x | x ∈ C ∧ ¬(x ∈ A ∨ x ∈ B) } := rfl + _ = { x | x ∈ C ∧ (x ∉ A ∧ x ∉ B) } := by + ext _ + simp only [Set.mem_setOf_eq] + rw [not_or_de_morgan] + _ = { x | (x ∈ C ∧ x ∉ A) ∧ (x ∈ C ∧ x ∉ B) } := by + ext _ + exact and_and_left + _ = { x | x ∈ C \ A ∧ x ∈ C \ B } := rfl + _ = (C \ A) ∩ (C \ B) := rfl + +#check Set.diff_inter + +theorem de_morgans_law_ii (A B C : Set α) + : C \ (A ∩ B) = (C \ A) ∪ (C \ B) := calc C \ (A ∩ B) + _ = { x | x ∈ C ∧ x ∉ A ∩ B } := rfl + _ = { x | x ∈ C ∧ ¬(x ∈ A ∧ x ∈ B) } := rfl + _ = { x | x ∈ C ∧ (x ∉ A ∨ x ∉ B) } := by + ext _ + simp only [Set.mem_setOf_eq] + rw [not_and_de_morgan] + _ = { x | (x ∈ C ∧ x ∉ A) ∨ (x ∈ C ∧ x ∉ B) } := by + ext _ + exact and_or_left + _ = { x | x ∈ C \ A ∨ x ∈ C \ B } := rfl + _ = (C \ A) ∪ (C \ B) := rfl + +/-! #### Identities Involving ∅ + +For any set `A`, +``` +A ∪ ∅ = A +A ∩ ∅ = ∅ +A ∩ (C - A) = ∅ +``` +-/ + +#check Set.union_empty + +theorem emptyset_identity_i (A : Set α) + : A ∪ ∅ = A := calc A ∪ ∅ + _ = { x | x ∈ A ∨ x ∈ ∅ } := rfl + _ = { x | x ∈ A ∨ False } := rfl + _ = { x | x ∈ A } := by simp + _ = A := rfl + +#check Set.inter_empty + +theorem emptyset_identity_ii (A : Set α) + : A ∩ ∅ = ∅ := calc A ∩ ∅ + _ = { x | x ∈ A ∧ x ∈ ∅ } := rfl + _ = { x | x ∈ A ∧ False } := rfl + _ = { x | False } := by simp + _ = ∅ := rfl + +#check Set.inter_diff_self + +theorem emptyset_identity_iii (A C : Set α) + : A ∩ (C \ A) = ∅ := calc A ∩ (C \ A) + _ = { x | x ∈ A ∧ x ∈ C \ A } := rfl + _ = { x | x ∈ A ∧ (x ∈ C ∧ x ∉ A) } := rfl + _ = { x | x ∈ C ∧ False } := by simp + _ = { x | False } := by simp + _ = ∅ := rfl + /-- #### Exercise 2.1 Assume that `A` is the set of integers divisible by `4`. Similarly assume that diff --git a/Bookshelf/Enderton/Set/Chapter_3.lean b/Bookshelf/Enderton/Set/Chapter_3.lean index f6ac7bf..5312990 100644 --- a/Bookshelf/Enderton/Set/Chapter_3.lean +++ b/Bookshelf/Enderton/Set/Chapter_3.lean @@ -19,7 +19,7 @@ namespace Enderton.Set.Chapter_3 If `x ∈ C` and `y ∈ C`, then `⟨x, y⟩ ∈ 𝒫 𝒫 C`. -/ -theorem theorem_3b {C : Set α} (hx : x ∈ C) (hy : y ∈ C) +theorem lemma_3b {C : Set α} (hx : x ∈ C) (hy : y ∈ C) : OrderedPair x y ∈ 𝒫 𝒫 C := by have hxs : {x} ⊆ C := Set.singleton_subset_iff.mpr hx have hxys : {x, y} ⊆ C := Set.mem_mem_imp_pair_subset hx hy diff --git a/Common/Real/Sequence.tex b/Common/Real/Sequence.tex index 965b9d6..40c4738 100644 --- a/Common/Real/Sequence.tex +++ b/Common/Real/Sequence.tex @@ -15,118 +15,118 @@ \subsection{\verified{Arithmetic Series}}% \hyperlabel{sub:sum-arithmetic-series} -Let $(a_i)_{i \geq 0}$ be an arithmetic sequence with common difference $d$. - Then for some $n \in \mathbb{N}$, - \begin{equation} - \hyperlabel{sub:sum-arithmetic-series-eq1} - \sum_{i=0}^n a_i = \frac{(n + 1)(a_0 + a_n)}{2}. - \end{equation} - -\begin{proof} + Let $(a_i)_{i \geq 0}$ be an arithmetic sequence with common difference $d$. + Then for some $n \in \mathbb{N}$, + \begin{equation} + \hyperlabel{sub:sum-arithmetic-series-eq1} + \sum_{i=0}^n a_i = \frac{(n + 1)(a_0 + a_n)}{2}. + \end{equation} \code{Common/Real/Sequence/Arithmetic} {Real.Arithmetic.sum\_recursive\_closed} - Let $(a_i)_{i \geq 0}$ be an arithmetic sequence with common difference $d$. - By definition, for all $k \in \mathbb{N}$, - \begin{equation} - \hyperlabel{sub:sum-arithmetic-series-eq2} - a_k = (a_0 + kd). - \end{equation} - Define predicate $P(n)$ as "identity \eqref{sub:sum-arithmetic-series-eq1} - holds for value $n$." - We use induction to prove $P(n)$ holds for all $n \geq 0$. + \begin{proof} - \paragraph{Base Case}% + Let $(a_i)_{i \geq 0}$ be an arithmetic sequence with common difference $d$. + By definition, for all $k \in \mathbb{N}$, + \begin{equation} + \hyperlabel{sub:sum-arithmetic-series-eq2} + a_k = (a_0 + kd). + \end{equation} + Define predicate $P(n)$ as "identity \eqref{sub:sum-arithmetic-series-eq1} + holds for value $n$." + We use induction to prove $P(n)$ holds for all $n \geq 0$. - Let $k = 0$. - Then $$\sum_{i=0}^k a_i = a_0 = \frac{2a_0}{2} = - \frac{(k + 1)(a_0 + a_k)}{2}.$$ - Therefore $P(0)$ holds. + \paragraph{Base Case}% - \paragraph{Induction Step}% + Let $k = 0$. + Then $$\sum_{i=0}^k a_i = a_0 = \frac{2a_0}{2} = + \frac{(k + 1)(a_0 + a_k)}{2}.$$ + Therefore $P(0)$ holds. - Assume induction hypothesis $P(k)$ holds for some $k \geq 0$. - Then - \begin{align*} - \sum_{i=0}^{k+1} a_i - & = \sum_{i=0}^k a_i + a_{k+1} \\ - & = \frac{(k + 1)(a_0 + a_k)}{2} + a_{k+1} - & \text{induction hypothesis} \\ - & = \frac{(k + 1)(a_0 + (a_0 + kd))}{2} + (a_0 + (k + 1)d) - & \eqref{sub:sum-arithmetic-series-eq2} \\ - & = \frac{(k + 1)(2a_0 + kd)}{2} + (a_0 + (k + 1)d) \\ - & = \frac{(k + 1)(2a_0 + kd) + 2a_0 + 2(k + 1)d}{2} \\ - & = \frac{2ka_0 + k^2d + 4a_0 + kd + 2kd + 2d}{2} \\ - & = \frac{(k + 2)(2a_0 + kd + d)}{2} \\ - & = \frac{(k + 2)(a_0 + a_0 + (k + 1)d)}{2} \\ - & = \frac{(k + 2)(a_0 + a_{k+1})}{2} - & \eqref{sub:sum-arithmetic-series-eq2} \\ - & = \frac{((k + 1) + 1)(a_0 + a_{k+1})}{2}. - \end{align*} - Thus $P(k)$ implies $P(k + 1)$ holds true. + \paragraph{Induction Step}% - \paragraph{Conclusion}% + Assume induction hypothesis $P(k)$ holds for some $k \geq 0$. + Then + \begin{align*} + \sum_{i=0}^{k+1} a_i + & = \sum_{i=0}^k a_i + a_{k+1} \\ + & = \frac{(k + 1)(a_0 + a_k)}{2} + a_{k+1} + & \text{induction hypothesis} \\ + & = \frac{(k + 1)(a_0 + (a_0 + kd))}{2} + (a_0 + (k + 1)d) + & \eqref{sub:sum-arithmetic-series-eq2} \\ + & = \frac{(k + 1)(2a_0 + kd)}{2} + (a_0 + (k + 1)d) \\ + & = \frac{(k + 1)(2a_0 + kd) + 2a_0 + 2(k + 1)d}{2} \\ + & = \frac{2ka_0 + k^2d + 4a_0 + kd + 2kd + 2d}{2} \\ + & = \frac{(k + 2)(2a_0 + kd + d)}{2} \\ + & = \frac{(k + 2)(a_0 + a_0 + (k + 1)d)}{2} \\ + & = \frac{(k + 2)(a_0 + a_{k+1})}{2} + & \eqref{sub:sum-arithmetic-series-eq2} \\ + & = \frac{((k + 1) + 1)(a_0 + a_{k+1})}{2}. + \end{align*} + Thus $P(k)$ implies $P(k + 1)$ holds true. - By mathematical induction, it follows for all $n \geq 0$, $P(n)$ is true. + \paragraph{Conclusion}% -\end{proof} + By mathematical induction, it follows for all $n \geq 0$, $P(n)$ is true. + + \end{proof} \subsection{\verified{Geometric Series}}% \hyperlabel{sub:sum-geometric-series} -Let $(a_i)_{i \geq 0}$ be a geometric sequence with common ratio $r \neq 1$. - Then for some $n \in \mathbb{N}$, - \begin{equation} - \hyperlabel{sub:sum-geometric-series-eq1} - \sum_{i=0}^n a_i = \frac{a_0(1 - r^{n+1})}{1 - r}. - \end{equation} - -\begin{proof} + Let $(a_i)_{i \geq 0}$ be a geometric sequence with common ratio $r \neq 1$. + Then for some $n \in \mathbb{N}$, + \begin{equation} + \hyperlabel{sub:sum-geometric-series-eq1} + \sum_{i=0}^n a_i = \frac{a_0(1 - r^{n+1})}{1 - r}. + \end{equation} \code{Common/Real/Sequence/Geometric} {Real.Geometric.sum\_recursive\_closed} - Let $(a_i)_{i \geq 0}$ be a geometric sequence with common ratio $r \neq 1$. - By definition, for all $k \in \mathbb{N}$, - \begin{equation} - \hyperlabel{sub:sum-geometric-series-eq2} - a_k = a_0r^k. - \end{equation} - Define predicate $P(n)$ as "identity \eqref{sub:sum-geometric-series-eq1} - holds for value $n$." - We use induction to prove $P(n)$ holds for all $n \geq 0$. + \begin{proof} - \paragraph{Base Case}% + Let $(a_i)_{i \geq 0}$ be a geometric sequence with common ratio $r \neq 1$. + By definition, for all $k \in \mathbb{N}$, + \begin{equation} + \hyperlabel{sub:sum-geometric-series-eq2} + a_k = a_0r^k. + \end{equation} + Define predicate $P(n)$ as "identity \eqref{sub:sum-geometric-series-eq1} + holds for value $n$." + We use induction to prove $P(n)$ holds for all $n \geq 0$. - Let $k = 0$. - Then $$\sum_{i=0}^k a_i = a_0 = \frac{a_0(1 - r)}{1 - r} = - \frac{a_0(1 - r^{k+1})}{1 - r}$$ - Therefore $P(0)$ holds. + \paragraph{Base Case}% - \paragraph{Induction Step}% + Let $k = 0$. + Then $$\sum_{i=0}^k a_i = a_0 = \frac{a_0(1 - r)}{1 - r} = + \frac{a_0(1 - r^{k+1})}{1 - r}$$ + Therefore $P(0)$ holds. - Assume induction hypothesis $P(k)$ holds for some $k \geq 0$. - Then - \begin{align*} - \sum_{i=0}^{k+1} a_i - & = \sum_{i=0}^k a_i + a_{k+1} \\ - & = \frac{a_0(1 - r^{k+1})}{1 - r} + a_{k + 1} - & \text{induction hypothesis} \\ - & = \frac{a_0(1 - r^{k+1})}{1 - r} + a_0r^{k + 1} - & \eqref{sub:sum-geometric-series-eq2} \\ - & = \frac{a_0(1 - r^{k+1}) + a_0r^{k+1}(1 - r)}{1 - r} \\ - & = \frac{a_0(1 - r^{k+1} + r^{k+1}(1 - r))}{1 - r} \\ - & = \frac{a_0(1 - r^{k+1} + r^{k+1} - r^{k+2})}{1 - r} \\ - & = \frac{a_0(1 - r^{k+2})}{1 - r} \\ - & = \frac{a_0(1 - r^{(k + 1) + 1})}{1 - r}. - \end{align*} - Thus $P(k)$ implies $P(k + 1)$ holds true. + \paragraph{Induction Step}% - \paragraph{Conclusion}% + Assume induction hypothesis $P(k)$ holds for some $k \geq 0$. + Then + \begin{align*} + \sum_{i=0}^{k+1} a_i + & = \sum_{i=0}^k a_i + a_{k+1} \\ + & = \frac{a_0(1 - r^{k+1})}{1 - r} + a_{k + 1} + & \text{induction hypothesis} \\ + & = \frac{a_0(1 - r^{k+1})}{1 - r} + a_0r^{k + 1} + & \eqref{sub:sum-geometric-series-eq2} \\ + & = \frac{a_0(1 - r^{k+1}) + a_0r^{k+1}(1 - r)}{1 - r} \\ + & = \frac{a_0(1 - r^{k+1} + r^{k+1}(1 - r))}{1 - r} \\ + & = \frac{a_0(1 - r^{k+1} + r^{k+1} - r^{k+2})}{1 - r} \\ + & = \frac{a_0(1 - r^{k+2})}{1 - r} \\ + & = \frac{a_0(1 - r^{(k + 1) + 1})}{1 - r}. + \end{align*} + Thus $P(k)$ implies $P(k + 1)$ holds true. - By mathematical induction, it follows for all $n \geq 0$, $P(n)$ is true. + \paragraph{Conclusion}% -\end{proof} + By mathematical induction, it follows for all $n \geq 0$, $P(n)$ is true. + + \end{proof} \end{document} diff --git a/preamble.tex b/preamble.tex index f5db378..7d59526 100644 --- a/preamble.tex +++ b/preamble.tex @@ -44,61 +44,47 @@ \label{#1}% \hypertarget{#1}{}} -% Denote whether we are working with a standard/Mathlib statement (lean) or a -% custom one (code). +% Denote if working with a predefined statement/theorem or a custom one. \newcommand\@leanlink[4]{% - \textcolor{blue}{\raisebox{-4.5pt}{% - \tikz{\draw (0, 0) node[yscale=-1,xscale=1] {\faFont};}}}% - {-\;}\href{#1/#2.html\##3}{#4}} - + \textcolor{BlueViolet}{\raisebox{-4.5pt}{% + \tikz{\draw (0, 0) node[yscale=-1,xscale=1] {\faFont};}}{-\;}}% + \href{#1/#2.html\##3}{\color{BlueViolet}{#4}}} \newcommand\@codelink[4]{% - \textcolor{blue}{\raisebox{-4.5pt}{% - \tikz{\draw (0, 0) node[] {\faCodeBranch};}}}% - {-\;}\href{#1/#2.html\##3}{#4}} + \textcolor{MidnightBlue}{\raisebox{-4.5pt}{% + \tikz{\draw (0, 0) node[xshift=8pt] {\faCodeBranch};}}{-\;}}% + \href{#1/#2.html\##3}{\color{MidnightBlue}{#4}}} -% Reference to an anchor of Lean documentation. +% Reference to an anchor of generated Lean documentation. \newcommand\leanref[3]{% - \@leanlink{#1}{#2}{#3}{#3}\vspace{10pt}} -\WithSuffix\newcommand\leanref*[3]{% \@leanlink{#1}{#2}{#3}{#3}} - \newcommand\coderef[3]{% - \@codelink{#1}{#2}{#3}{#3}\vspace{10pt}} -\WithSuffix\newcommand\coderef*[3]{% \@codelink{#1}{#2}{#3}{#3}} - -% Variants that allows customizing display text. \newcommand\leanpref[4]{% - \@leanlink{#1}{#2}{#3}{#4}\vspace{10pt}} -\WithSuffix\newcommand\leanpref*[4]{% \@leanlink{#1}{#2}{#3}{#4}} - \newcommand\codepref[4]{% - \@codelink{#1}{#2}{#3}{#4}\vspace{10pt}} -\WithSuffix\newcommand\codepref*[4]{% \@codelink{#1}{#2}{#3}{#4}} % Macro to build all Lean related commands relative to a specified directory. \newcommand\makeleancommands[1]{% \newcommand\lean[2]{% - \leanref{#1}{##1}{##2}} + \noindent\leanref{#1}{##1}{##2}} \WithSuffix\newcommand\lean*[2]{% - \leanref*{#1}{##1}{##2}} + \vspace{6pt}\noindent\leanref{#1}{##1}{##2}} \newcommand\code[2]{% - \coderef{#1}{##1}{##2}} + \noindent\coderef{#1}{##1}{##2}} \WithSuffix\newcommand\code*[2]{% - \coderef*{#1}{##1}{##2}} + \vspace{6pt}\noindent\coderef{#1}{##1}{##2}} \newcommand\leanp[3]{% - \leanpref{#1}{##1}{##2}{##3}} + \noindent\leanpref{#1}{##1}{##2}{##3}} \WithSuffix\newcommand\leanp*[3]{% - \leanpref*{#1}{##1}{##2}{##3}} + \vspace{6pt}\noindent\leanpref{#1}{##1}{##2}{##3}} \newcommand\codep[3]{% - \codepref{#1}{##1}{##2}{##3}} + \noindent\codepref{#1}{##1}{##2}{##3}} \WithSuffix\newcommand\codep*[3]{% - \codepref*{#1}{##1}{##2}{##3}} + \vspace{6pt}\noindent\codepref{#1}{##1}{##2}{##3}} } % ======================================== @@ -124,11 +110,7 @@ \newcommand\@statement[1]{% \linedivider*\paragraph{\normalfont\normalsize\textit{#1.}}} -\newcommand{\statementpadding}{\ \vspace{8pt}} - \newenvironment{answer}{\@statement{Answer}}{\hfill$\square$} -\newenvironment{axiom}{\@statement{Axiom}}{\hfill$\square$} -\newenvironment{definition}{\@statement{Definition}}{\hfill$\square$} \renewenvironment{proof}{\@statement{Proof}}{\hfill$\square$} \newtheorem{corollaryinner}{Corollary}