% This is a TeX file
% It is essentially a programming language for mathematics documents
% You can ignore this first portion of the file, as it is essentially a bunch of "include" statements.
\documentclass[10pt]{article}

\usepackage{pictex, latexsym, graphicx,amsmath,amssymb,amsbsy,amsfonts,amsthm,verbatim}
\usepackage{graphics}
\usepackage{hyperref}
\usepackage{fullpage}
\usepackage{fancyhdr}
\usepackage{array}

\usepackage{algorithm,algorithmic}
\usepackage{multirow}

\setlength{\parskip}{0.5em}
\setlength{\parindent}{0em}
\setlength{\voffset}{-0.5in}
\setlength{\headsep}{0.25in}

% The following denotes a counter for the problems.
\newcounter{problem}
\newcommand{\problem}{\textbf{Problem \refstepcounter{problem}.}}

% These are macro shortcuts! Helpful!
\def\vu{\mathbf{u}}
\def\vx{\mathbf{x}}
\def\vb{\mathbf{b}}
\def\vv{\mathbf{v}}
\def\vw{\mathbf{w}}

\renewcommand{\implies}{\rightarrow}
%\newcommand{\lnot}{\neg}
\renewcommand{\lor}{\vee}
\renewcommand{\land}{\wedge}
\newcommand{\xor}{\oplus}
\newcommand{\symmdiff}{\triangle}
\renewcommand{\iff}{\leftrightarrow}
\newcommand{\TRUE}{\mathbf{T}}
\newcommand{\FALSE}{\mathbf{F}}
\newcommand{\universe}{\mathcal{U}}


\def\N{\mathbb{N}}
\def\Q{\mathbb{Q}}
\def\C{\mathbb{C}}
\def\Z{\mathbb{Z}}
\def\R{\mathbb{R}}
\def\cP{\mathcal{P}}



\begin{document}
\pagestyle{fancyplain}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% NOW you can start typing your text that will appear in the PDF!!!

% Note that anything after a '%' is a comment!

% Anything immediately after a '\' is a command. 
% Some denote formatting, some are for special characters.
% The '$' symbol starts and ends "math mode". Use this only for mathematical statements
% In math mode, any sequence of letters is meant to be a list of variables, so use "\sin x" for the sine of x, which will look much different from "sin x"

\lhead{}
\rhead{}
\chead{COM S 330 --- Lecture Notes --- Week of Feb 9--13}

\renewcommand{\arraystretch}{1.25}



\section{Monday, February 9}

\subsection{Rosen 2.4 -- Sequences}

\textbf{Reading:} Rosen 2.4. LLM 4.2. Ducks 8.1, 8.2,

\textbf{Def:} A \emph{sequence} is a function from a (usually infinite) subset of the integers (usually $\N = \{0,1,2,3,\dots\}$ or $\Z^+= \{1,2,3,4,\dots\}$) to a set $S$.  If $a : D \to S$ is a sequence ($D \subseteq \Z$), then we use the notation $a_n$ to denote the image of the integer $n$ under the function $a$. We call $a_n$ a \emph{term} of the sequence. We can use the notation $(a_n)_{n=0}^\infty$ to denote a sequence $(a_0,a_1,a_2,\dots)$ [Think of it as an infinite tuple].

\textbf{Ex:} $a_n = \frac{1}{n}$, $b_n = n^2$, $c_n = \sin\left(\frac{1}{n}\right)$, $d_n = \left(1 + \frac{1}{n}\right)^n$, $\mu_n = |\{ p  : 2 \leq p \leq n, p\text{ is prime }\}|$.

There are a few common sequences that are good to know.

\textbf{Def:} Let $a$ and $r$ be real numbers.  The \emph{geometric sequence} defined by $a$ and $r$ is the sequence
\[
a, ar, ar^2, ar^3, \dots, ar^n, \dots
\]
where the $n$th term is $ar^n$ ($n \in \N$).

\textbf{Def:} Let $a$ and $d$ be real numbers.  The \emph{arithmetic sequence} defined by $a$ and $d$ is the sequence
\[
a, a+d, a+2d, a+3d, \dots, a+nd, \dots
\]
where the $n$th term is $a+nd$ ($n \in \N$).

