\documentclass[11pt]{article}
\usepackage{graphicx}
\usepackage{amssymb}
\usepackage{epstopdf}
\DeclareGraphicsRule{.tif}{png}{.png}{`convert #1 `dirname #1`/`basename #1 .tif`.png}

\textwidth = 6.5 in
\textheight = 9 in
\oddsidemargin = 0.0 in
\evensidemargin = 0.0 in
\topmargin = 0.0 in
\headheight = 0.0 in
\headsep = 0.0 in
\parskip = 0.2in
\parindent = 0.0in

\newtheorem{theorem}{Theorem}
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{definition}{Definition}

\begin{document}

\begin{problems}

\item Do each of the following (6 points each).  
\begin{subproblem}
\item Define \emph{prime number}.

$p\in\N-\{1\}$ is prime if the only natural numbers that divide $p$ are
$1$ and $p$.
\vspace*{.2in}

\item State the \emph{well-ordering property}.

Every non-empty set $S\subset\N$ has a smallest element.
\vspace*{.2in}

\item State the contrapositive of the following assertion: 
\emph{If $x_1 \neq x_2$, then $f(x_1)\neq f(x_2)$.} 

If $f(x_1) = f(x_2)$ then $x_1=x_2$.
\vspace*{.2in}

\item Without using words of negation, state the opposite (i.e. negation) 
of the following assertion: \emph{For all $x\in A$ there exists $b\in B$
such that $b>x$.}

There exists $x\in A$ such that for every $b\in B$, we have $x\geq b$.
\vspace*{.2in}

\item Define \emph{increasing function}.

Suppose that $A\subset\R$.  A function $f:A\to\R$ is increasing if for
all $x_1,x_2\in A$, $x_1<x_2$ implies that $f(x_1)<f(x_2)$.
\end{subproblem}
\vspace*{.2in}


\item Four of the following seven assertions are false.  
Identify three of them and give counterexamples on this page and (if
necessary) the next.  If you give counterexamples to more than
three statements, I will simply grade the first three.  
Note that you do not have to justify your counterexamples---only present 
them.  
(10 points each)
\begin{subproblem}
\item Let $f:A\to B$ and $g:B\to C$ be functions.  If $f$ is injective and 
      $g$ is injective then $g\circ g$ is injective.
{\bf True.}
\item Let $f:A\to B$ and $g:B\to C$ be functions.  If $g\circ f$ is injective 
      then $g$ is injective.
{\bf False.}

For example, $f:[0,\infty)\to\R$ given by $f(x) = \sqrt{x}$ and
$g:\R\to\R$ given by $g(x) = x^2$.
\vspace*{.2in}

\item The function $f:\N\times\N\to\N$ given by $f(a,b) = a+b$ is
      surjective. 
{\bf False.}

There is no $(a,b)\in\N\times\N$ such that $f(a,b) = 1$.
\vspace*{.2in}

\item If $A, B, C$ are sets then $(A\cup B)\cap (A\cup C) = A\cap (B\cup C)$
{\bf False.}

For example $A = \{1\}$, $B=C=\emptyset$.
\vspace*{.2in}

\item Let $S = \{(a,b)\in\N\times \N: 2a+b\leq 5\}$.  Then 
      $S\subset [2]\times[2]$.
{\bf False.}

$(1,3) \in S$ but $(1,3)\notin [2]\times[2]$
\vspace*{.2in}

\item Let $A$ and $B$ be sets and $f:A\to B$, $g:B\to A$ be injective
      functions.  Then the cardinality of $A$ is the same as that of $B$.
{\bf True.}

\item Let $A$ and $B$ be sets.  Suppose that $A$ is a subset of $B$,
      but $B$ is not a subset of $A$.  Then the cardinality of $A$
      is not the same as the cardinality of $B$.
{\bf False.}

For example, $A = \N-\{1\}$ and $B=\N$.
\end{subproblem}
\vspace*{.2in}

\item On the remaining pages of this exam, do three of the following four 
problems. If you turn in solutions to all four, I will simply grade the 
first three.  (13 points each)
\begin{subproblem}

\item Let $n\in\N$ be a natural number whose base 3 decimal expansion 
is $122_{(3)}$.  Give the base 7 decimal expansion of $n$.  

\vspace*{.1in}
We have
$$
122_{(3)} = 1\cdot 3^2 + 2\cdot 3^1 + 2\cdot 3^0 = 17 \mbox{ in base 10},
$$
which is equal to
$$
2\cdot 7^1 = 3\cdot 7^0 = 23_{(7)}.
$$
\vspace*{.2in}

\item Prove that there are infinitely many prime numbers.

\vspace*{.1in}
\proof
Given in class.
\qed
\vspace*{.2in}

\item Let $A,B,C$ be sets.  Prove that $A - B \subset A - (B\cap C)$ 

\vspace*{.1in}
\proof
Suppose that $x\in A - B$.  Then $x\in A$ and $x\notin B$.  Hence
$x\notin B\cap C$.  Therefore, $x\in A - (B\cap C)$.  This
shows that $A-B\subset A- (B\cap C).$
\qed
\vspace*{.2in}

\item Prove by induction that $\sum_{i=1}^n 2n-1 = n^2$. 

\vspace*{.1in}
\proof (by induction on $n$)

\noindent{\bf Initial step:} (n=1) We have
$$
\sum_{i=1}^1 2i - 1 = 2\cdot 1 - 1 = 1 = 1^2,
$$
so the assertion holds when $n=1$.

\noindent{\bf Induction step:} Suppose the assertion is true when $n=k$---i.e.
that 
$$
\sum_{i=1}^k 2i-1 = k^2.
$$
Then
$$
\sum_{i=1}^{k+1} 2i-1 = \left(\sum_{i=1}^k 2i-1\right) + 2(k+1)-1
= k^2 + 2k + 2 -1 = k^2 + 2k + 1 = (k+1)^2.
$$
Hence the assertion holds when $n=k+1$.  This completes the induction step
and the proof.
\qed
\vspace*{.2in}


\end{subproblem}

\item How many points should Professor Diller give you for problem 4? 
(1 point total)

\vspace*{.1in}
As many as he's willing.
\end{problems}

\end{document}
