Cleanup
This commit is contained in:
parent
8e131d3c31
commit
46e463d420
@ -8,7 +8,6 @@
|
|||||||
\usepackage{amsmath}
|
\usepackage{amsmath}
|
||||||
\usepackage{amssymb}
|
\usepackage{amssymb}
|
||||||
\usepackage{multicol}
|
\usepackage{multicol}
|
||||||
\usepackage{subfiles}
|
|
||||||
|
|
||||||
|
|
||||||
\begin{document}
|
\begin{document}
|
||||||
@ -19,14 +18,10 @@
|
|||||||
{Intro to Cryptography}
|
{Intro to Cryptography}
|
||||||
{Prepared by Mark on \today{}}
|
{Prepared by Mark on \today{}}
|
||||||
|
|
||||||
\vspace{3ex}
|
\input{parts/part 1}
|
||||||
|
\input{parts/part 2}
|
||||||
|
\input{parts/part 3}
|
||||||
|
|
||||||
\subfile{parts/part 1}
|
\input{parts/challenge}
|
||||||
|
|
||||||
\subfile{parts/part 2}
|
|
||||||
|
|
||||||
\subfile{parts/part 3}
|
|
||||||
|
|
||||||
\subfile{parts/challenge}
|
|
||||||
|
|
||||||
\end{document}
|
\end{document}
|
||||||
|
@ -1,7 +1,3 @@
|
|||||||
\documentclass[../main.tex]{subfiles}
|
|
||||||
|
|
||||||
\begin{document}
|
|
||||||
|
|
||||||
\section{Challenge Problems}
|
\section{Challenge Problems}
|
||||||
|
|
||||||
|
|
||||||
@ -72,6 +68,7 @@
|
|||||||
\end{solution}
|
\end{solution}
|
||||||
|
|
||||||
\vfill
|
\vfill
|
||||||
|
\pagebreak
|
||||||
|
|
||||||
\problem{Chinese Remainder Theorem}
|
\problem{Chinese Remainder Theorem}
|
||||||
There are certain things whose number is unknown. If we count them by threes, we have two left over; by fives, we have three left over; and by sevens, two are left over. How many things are there?
|
There are certain things whose number is unknown. If we count them by threes, we have two left over; by fives, we have three left over; and by sevens, two are left over. How many things are there?
|
||||||
@ -143,4 +140,3 @@
|
|||||||
|
|
||||||
[Note on \ref{eua_runtime}] This proof can be used to show that the Euclidean algorithm finishes in logarithmic time, and it is the first practical application of the Fibonacci numbers. If you have finished all challenge problems, finish the proof: show that the Euclidean runs in $O(\log{n})$
|
[Note on \ref{eua_runtime}] This proof can be used to show that the Euclidean algorithm finishes in logarithmic time, and it is the first practical application of the Fibonacci numbers. If you have finished all challenge problems, finish the proof: show that the Euclidean runs in $O(\log{n})$
|
||||||
\pagebreak
|
\pagebreak
|
||||||
\end{document}
|
|
||||||
|
@ -1,8 +1,3 @@
|
|||||||
\documentclass[../main.tex]{subfiles}
|
|
||||||
|
|
||||||
\begin{document}
|
|
||||||
\section{The Euclidean Algorithm}
|
|
||||||
|
|
||||||
\definition{}
|
\definition{}
|
||||||
The \textit{greatest common divisor} of $a$ and $b$ is the greatest integer that divides both $a$ and $b$. \\
|
The \textit{greatest common divisor} of $a$ and $b$ is the greatest integer that divides both $a$ and $b$. \\
|
||||||
We denote this number with $\gcd(a, b)$. For example, $\gcd(45, 60) = 15$.
|
We denote this number with $\gcd(a, b)$. For example, $\gcd(45, 60) = 15$.
|
||||||
@ -25,10 +20,9 @@
|
|||||||
|
|
||||||
\vfill
|
\vfill
|
||||||
|
|
||||||
\problem{}<euclid_algorithm>
|
\problem{The Euclidean Algorithm}<euclid_algorithm>
|
||||||
Using the theorems above, detail an algorithm for finding $\gcd(a, b)$.\\
|
Using the theorems above, detail an algorithm for finding $\gcd(a, b)$.\\
|
||||||
Then, compute $\gcd(1610, 207)$ by hand. \\
|
Then, compute $\gcd(1610, 207)$ by hand. \\
|
||||||
Have an instructor check your work before moving on.
|
|
||||||
|
|
||||||
\begin{solution}
|
\begin{solution}
|
||||||
Using \ref{gcd_abc} and the division algorthm,
|
Using \ref{gcd_abc} and the division algorthm,
|
||||||
@ -36,20 +30,20 @@
|
|||||||
% Minipage prevents column breaks inside body
|
% Minipage prevents column breaks inside body
|
||||||
\begin{multicols}{2}
|
\begin{multicols}{2}
|
||||||
\begin{minipage}{\columnwidth}
|
\begin{minipage}{\columnwidth}
|
||||||
$\gcd(1610, 207)$ \\
|
$\gcd(1610, 207)$ \par
|
||||||
$= \gcd(207, 161)$ \\
|
$= \gcd(207, 161)$ \par
|
||||||
$= \gcd(161, 46)$ \\
|
$= \gcd(161, 46)$ \par
|
||||||
$= \gcd(46, 23)$ \\
|
$= \gcd(46, 23)$ \par
|
||||||
$= \gcd(23, 0) = 23$ \\
|
$= \gcd(23, 0) = 23$ \par
|
||||||
\end{minipage}
|
\end{minipage}
|
||||||
|
|
||||||
\columnbreak
|
\columnbreak
|
||||||
|
|
||||||
\begin{minipage}{\columnwidth}
|
\begin{minipage}{\columnwidth}
|
||||||
$1610 = 207 \times 7 + 161$ \\
|
$1610 = 207 \times 7 + 161$ \par
|
||||||
$207 = 161 \times 1 + 46$ \\
|
$207 = 161 \times 1 + 46$ \par
|
||||||
$161 = 46 \times 3 + 23$ \\
|
$161 = 46 \times 3 + 23$ \par
|
||||||
$46 = 23 \times 2 + 0$ \\
|
$46 = 23 \times 2 + 0$ \par
|
||||||
\end{minipage}
|
\end{minipage}
|
||||||
\end{multicols}
|
\end{multicols}
|
||||||
\end{solution}
|
\end{solution}
|
||||||
@ -73,8 +67,8 @@
|
|||||||
\vfill
|
\vfill
|
||||||
|
|
||||||
\problempart{Conquer}<extend_e_algorithm>
|
\problempart{Conquer}<extend_e_algorithm>
|
||||||
Using the output of your algorithm\footnotemark{} from \ref{euclid_algorithm},
|
Using the output of the Euclidean algorithm,
|
||||||
\footnotetext{Your solution to \ref{euclid_algorithm} is called the \textit{Euclidean Algorithm}}
|
|
||||||
\begin{itemize}
|
\begin{itemize}
|
||||||
\item[-] find a pair $(u, v)$ that satisfies $20u + 14v = \gcd(20, 14)$
|
\item[-] find a pair $(u, v)$ that satisfies $20u + 14v = \gcd(20, 14)$
|
||||||
\item[-] find a pair $(u, v)$ that satisfies $541u + 34v = \gcd(541, 34)$ \\
|
\item[-] find a pair $(u, v)$ that satisfies $541u + 34v = \gcd(541, 34)$ \\
|
||||||
@ -90,18 +84,18 @@
|
|||||||
|
|
||||||
\begin{multicols}{2}
|
\begin{multicols}{2}
|
||||||
\begin{minipage}{\columnwidth}
|
\begin{minipage}{\columnwidth}
|
||||||
\textit{Euclidean Algorithm:} \\
|
\textit{Euclidean Algorithm:} \par
|
||||||
$20 = 14 \times 1 + 6$ \\
|
$20 = 14 \times 1 + 6$ \par
|
||||||
$14 = 6 \times 2 + 2$ \\
|
$14 = 6 \times 2 + 2$ \par
|
||||||
$6 = 2 \times 3 + 0$ \\
|
$6 = 2 \times 3 + 0$ \par
|
||||||
\end{minipage}
|
\end{minipage}
|
||||||
|
|
||||||
\columnbreak
|
\columnbreak
|
||||||
|
|
||||||
\begin{minipage}{\columnwidth}
|
\begin{minipage}{\columnwidth}
|
||||||
\textit{Rearranged:} \\
|
\textit{Rearranged:} \par
|
||||||
$6 = 20 - 14 \times 1$ \\
|
$6 = 20 - 14 \times 1$ \par
|
||||||
$2 = 14 - 6 \times 2 = \gcd(20, 14)$ \\
|
$2 = 14 - 6 \times 2 = \gcd(20, 14)$ \par
|
||||||
\end{minipage}
|
\end{minipage}
|
||||||
\end{multicols}
|
\end{multicols}
|
||||||
|
|
||||||
@ -124,6 +118,8 @@
|
|||||||
(See Part A)
|
(See Part A)
|
||||||
|
|
||||||
\end{solution}
|
\end{solution}
|
||||||
|
|
||||||
|
|
||||||
\vfill
|
\vfill
|
||||||
\pagebreak
|
\pagebreak
|
||||||
\end{document}
|
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
\documentclass[../main.tex]{subfiles}
|
|
||||||
|
|
||||||
\begin{document}
|
|
||||||
\section{Modular Arithmetic}
|
\section{Modular Arithmetic}
|
||||||
|
|
||||||
\definition{}
|
\definition{}
|
||||||
@ -65,4 +62,4 @@
|
|||||||
|
|
||||||
\vfill
|
\vfill
|
||||||
\pagebreak
|
\pagebreak
|
||||||
\end{document}
|
|
||||||
|
@ -1,6 +1,3 @@
|
|||||||
\documentclass[../main.tex]{subfiles}
|
|
||||||
|
|
||||||
\begin{document}
|
|
||||||
\section{Symmetric Cryptosystems}
|
\section{Symmetric Cryptosystems}
|
||||||
|
|
||||||
\definition{}
|
\definition{}
|
||||||
@ -30,7 +27,7 @@
|
|||||||
|
|
||||||
\vspace{2ex}
|
\vspace{2ex}
|
||||||
|
|
||||||
Finally, you will notice that the encryption schemes that follow can only take a limited range of inputs. Indeed, even the cyphers in use today have a limited input size. A simple (though possible insecure) way to overcome this limitation is to split the message into ``blocks'' of a desired size, and encrypt each independently.
|
Finally, you will notice that the encryption schemes that follow can only take a limited range of inputs. Indeed, even the cyphers in use today have a limited input size. A simple (though possibly insecure) way to overcome this limitation is to split the message into blocks of a desired size, encrypting each independently.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -166,4 +163,3 @@
|
|||||||
|
|
||||||
\vfill
|
\vfill
|
||||||
\pagebreak
|
\pagebreak
|
||||||
\end{document}
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user