(The term \emph{geometric} means ``multiply'' while \emph{arithmetic} means ``add.'')

\textbf{Note:} If $b = \log a$ and $d = \log r$, then $\log(ar^n) = \log a + n\log r = b+nd$. Thus, the arithmetic sequence is a log version of the geometric sequence. Alternatively, the geometric sequence is the exponential version of the arithmetic sequence.

\textbf{Def:} A function from a finite set of integers (say $\{1,\dots,n\}$) to a set $S$ is called a \emph{list} or \emph{string}. We use sequence notation to denote the values as $a_1,\dots,a_n$, but since the list is finite, it is very different from a sequence.


\subsubsection{Recurrence Relations}

\textbf{Def:} A \emph{recurrence relation} for the sequence $(a_n)_{n=0}^\infty$ is an equation that expresses $a_n$ in terms of one or more of the previous terms of the sequence, namely $a_0,\dots,a_{n-1}$ for all integer $n \geq n_0$, where $n_0$ is a nonnegative integer. A sequence is called a \emph{solution} of a recurrence relation if its terms satisfy the recurrence relations. (A recurrence relation is said to \emph{recursively define} a sequence.)

\textbf{Natural Numbers:} $a_0 = 0$. For $n > 1$, $a_n = a_{n-1} + 1$. (Solution: $a_n = n$.)

\textbf{Def:} The values of the sequence $a_0,\dots, a_{n_0-1}$ are called the \emph{initial conditions}, as they define the start of the sequence by 

\textbf{Fibonacci Sequence:} $F_0 = 0$, $F_1 = 1$. For $n > 2$, $F_n = F_{n-1} + F_{n-2}$. 
\[
	0,1,1,2,3,5,8,13,21,34,55,\dots
\]
(Solution: $F_n = \frac{\sqrt{5}}{5}\left[\left(\frac{1+\sqrt{5}}{2}\right)^n-\left(\frac{1-\sqrt{5}}{2}\right)^n\right].$ We may talk about why this is true later. Not now!)

\textbf{Lucas Sequence:} $L_0 = 2$, $L_1 = 1$. For $n > 2$, $L_n = L_{n-1} + L_{n-2}$. 
\[
	2,1,3,4,7,11,18,29,47,76,123,\dots
\]
(Solution: $L_n = \left(\frac{1+\sqrt{5}}{2}\right)^n + \left(\frac{1-\sqrt{5}}{2}\right)^n.$ We may talk about why this is true later. Not now!)

\textbf{Note:} When we say ``solution'' above, we really mean \emph{closed form}, where we describe the $n$th term precisely 
	
\textbf{Ex:} Find a closed form for the following sequences:
\begin{enumerate}
\item $a_0 = 1$; for $n \geq 1$, $a_n = a_{n-1} + 5$.
\item $b_0 = 3$; for $n \geq 1$, $b_n = 2b_{n-1}$.
\item $c_0 = 2$; for $n \geq 1$, $c_n = \frac{1}{2}c_{n-1}+1$.
\end{enumerate}

\textbf{Forward Substitution:} Start by writing out all of the terms and see if you notice a pattern.
For the examples above, we have the following lists of initial terms:
\[
( a_n )_{n=0}^\infty = ( 1, 6, 11, 16, 21, \dots ), \qquad
( b_n )_{n=0}^\infty = ( 3, 6, 12, 24, 48, \dots), \qquad
( c_n )_{n=0}^{\infty} = ( 2, 2, 2, 2, 2, \dots).
\]
Notice that from this method we easily see that $c_n = 2$ for all $n \geq 0$.
You may be able to deduce closed forms for $a_n$ and $b_n$ as well.

\textbf{Backward Substitution:} Start with $n$ as a variable and start plugging in terms.
Extend this to the ``full'' recursion and see what happens.
For the examples above, we have the following lists of initial terms:

