|
| 1 | +\documentclass{article} |
| 2 | +\usepackage{amsmath,amssymb,amsthm,latexsym,paralist} |
| 3 | +\usepackage{fancyhdr,hyperref} |
| 4 | + |
| 5 | +\theoremstyle{definition} |
| 6 | +\newtheorem{problem}{Problem} |
| 7 | +\newtheorem*{solution}{Solution} |
| 8 | +\newtheorem*{resources}{Resources} |
| 9 | + |
| 10 | +\newcommand{\name}[2]{\noindent\textbf{Name: #1}\hfill \textbf{UIN: #2} |
| 11 | + \newcommand{\myName}{#1} |
| 12 | + \newcommand{\myUIN}{#2} |
| 13 | +} |
| 14 | +\newcommand{\honor}{\noindent On my honor, as an Aggie, I have neither |
| 15 | + given nor received any unauthorized aid on any portion of the |
| 16 | + academic work included in this assignment. Furthermore, I have |
| 17 | + disclosed all resources (people, books, web sites, etc.) that have |
| 18 | + been used to prepare this homework. \\[2ex] |
| 19 | + \textbf{Electronic signature:} \underline{ \textbf{Blake Dejohn} } } % type your full name here |
| 20 | + |
| 21 | +\newcommand{\checklist}{\noindent\textbf{Checklist:} |
| 22 | +\begin{compactitem}[$\Box$] |
| 23 | +\item [\checkmark] Did you type in your name and UIN? |
| 24 | +\item [\checkmark] Did you disclose all resources that you have used? \\ |
| 25 | +(This includes all people, books, websites, etc.\ that you have consulted.) |
| 26 | +\item [\checkmark] Did you sign that you followed the Aggie Honor Code? |
| 27 | +\item [\checkmark] Did you solve all problems? |
| 28 | +\item [\checkmark] Did you submit both the .tex and .pdf files of your homework to each correct link on Canvas? |
| 29 | +\end{compactitem} |
| 30 | +} |
| 31 | + |
| 32 | +\newcommand{\problemset}[1]{\begin{center}\textbf{Problem Set #1}\end{center}} |
| 33 | +\newcommand{\duedate}[1]{\begin{quote}\textbf{Due dates:} Electronic |
| 34 | + submission of \textsl{yourLastName-yourFirstName-hw1.tex} and |
| 35 | + \textsl{yourLastName-yourFirstName-hw1.pdf} files of this homework is due on |
| 36 | + \textbf{#1} on \texttt{https://canvas.tamu.edu}. You will see two separate links |
| 37 | + to turn in the .tex file and the .pdf file separately. Please do not archive or compress the files. |
| 38 | + \textbf{If any of the two files are missing, you will receive zero points for this homework.}\end{quote} } |
| 39 | + |
| 40 | +\newcommand{\N}{\mathbf{N}} |
| 41 | +\newcommand{\R}{\mathbf{R}} |
| 42 | +\newcommand{\Z}{\mathbf{Z}} |
| 43 | + |
| 44 | +\fancyhead[L]{\myName} |
| 45 | +\fancyhead[R]{\myUIN} |
| 46 | +\pagestyle{fancy} |
| 47 | + |
| 48 | +\begin{document} |
| 49 | +\begin{center} |
| 50 | +{\large |
| 51 | +CSCE 222 Discrete Structures for Computing -- Fall 2022\\[.5ex] |
| 52 | +Hyunyoung Lee\\} |
| 53 | +\end{center} |
| 54 | +\problemset{1} |
| 55 | +\duedate{Thursday, 9/8/2022 11:59 p.m.} |
| 56 | +\name{Blake Dejohn}{531002472} % type your name and UIN here |
| 57 | +\begin{resources} |
| 58 | +\hspace{1cm} |
| 59 | +\subsection*{Resources Overall (used for the whole document)} |
| 60 | +Lecture Notes\\ |
| 61 | +"LaTeX Typesetting System" - (found in module view in Canvas)\\ |
| 62 | +List of logic symbols - \url{https://en.wikipedia.org/wiki/List_of_logic_symbols}\\ |
| 63 | +"How to make clickable links in LaTex" - \url{https://latex-tutorial.com/tutorials/hyperlinks/} |
| 64 | +\\ |
| 65 | +How to work with a checklist in LaTeX - \url{https://tex.stackexchange.com/questions/321048/checklist-in-beamer-using-enumitem-package} |
| 66 | +\subsection*{Resources for Problem \#3} |
| 67 | +"Rational Numbers" - \url{https://www.mathsisfun.com/rational-numbers.html} |
| 68 | +\subsection*{Resources for Problem \#6} |
| 69 | +"Knights and Knaves Puzzles" (video and lecture notes) - (found in module 2.1)\\ |
| 70 | +"truth-table.pdf" - (found in Homework 1 module) |
| 71 | +\subsection*{Resources for Problem \#7} |
| 72 | +"truth-table.pdf" - (found in Homework 1 module) |
| 73 | +\subsection*{Resources for Problem \#8} |
| 74 | +"Problem Solving Exercise 1" - (found in module 2.1) |
| 75 | +%(All people, books, articles, web pages, etc. that |
| 76 | + %have been consulted when producing your answers to this homework) |
| 77 | +\end{resources} |
| 78 | +\honor |
| 79 | + |
| 80 | +\bigskip |
| 81 | + |
| 82 | +\noindent |
| 83 | +Total $100 + 7$ (bonus) points. |
| 84 | + |
| 85 | +\bigskip |
| 86 | + |
| 87 | +\noindent |
| 88 | +The intended formatting is that this first page is a cover page and each |
| 89 | +problem solved on a new page. You only need to fill in your solution between |
| 90 | +the \verb|\begin{solution}| and \verb|\end{solution}| environment. |
| 91 | +Please do not change this overall formatting. |
| 92 | + |
| 93 | +\vfill |
| 94 | +\checklist |
| 95 | + |
| 96 | +\newpage |
| 97 | +\begin{problem} ($10+10=20$ points) Section 1.1, Exercise 1.3. |
| 98 | +For (b), give the knight's graph in a text format by giving all |
| 99 | +edges in the graph such that the knight's move from vertex $v_i$ to |
| 100 | +vertex $v_{i+1}$ is given as $(v_i, v_{i+1})$. Once you have all of the |
| 101 | +edges written, you can also give the path in the form of |
| 102 | +$v_i - v_{i+1} - v_{i+2} - \ldots$ |
| 103 | + |
| 104 | +Use the common convention of expressing the columns and rows of |
| 105 | +a chessboard as a, b, and c, and 1, 2, and 3, respectively. |
| 106 | +\end{problem} |
| 107 | +\begin{solution} |
| 108 | +\hspace{1cm} |
| 109 | +\section*{Part a.} |
| 110 | +A Knight's Tour can not be completed on a 3x3 chess board because of the fact that the center square of said board can neither have a Knight's move coming from it nor to it. |
| 111 | +\\ |
| 112 | +\\ |
| 113 | +In other words, no Knight's move can be made from this square and no other square from this 3x3 chess board can have a Knight's move that goes to this square. This makes it so |
| 114 | +a completed Knight's Tour is impossible because of the inability to travel from or to this square. |
| 115 | + |
| 116 | +\section*{Part b.} |
| 117 | +\subsection*{Edges} |
| 118 | +(a3,c2), (a3,b1), (a2,c3), (a2,c1), (a1,b3), (a1,c2), (b3,c1), (b1,c3) |
| 119 | +\subsection*{Path} |
| 120 | +a3 - c2 - a1 - b3 - c1 - a2 - c3 - b1 - a3\\ |
| 121 | +(last move (b1 - a3) is reduntant since it moves back to the start, but I wanted to include all the edges possible in case that was needed) |
| 122 | +\subsection*{Insights} |
| 123 | +Some noteworthy things that are more readily shown with this graph representation is that the square b2 is absent (which proves a Knight's Tour can not be completed with a 3x3 board) and that at least one edge is left out for any given path if the player decides not to go back to where they started. |
| 124 | +\end{solution} |
| 125 | + |
| 126 | +\newpage |
| 127 | +\begin{problem} (2 points $\times$ 5 subproblems = 10 points) Section 2.1, Exercise 2.1 |
| 128 | +\end{problem} |
| 129 | +\begin{solution} |
| 130 | +\hspace{1cm} |
| 131 | +\\ |
| 132 | +\\ |
| 133 | +Parts (a), (b), (c), and (d) are all mathematical statments. |
| 134 | +\subsection*{Justification} |
| 135 | +According to Section 2.1, "a statement is a sentence that is either true or false". Therefore, I can conclude that any sentence that holds either a true or false value is a statement. Also, if this statement includes properties of mathematics, then I can reasonably state that this sentence is a mathematical statement. Given this line of reasoning, I say that parts (a), (b), (c), and (d) are all mathematical statements because of the fact that they hold either true or false values while part (e) is not a mathematical statment since this sentence needs more context before it can be assigned a true or false value. |
| 136 | +\end{solution} |
| 137 | + |
| 138 | +\newpage |
| 139 | +\begin{problem} (3 points $\times$ 5 subproblems = 15 points) Section 2.1, Exercise 2.3 |
| 140 | +\end{problem} |
| 141 | +\begin{solution} |
| 142 | +\hspace{1cm} |
| 143 | +\subsection*{Part a.} |
| 144 | +\textbf{True} |
| 145 | +\\ |
| 146 | +\\ |
| 147 | +Using long division and following its rules ( $9\overline{)1}$ ), we can see that 9 divides into 10 once and leaves a remainder of 1 each time. This creates a repeating outcome that results in the answer being $0.\overline{1}$. |
| 148 | +\subsection*{Part b.} |
| 149 | +\textbf{False} |
| 150 | +\\ |
| 151 | +\\ |
| 152 | +A rational number is a number that can be represented as a fraction of two integers. Since $12/99 = 0.\overline{12}$, this shows that the real number $0.\overline{12}$ can be represented as a fraction of two integers and is therefore a rational number. |
| 153 | +\subsection*{Part c.} |
| 154 | +\textbf{False} |
| 155 | +\\ |
| 156 | +\\ |
| 157 | +You can perfectly divide $11111111$ by $1111$ to get $10001$. This shows that the greatest common divisior between these two numbers is actually $1111$ since it can both divide $11111111$ and itself without leaving any remainders. |
| 158 | +\subsection*{Part d.} |
| 159 | +\textbf{True} |
| 160 | +\\ |
| 161 | +\\ |
| 162 | +Given the axiom that two negative numbers multiplied together create a positive product, the two negative ones are guaranteed to make a positive product. Next, with the sign out of the way, we can treat the ones like regular, positive ones which multiply together to get another positive one. |
| 163 | +\subsection*{Part e.} |
| 164 | +\textbf{True} |
| 165 | +\\ |
| 166 | +\\ |
| 167 | +An infinite set is one that has no end. Because of how new positive integers can be found (using the rules of the base 10 number system), there is seemingly no end to the set of all positive numbers which therefore makes it an infinite set. |
| 168 | +\end{solution} |
| 169 | + |
| 170 | +\newpage |
| 171 | +\begin{problem} (3 points $\times$ 2 subproblems = 6 points) Section 2.2, Exercise 2.7 (a) and (b) |
| 172 | +\end{problem} |
| 173 | +\begin{solution} |
| 174 | +\hspace{1cm} |
| 175 | +\section*{Part a.} |
| 176 | +Albert cooks pasta and Emmy is not happy. |
| 177 | +\section*{Part b.} |
| 178 | +If Albert cooks pasta, then Albert and Emmy are happy. |
| 179 | +\end{solution} |
| 180 | + |
| 181 | +\newpage |
| 182 | +\begin{problem} (3 points $\times$ 2 subproblems = 6 points) Section 2.2, Exercise 2.8 (a) and (d) |
| 183 | +\end{problem} |
| 184 | +\begin{solution} |
| 185 | +\hspace{1cm} |
| 186 | +\section*{Part a.} |
| 187 | +$(\textit{C} \rightarrow \neg \textit{S})$ |
| 188 | +\section*{Part d.} |
| 189 | +$(\textit{S} \leftrightarrow \neg \textit{C})$ |
| 190 | +\end{solution} |
| 191 | + |
| 192 | +\newpage |
| 193 | +\begin{problem} (15 points) Section 2.2, Exercise 2.18. |
| 194 | +Use a truth table to show your reasoning. |
| 195 | + |
| 196 | +Example \LaTeX\ source for how to draw a truth table is shown |
| 197 | +in the truth-table.tex and truth-table.pdf files. |
| 198 | +\end{problem} |
| 199 | +\begin{solution} |
| 200 | +\hspace{1cm} |
| 201 | +\section*{Formalization} |
| 202 | +A = "A is a knight"\\ |
| 203 | +B = "B is a knight"\\ |
| 204 | +A's statement = "I am a knave or B is a knight"\\ |
| 205 | +\begin{displaymath} |
| 206 | +\begin{array}{|c c| |c|c|} |
| 207 | +A & B & \neg A \lor B & A \leftrightarrow \neg A \lor B \\ |
| 208 | +\hline |
| 209 | +T & T & T & T\\ |
| 210 | +T & F & F & F\\ |
| 211 | +F & T & T & F\\ |
| 212 | +F & F & T & F\\ |
| 213 | +\end{array} |
| 214 | +\end{displaymath} |
| 215 | +\section*{Conclusion} |
| 216 | +Both A and B are Knights. This is because this is the only case where the logical statement $A \leftrightarrow \neg A \lor B$ outputs a true value. This is important because this logical statement determines if A's statement was false (which means that A is a Knave and the logical statement will output a true value) or if A's statement was true (which means that A is a Knight, which once again, means the logical statement will ouput a true value). Since this logical statement outputted false whenever A or B was assigned to be a Knave (or when they were both knaves), it can be reasoned that they both must be Knights. |
| 217 | +\end{solution} |
| 218 | + |
| 219 | +\newpage |
| 220 | +\begin{problem} (15 points) Section 2.3, Exercise 2.25. |
| 221 | +Use a truth table. |
| 222 | +\end{problem} |
| 223 | +\begin{solution} |
| 224 | +\hspace{1cm} |
| 225 | +\subsection*{Proof for $(A \rightarrow B) \land (B \rightarrow A) \equiv A \leftrightarrow B$} |
| 226 | +\hspace{1cm} |
| 227 | +\begin{displaymath} |
| 228 | +\begin{array}{|c c| c |c| |c| c|} |
| 229 | +A & B & A \rightarrow B & B \rightarrow A & A \rightarrow B \land B \rightarrow A & A \leftrightarrow B\\ |
| 230 | +\hline |
| 231 | +T & T & T & T & T & T\\ |
| 232 | +T & F & F & T & F & F\\ |
| 233 | +F & T & T & F & F & F\\ |
| 234 | +F & F & T & T & T & T\\ |
| 235 | +\end{array} |
| 236 | +\end{displaymath} |
| 237 | +\subsection*{Conclusion} |
| 238 | +As can be seen from the truth table, for every possible combination of truth values between A and B, the logical statements $(A \rightarrow B) \land (B \rightarrow A)$ and $A \leftrightarrow B$ output the same truth values. This means that they are logically equivalent since they are guaranteed to ouput the same value, no matter the starting values of their inputs. |
| 239 | +\end{solution} |
| 240 | + |
| 241 | +\newpage |
| 242 | +\begin{problem} (20 points) Section 2.3, Exercise 2.26. |
| 243 | +Your answer should consist of a series of logical equivalences |
| 244 | +you learned in the text, and the final step must resolve to $T$. |
| 245 | +Do not use a truth table. Study the proofs of Proposition 2.8 (b) and (c) |
| 246 | +for the expected style of your answer. Watching the video ``Problem |
| 247 | +Solving Exercise 1" in Module \textbf{2.1} will also be helpful. |
| 248 | + |
| 249 | +Example \LaTeX\ source for how to align the steps nicely is shown |
| 250 | +in the truth-table.tex and truth-table.pdf files. |
| 251 | +\end{problem} |
| 252 | +\begin{solution} |
| 253 | +\hspace{1cm} |
| 254 | +\section*{Proof that $(A \land (A \rightarrow B)) \rightarrow B$ is a tautology} |
| 255 | +\begin{align} |
| 256 | +(A \land (A \rightarrow B)) \rightarrow B &\equiv (A \land (\neg A \lor B)) \rightarrow B \quad \quad \mbox{by } P \rightarrow Q \equiv \neg P \lor Q\\ |
| 257 | +&\equiv (A \land \neg A) \lor (A \land B) \rightarrow B \quad \quad \mbox{by distributive law}\\ |
| 258 | +&\equiv F \lor (A \land B) \rightarrow B \quad \quad \mbox{since } A \land \neg A \equiv F\\ |
| 259 | +&\equiv (A \land B) \rightarrow B \quad \quad \mbox{since } F \lor P \equiv P\\ |
| 260 | +&\equiv \neg (A \land B) \lor B \quad \quad \mbox{by } P \rightarrow Q \equiv \neg P \lor Q\\ |
| 261 | +&\equiv \neg A \lor \neg B \lor B \quad \quad \mbox{by distributive law}\\ |
| 262 | +&\equiv \neg A \lor (\neg B \lor B) \quad \quad \mbox{by associative law of } \lor\\ |
| 263 | +&\equiv \neg A \lor T \quad \quad \mbox{since } \neg B \lor B \equiv T\\ |
| 264 | +&\equiv T \quad \quad \mbox{since } T \mbox{ dominates } \lor |
| 265 | +\end{align} |
| 266 | +\end{solution} |
| 267 | +\end{document} |
0 commit comments