\begin{center}
\mbox{
\parbox{2in}{
\begin{align*}
a_n &= a_{n-1} + 5 \\
 &= (a_{n-2} + 5) + 5 \\
 &= ((a_{n-3} + 5) + 5) + 5 \\
 &\qquad \vdots\\
 &= ((\cdots ((a_0 \underbrace{+ 5) + 5) + \cdots ) + 5}_{n \text{ terms}}\\
 &= a_0 + 5n = 5n+1.
\end{align*}}
\quad
\parbox{2in}{
\begin{align*}
b_n &= 2b_{n-1} \\
	&= 2(2b_{n-2})\\
	&= 2(2(2b_{n-3}))\\
 &\qquad \vdots\\
	&= \underbrace{2(2(\cdots(2}_{n \text{ terms}}b_0)\cdots))\\
	&= b_02^n  = 3\cdot 2^n
\end{align*}
}}
\end{center}

In a more complicated process of backward substitution, we can try it on our sequence $(c_n)_{n=0}^\infty$.

\begin{align*}
c_n &= \frac{1}{2}c_{n-1} + 1\\
	&= \frac{1}{2}\left(\frac{1}{2}c_{n-1}+1\right)+1\\
	&= \frac{1}{2}\left(\frac{1}{2}\left(\frac{1}{2}c_{n-2} + 1\right) + 1\right) + 1\\
	&= \dots
\end{align*}
This is getting complicated quickly! However, let's distribute all of our terms in order to make better sense of everything!

\begin{align*}
c_n &= \frac{1}{2}c_{n-1} + 1 &&= \frac{1}{2}c_{n-1}+1\\
	&= \frac{1}{2}\left(\frac{1}{2}c_{n-1}+1\right)+1 &&= \frac{1}{4}c_{n-2} + \frac{1}{2} + 1\\
	&= \frac{1}{2}\left(\frac{1}{2}\left(\frac{1}{2}c_{n-2} + 1\right) + 1\right) + 1 &&= \frac{1}{8}c_{n-3} + \frac{1}{4} + \frac{1}{2} + 1\\
	&&&= \dots\\
	&&&= \left(\frac{1}{2}\right)^k c_{n-k} + \sum_{i=0}^{k-1} 2^i\\
	&&&= \dots\\
	&&&= \left(\frac{1}{2}\right)^n c_0 + \sum_{i=0}^{n-1} 2^i\\
	&&&= \left(\frac{1}{2}\right)^{n-1} + \sum_{i=0}^{n-1} 2^i.
\end{align*}
This is a very difficult to compute closed form! This is not nearly as simple as $c_n = 2$.
However, what we need to do is apply a summation identity\footnote{In class, I made a comment about how I remember this formula for $x = 2$: $\sum_{i=0}^k 2^i$ is the binary number $\underbrace{111\cdots 1}_{k+1\text{ digits}}$ and $\underbrace{111\cdots 1}_{k+1\text{ digits}} = 1\!\!\underbrace{000\cdots 0}_{k+1\text{ digits}} - 1$. So $\sum_{i=0}^k 2^i = 2^{k+1} -1 = \frac{2^{k+1}-1}{2-1}$. This extends to larger integers, for instance $x = 3$:  $\sum_{i=0}^k 3^i$ is the \emph{ternary} (base-3) number $\underbrace{111\cdots 1}_{k+1\text{ digits}}$ and $\underbrace{222\cdots 2}_{k+1\text{ digits}} = 1\!\!\underbrace{000\cdots 0}_{k+1\text{ digits}} - 1$, so $\sum_{i=0}^k (3-1)3^i = \frac{3^{k+1}-1}{3-1}$. In general, the base-$b$ number given by $k+1$ digits where each digit is value $b-1$, adding one gets a carry-bit for each term until it is equal to the power $b^{k+1}$, hence $\left[\sum_{i=0}^k (b-1)b^i\right] + 1 = b^{k+1}$ and therefore $\sum_{i=0}^k b^i = \frac{b^{k+1}-1}{b-1}$. }:
\[
	\text{For $x \neq 1$, } \sum_{i=0}^k x^i = \frac{x^{k+1}-1}{x-1}.
\]
Using the above identity with $x = \frac{1}{2}$ we see that
\begin{align*}
	c_n &= \left(\frac{1}{2}\right)^{n-1} + \sum_{i=0}^{n-1}2^i \\
	&=  \left(\frac{1}{2}\right)^{n-1}  + \frac{ \left(\frac{1}{2}\right)^{n}-1}{\frac{1}{2}-1} \\
	&=  \left(\frac{1}{2}\right)^{n-1}  + \frac{ \left(\frac{1}{2}\right)^{n}-1}{-\frac{1}{2}} \\
	&=  \left(\frac{1}{2}\right)^{n-1}  - 2\left(\left(\frac{1}{2}\right)^{n}-1\right) \\
	&=  \left(\frac{1}{2}\right)^{n-1}  - \left(\frac{1}{2}\right)^{n-1}+2 \\
	&= 2.
\end{align*}



\subsubsection{Common Sequences}

There are many common sequences that you should be aware of (but do not need to have memorized). However, these sequences will appear more and more frequently throughout the course and can make finding closed forms of sequences much easier!

\begin{center}
\begin{tabular}[h]{|c|l|r@{\ }r@{\ }r@{\ }r@{\ }r@{\ }r@{\ }r@{\ }r@{\ }r@{\ }r@{\ }r|}
\hline
$a_n$ & Recurrence Relation & $a_0$ & $a_1$ & $a_2$ &$a_3$&$a_4$&$a_5$&$a_6$&$a_7$&$a_8$&$a_9$&$a_{10}$ \\
\hline
$n$ & $a_n = a_{n-1} + 1$ & $0$ & $1$ & $2$&$3$&$4$&$5$&$6$&$7$&$8$&$9$&$10$\\
$n^2$ & $a_n = a_{n-1} + 2n - 1$ & $0$&$1$&$4$&$9$&$16$&$25$&$36$&$ 49$&$64$&$81$&$100$\\
$n^3$ & $a_n = a_{n-1} + 3n^2-3n+1$ & $0$&$1$&$8$&$27$&$ 64$&$ 126$&$216$&$343$&$512$&$729$&$1000$\\
$2^n$ & $a_n = 2a_{n-1}$ & $1$&$2$&$4$&$8$&$16$&$32$&$64$&$128$&$256$&$512$&$1024$\\
$3^n$ & $a_n = 3a_{n-1}$ & $1$&$3$&$9$&$27$&$81$&$243$&$729$&$2187$&$6561$&$19683$&$59049$\\
$n!$ & $a_n = na_{n-1}$ & $1$&$1$&$2$&$6$&$24$&$120$&$720$&$5040$&$40320$&$362880$&$3628800$\\ 
$F_n$ & $F_n = F_{n-1} + F_{n-2}$ & $0$&$1$&$1$&$2$&$3$&$5$&$8$&$13$&$21$&$34$&$55$\\
$L_n$ & $L_n = L_{n-1} + L_{n-2}$ & $2$&$1$&$3$&$4$&$7$&$11$&$18$&$29$&$47$&$76$&$123$\\
\hline
\end{tabular}
\end{center}




\subsubsection{OEIS}

When doing your homework, or just having fun with sequences, you can use the Online Encyclopedia of Integer Seq	uences (\url{http://oeis.org/}) to discover what sequences represent, how they have different representations.


\subsubsection{Suggested Homework}

Rosen 2.4: 1--4, 9--17, 25--26.






\clearpage
\section{Wednesday, February 9}

\subsection{Rosen 4.1 -- Mathematical Induction}

\textbf{Reading:} Rosen 4.1. LLM 4.2. Ducks 8.2, 8.3

\subsubsection{Standard Induction}

\textbf{The Principal of Mathematical Induction:} Let $(P(n))_{n=0}^\infty$ be a sequence of propositions. To prove $\forall n P(n)$, it suffices to demonstrate the following:

1. $P(0)$ is true.

2. If $P(n)$ is true for some $n \geq 0$, then $P(n+1)$ is true.

\textbf{Thm:} Let $(a_n)_{n=0}^\infty$ be the sequence defined as $a_0 = a$, and for $n \geq 1$ $a_n = a_{n-1} + d$. Then $a_n = dn + a$.

\begin{proof}
Case $n = 0$: $a_0 = a = d(0) + a$.

(Induction Hypothesis) Assume that $a_{n} = dn + a$ for some $n \geq 0$.

Case $n +1$: $a_{n+1} = \underbrace{a_{n} + d = dn+a + d}_{\text{by IH}} = d(n+1) + a$.
\end{proof}

\textbf{Thm:} Let $(b_n)_{n=0}^\infty$ be the sequence defined as $b_0 = a$, and for $n \geq 1$ $b_n =rb_{n-1}$. Then $b_n = ar^n$.

\begin{proof}
Case $n = 0$: $b_0 = a = ar^0$.

(Induction Hypothesis) Assume that $b_{n} = ar^n$ for some $n \geq 0$.

Case $n +1$: $b_{n+1} = \underbrace{rb_{n} = r(ar^n)}_{\text{by IH}} = ar^{n+1}$.
\end{proof}

\textbf{Thm:} Let $(c_n)_{n=0}^\infty$ be the sequence defined as $c_0 = a$, and for $n \geq 1$ $c_n =rc_{n-1}+d$. Then $c_n = ar^n + \left(\frac{r^{n}-1}{r-1}\right)d$.

\begin{proof}
Case $n = 0$: $c_0 = a = a(1) + 0 = ar^0 + \left(\frac{r^{0}-1}{r-1}\right)d$.

(Induction Hypothesis) Assume that $c_{n} = ar^n + \left(\frac{r^{n}-1}{r-1}\right)d$ for some $n \geq 0$.

Case $n + 1$: Consider $c_{n+1}$.

\begin{align*}
	c_{n+1} &= rc_{n}+d \\
	&= r\left(ar^n + \left(\frac{r^{n}-1}{r-1}\right)d\right) + d &\text{(By Induction Hypothesis)}\\
	&= ar^{n+1} + \left(\frac{r^{n}-1}{r-1}\right)rd + d\\
	&= ar^{n+1} + \frac{d}{r-1}\left[(r^n-1)r + (r-1)\right]\\
	&= ar^{n+1} + \frac{d}{r-1}\left[r^{n+1}-r + r - 1\right]\\
	&= ar^{n+1} + \frac{r^{n+1}-1}{r-1}d. \qedhere
\end{align*}
\end{proof}



\textbf{Thm:} Let $k \geq 0$ be an integer and $x \neq 1$. Prove that $\sum_{i=0}^k x^i = \frac{x^{k+1}-1}{x-1}$.

\begin{proof}
Case $k = 0$: $\sum_{i=0}^0 x^i = x^0 = 1 = \frac{x^1-1}{x-1}$.

(Induction Hypothesis) Assume that $\sum_{i=0}^k x^i = \frac{x^{k+1}-1}{x-1}$.

Case $k+1$: 
\begin{align*}
	\sum_{i=0}^{k+1} x^i &= x^{k+1} + \sum_{i=0}^k x_i \\
	&= x^{k+1} + \frac{x^{k+1}-1}{x-1} & (\text{By Induction hypothesis})\\
	&= \frac{x^{k+1}(x-1)}{x-1}+\frac{x^{k+1}-1}{x-1} \\
	&= \frac{x^{k+2}-x^{k+1}+x^{k+1}-1}{x-1}\\
	&= \frac{x^{k+2}-1}{x-1}.
\end{align*}
Therefore $\sum_{i=0}^{k+1}x^i=  \frac{x^{k+2}-1}{x-1}$.
\end{proof}

Many of the following closed forms can be proven using induction:
\begin{center}
\begin{tabular}[h]{|l|l|}
\hline
Sum & Closed Form\\
\hline
$\sum_{i=0}^k 1$ & $k+1$ \\
$\sum_{i=0}^k i$ & $\frac{k(k+1)}{2}$ \\
$\sum_{i=0}^k i^2$ & $\frac{k(k+1)(2k+1)}{6}$ \\
$\sum_{i=0}^k i^3$ & $\frac{k^2(k+1)^2}{4}$ \\
$\sum_{i=0}^k ar^i$ & $\frac{ar^{k+1}-a}{r-1} (r\neq 1)$\\
$\sum_{i=0}^\infty x^i, |x| <1$ & $\frac{1}{1-x}$\\
$\sum_{i=0}^\infty kx^{k-1}, |x| < 1$ &  $\frac{1}{(1-x)^2}$\\
\hline
\end{tabular}
\end{center}



\textbf{Def:} An \emph{angle tile} is a tile consisting of three squares not in a line (can cover positions $(1,1)$, $(1,2)$, and $(2,1)$.

\textbf{Thm:} Let $n \geq 1$ and let $C_n$ be a $2^n\times 2^n$ chessboard with one square missing. $C_n$ can be tiled using angle pieces.

\begin{proof}
Case $n = 1$: All squares of the $2\times 2$ chessboard are corners. Once a corner is missing, the remaining squares form an angle tile.

(Induction Hypothesis) Assume that $C_n$ can be tiled using angle pieces.

Case $n + 1$: The $2^{n+1}\times 2^{n+1}$ chessboard can be split into four ``quadrants'' that are each a $2^n\times 2^n$ chessboard, by cutting the board in half in each direction.
The missing square of $C_{n+1}$ is in exactly one of the quadrants. 
Place an angle tile such that exactly one square of the tile is in each of the quadrants without a missing square.
Now the squares of $C_{n+1}$ that are not covered by the angle tile form $2^n\times 2^n$ chessboards with one missing square. 
Therefore, by the induction hypothesis there exists a tiling of these quadrants using angle tiles, completing a tiling of $C_{n+1}$.
\end{proof}


\subsubsection{A NON Proof!}

\textbf{Thm:} Every horse is of the same color.

\begin{proof}
We will use induction to prove the following proposition: for $n \geq 1$, $P(n)$ is the proposition ``for every collection of $n$ horses, every horse has the same color.''

Case $n= 1$: Consider a collection of 1 horse. This horse has the same color as itself.

(Induction Hypothesis) Assume for some $n \geq 1$, $P(n)$ is true.

Case $n+1$: Let $S$ be a collection of $n+1$ horses. List the horses as $h_1,\dots, h_{n+1}$. The collection $\{h_1,\dots,h_n\}$ is a collection of $n$ horses, and the collection $\{h_2,\dots,h_{n+1}\}$ is a collection of $n$ horses.
By the induction hypothesis, the colors of $h_1,\dots,h_n$ are the same, and the colors of $h_2,\dots,h_{n+1}$ are the same. 
Thus, $h_{n+1}$ has the same color as $h_n$, which is the same color as $h_1,\dots,h_{n-2}$.
\end{proof}

\textbf{What is wrong with that proof?}



\subsubsection{Strong Induction}

\textbf{The Principal of (Strong) Mathematical Induction:} Let $(P(n))_{n=0}^\infty$ be a sequence of propositions. To prove $\forall n P(n)$, it suffices to demonstrate the following:

1. $P(0)$ is true.

2. If $P(m)$ is true for $0 \leq m < n$, then $P(n)$ is true.

\textbf{Thm:} Every natural number $n \in \N$ is either even or odd.

\begin{proof}
Case $n = 0$: $0 = 2\cdot 0$, so $0$ is even.

Case $n = 1$: $1 = 2\cdot 0 + 1$, so $1$ is odd.

Now for some $N \geq 2$, assume that for all natural numbers $n < N$, $n$ is even or odd.

Case $N$: $N - 2$ is either even or odd.
If $N-2$ is even, then there exists an integer $k$ such that $N-2 = 2k$ and $N = 2(k+1)$, so $N$ is even.
If $N-2$ is odd, then there exists an integer $k$ such that $N-2 = 2k+1$ and $N = 2(k+1)+1$, so $N$ is odd.
\end{proof}

\textbf{Thm:} There are $F_{n+1}$ ways to tile the $2 \times n$ chessboard with dominoes.

\begin{proof}
Let $d_n$ be the number of ways to tile the $2 \times n$ chessboard. We will prove ``$d_n = F_{n+1}$'' for all $n \geq 0$.

Case $n = 0$: There is 1 way to tile the $2 \times 0$ chessboard: no dominoes! $d_0 = 1 = F_1$.

Case $n = 1$: There is 1 way to tile the $2 \times 1$ chessboard: one vertical domino! $d_1 = 1 = F_2$.

Now let $N > 1$ and assume that for all $n < N$, $d_n = F_{n+1}$.

Case $N$: Consider a domino tiling, and consider the domino covering the $(1,1)$ position. This tile is either horizontal or vertical.

If the domino is horizontal, then there is another horizontal domino covering the $(2,1)$ position, and these dominoes cover the $(1,1)$, $(1,2)$, $(2,1)$ and $(2,2)$ positions. Since there are $d_{n-2}$ ways to tile the rest of the positions, there are $d_{n-2}$ domino tilings of the $2 \times n$ chessboard with a horizontal domino covering the $(1,1)$ position.

If the domino is vertical, then it also covers the $(2,1)$ position. 
Since there are $d_{n-1}$ ways to tile the rest of the positions, there are $d_{n-1}$ domino tilings of the $2 \times n$ chessboard with a vertical domino covering the $(1,1)$ position.

Therefore, there are $d_{n-2} + d_{n-1}$ ways to tile the $2\times n$ chessboard, so $d_n = d_{n-2} + d_{n-1} = F_{n-1} + F_{n} = F_{n+1}$.
\end{proof}








\subsubsection{Suggested Homework}

Rosen 2.4: 27$^*$, 28$^*$, 29--34, 35$^*$, 36--37, 44.

Rosen 4.1: 



\clearpage
\section{Extra Strong Induction Example}

The \emph{L-shaped Tetris piece} (or \emph{tetromino}, see \href{http://en.wikipedia.org/wiki/Tetromino}{the Wikipedia page}) consists of four squares: three of which are in a line and a fourth attached to one end of that line. See the figure below for all of the arrangements of the L-shaped Tetris piece (or L-piece).

% If you are using this TeX file for your homework, you will want to comment this out!
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominoes-L}
\end{center}



\textbf{Thm:} If $k$ is odd, then the $3 \times 4k$ chessboard \emph{cannot} be tiled using L-pieces.

\begin{proof}
We will use \emph{strong} induction to prove that if $k \geq 1$ is odd, then the $3 \times 4k$ chessboard cannot be tiled using L-pieces. 
We first make a claim about any tiling:

\textbf{Claim:} Any tiling of the $3 \times 4k$ chessboard using L-pieces must use an L-piece covering all three rows on the left-most and right-most edges.

\begin{proof}[Proof of Claim.]
Suppose there is a tiling that does not use an L-piece on an edge of length three (without loss of generality, we use the left edge).
The top-left corner must be covered by some L-piece. 
Consider the possible placements, by how many squares of the L-piece are on the left edge.

Case 1: Exactly one square of the L-piece is on the left edge. In this case, the L-piece covers the three squares in the second column, leaving two squares on the left edge that cannot be covered by an L-piece!

\begin{center}
\begin{tabular}[h]{c@{\qquad}c}
\includegraphics[height=0.5in]{figures/tetrominos-L-onesquareleft} & 
\includegraphics[height=0.5in]{figures/tetrominos-L-twosquaresleft} 
\\
Case 1. & Case 2.
\end{tabular}
\end{center}

Case 2: Exactly two squares of the L-piece are on the left edge.
There are two ways for the L-piece to cover two squares on the left edge.
However, since the bottom-left corner must be covered by an L-piece, the top-left corner piece cannot cover three squares in the middle row.
So, the top-left corner is covered by an L-piece that has three squares on the top edge.
Finally, the bottom-left corner must be covered by an L-piece and the only way this can be placed is with three squares on the bottom edge.
This leaves the square in the $(2,2)$ position surrounded by squares already covered, so no L-piece can cover this square!
\end{proof}

Case $k = 1$:
By the claim above, any tiling of the $3 \times 4$ chessboard must include an L-piece covering three squares of the left edge.
Also, the tiling must include an L-piece covering three squares of the right edge.
These L-pieces are either arranged such that they cover adjacent squares, or do not.
When they cover adjacent squares, the four squares not covered by these two pieces form a $2 \times 2$ chessboard, which cannot fit an L-piece.
When they do not cover adjacent squares, the four squares not covered by these two pieces form a $3 \times 2$ chessboard with two opposite corners missing, which cannot fit an L-piece.
Therefore, there is no tiling of the $3 \times 4$ chessboard.

\begin{center}
\begin{tabular}[h]{c@{\qquad}c}
\includegraphics[height=0.5in]{figures/tetrominos-L-3x4-adjacent} & 
\includegraphics[height=0.5in]{figures/tetrominos-L-3x4-nonadjacent} \\
Covering Adjacent Squares & Not Covering Adjacent Squares
\end{tabular}
\end{center}

(Induction Hypothesis) Suppose that the statement is true for all odd values of $k$ with $k < K$ for some $K > 1$.

Case $K$: Suppose that we have a tiling of the $3\times 4K$ chessboard using L-pieces.
If an L-piece is placed vertically so it covers all three rows of the chessboard, then the tiling of the $3 \times 4K$ chessboard partitions into tilings of a $3 \times m$ chessboard and a $3 \times (4K-m)$ chessboard, for some $m$.
Since L-pieces cover 4 squares each, these tilings cover a multiple of 4 squares, so $3m$ is a multiple of 4 and therefore $m = 4n$ for some integer $n$.
Finally, this implies that the $3\times 4n$ chessboard and the $3 \times 4(K-n)$ chessboard are tiled using L-pieces.
Since $K$ is odd, one of $n$ or $K-n$ is odd. 
Suppose without loss of generality, $n$ is odd,  but by the induction hypothesis the $3 \times 4n$ chessboard cannot be tiled using L-pieces.

Therefore, no L-piece is placed vertically to cover all three rows of the chessboard, except for the left-most edge and the right-most edge.

We now investigate our tiling, starting on the left edge.
As claimed, all three squares on this edge are covered by the same L-piece.
Since the square in the (2,2) position must be covered by an L-piece, the only arrangement of an L-piece covering this square without immediately making a tiling impossible is to have that L-piece cover the other open position in the second column.
Therefore, we definitely have a tiling that looks like the below (or its vertical mirror).
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case0.pdf}
\end{center}
We now consider how the (3,3) position is covered. Note that if it is covered by an L-piece without also covering the (2,3) position, the (2,3) position cannot be covered by an L-piece.
Thus, both the (3,3) and (3,2) positions are covered by the same L-piece.
There are two options to cover these two by a single L-piece, and they each ``force'' another L-piece, as in the pictures below.
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case2}

\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case2-alt}
\end{center}
Observe that both options cover the same set of squares, so we can take either option.
We now consider how the (1,5) position is covered, and there is exactly one option.
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case3}
\end{center}
Given this set of covered squares, we can now consider the (3,7) position.
This cannot be covered by an L-piece that covers all three rows (as below) because that would create a vertical L-piece, which we demonstrated does not exist.
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case4-bad}

Bad example!
\end{center}
Therefore, the L-piece covering the (3,7) position covers three squares on the bottom edge.
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case4}
\end{center}
This forces the (2,8) position to be covered by an L-piece that has three squares on the top edge.
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case5}
\end{center}
Now consider how the (2,10) position is covered by an L-piece.
If it is covered by an L-piece that does not have three squares on the bottom row, observe that the tiling cannot continue in one or two more placements of L-pieces [I know this is sketchy, but its' getting late].
Thus, the (2,10) position is covered by an L-piece covering three squares on the bottom row, as in the picture below.
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case6}
\end{center}
Now, see the two thick black lines. If we remove all of the L-pieces between them and take the two L-pieces on the left, flip them vertically, they fit nicely with the rest of the tiling to the right.
See the picture below.
\begin{center}
\includegraphics[height=0.5in]{figures/tetrominos-L-oddtiling-case6-conclusion}
\end{center}
Therefore, our tiling of the $3 \times 4K$ chessboard gives us a way to tile the $3 \times 4(K-2)$ chessboard. However, our induction hypothesis claims this is impossible, so we have a contradiction!
\end{proof}






\end{document} 