diff --git a/AR/.gitignore b/AR/.gitignore new file mode 100644 index 0000000..a8b46c8 --- /dev/null +++ b/AR/.gitignore @@ -0,0 +1,12 @@ +*.aux +*.log +*.out +*.pdf +*.gz +~$*.pptx +*.pyg + +.vscode +*.pygstyle +*.pygtex +.DS_Store diff --git a/AR/01_communication/01_communication.tex b/AR/01_communication/01_communication.tex new file mode 100644 index 0000000..c15a24a --- /dev/null +++ b/AR/01_communication/01_communication.tex @@ -0,0 +1,66 @@ +% Source: CPTR 280 Computer Organization and Assembly Language Fall 2020 +% File: "01 Communication (key).pdf" +% Author: James Foster, pogil@jgfoster.net + +% comment out for student version +% \ifdefined\Student\relax\else\def\Teacher{}\fi + +\documentclass[12pt]{article} + +\title{Activity 1: Communication: Codes and Combinations} +\author{James Foster} +\newcommand{\activityeditor}{James Foster} +\newcommand{\activitysource}{\url{pogil@jgfoster.net}} +\date{Fall 2020} + +\input{../../cspogil.sty} +\usepackage{graphicx} +\usepackage{tabularx} + +\begin{document} + + \begin{center} + \maketitle + \rolenames + \end{center} + + \keyquestions{ + \item Model 1, Question \#5 + \item Model 3, Question \#12 + \item Model 4, Question \#19 + \item Model 5, Question \#25 + } + + \newpage + \maketitle + + We communicate both data and instructions to computers. This activity will explore how we encode information and what constraints the media used places on the information conveyed. + + \guides{ + \item Calculate the number of values that can be encoded in a number of bits; and, + \item Identify ways to increase the information encoded in a number of bits. + }{ + \item Use a translation table to encode and decode Morse Code and Braille (information processing). + }{ + No additional notes + }{ + \item \href{https://dahliasagucio.files.wordpress.com/2013/10/models-of-communication-main-frame.jpg}{Models of Communication} + \item ``\href{https://www.flickr.com/photos/52358513@N02/5059980339}{Running Antelope Pictographs 002}'' + by \href{https://www.flickr.com/photos/52358513@N02/}{Peter Albrecht} is licensed under \href{https://creativecommons.org/licenses/by-nc-sa/2.0/?ref=ccsearch&atype=rich}{CC BY-NC-SA 2.0} + \item ``\href{https://www.flickr.com/photos/31218363@N05/40318380754}{ABC (27/52) EXPLORE}'' by \href{https://www.flickr.com/photos/31218363@N05/}{Mr B's Photography} is licensed under \href{https://creativecommons.org/licenses/by/2.0/?ref=ccsearch&atype=rich}{CC BY 2.0} + \item ``\href{https://commons.wikimedia.org/wiki/File:Morse_code_tree3.png}{Morse code tree3.png}'' by \href{https://en.wikipedia.org/wiki/User:Aris00}{Aris00} is licensed under \href{https://creativecommons.org/licenses/by-sa/3.0/}{CC BY-SA 3.0} + \item \href{https://i.pinimg.com/474x/57/01/03/5701033741e6ed52efaa5da28a675b3f--deaf-tattoo-braille-tattoo.jpg}{Braille Alphabet Chart} + \item ``\href{https://www.flickr.com/photos/44124372363@N01/17495568490}{Where's The Any Key?}'' by \href{https://www.flickr.com/photos/44124372363@N01/}{swanksalot} is licensed under \href{https://creativecommons.org/licenses/by-nc-sa/2.0/?ref=ccsearch&atype=rich}{CC BY-NC-SA 2.0} + } + + \input{communication.tex} + \newpage + \input{writing.tex} + \newpage + \input{morse_code.tex} + \newpage + \input{braille.tex} + \newpage + \input{shift_and_shift_lock.tex} + +\end{document} \ No newline at end of file diff --git a/AR/01_communication/braille.tex b/AR/01_communication/braille.tex new file mode 100644 index 0000000..cbb3204 --- /dev/null +++ b/AR/01_communication/braille.tex @@ -0,0 +1,62 @@ +\model{Braille} + + As already mentioned, there are ways of presenting letters that don't involve placing ink on paper. Braille uses raised dots on heavy paper (represented here as black dots since raised dots is more difficult!). + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/braille_chart.png} + \end{center} + + {\it\large Refer to Model 4 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q Using the information above, give the Latin letters equivalent to the following: + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/braille_code.png} + \end{center} + \begin{answer}[0.5in] + C \quad O \quad L \quad L \quad E \quad G \quad E + \end{answer} + + \Q Looking at the top right dot for B and C, how many possible unique values are there for one dot? + \begin{answer}[0.5in] + two (2) + \end{answer} + + \Q Looking at the middle row for A, E, F, and G, how many possible unique combinations can two dots take? + \begin{answer}[0.5in] + four (4) + \end{answer} + + \Q How many dots are possible in one Braille block (or cell)? + \hfill\ans{six (6)} + + \Q How many unique combinations of dots can exist in one Braille cell?\key\\[-2.5mm] + \begin{answer}[0.5in] + $2^6 = 64$ + \end{answer} + + \Q How did you calculate that value? + \begin{answer}[0.5in] + combinations = $2^n$ + \end{answer} + + \Q Imagine an alphabet with two letters, O and X. How many words could exist in this encoding if the word size + were the following values (the first two have been done for you)? What is the formula for this calculation? + \vspace{10pt} + \begin{center} + \begin{tabular}{|c|c|c|c|c|c|c|c|c|c|} + \hline + 1 & 2 & 3 & 4 & 5 & 6 & 7 & 8 & 9 & 10 \\ + \hline + 2 & 4 & 8 & \ans[0.2in]{16} & \ans[0.2in]{32} & \ans[0.2in]{64} & \ans[0.2in]{128} & \ans[0.2in]{256} & \ans[0.2in]{512} & \ans[0.3in]{1024} \\ + \hline + \end{tabular} + \end{center} + + \begin{answer}[0.5in] + The formula is $2^n$ (as given in question 20). + \end{answer} diff --git a/AR/01_communication/communication.tex b/AR/01_communication/communication.tex new file mode 100644 index 0000000..bb8a90a --- /dev/null +++ b/AR/01_communication/communication.tex @@ -0,0 +1,49 @@ +\model{Communication} + + \begin{center} + \includegraphics[width=0.5\textwidth]{figures/schramm_model.png} + \par\vspace{5pt} + {\small Figure 1: Schramm's Model of Communication} + \end{center} + + \vspace{10pt} + + A model of communication by Wilbur Schramm includes the following elements: + \begin{itemize} + \item Messenger + \item Encoding + \item Channel + \item Decoding + \item Recipient + \end{itemize} + + {\it\large Refer to Model 1 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q In Schramm's model, what elements are between the messenger and the recipient? + \begin{answer}[0.5in] + Encoding, Channel, and Decoding + \end{answer} + + \Q What channels are specified in the above image? + \hfill\ans{ Air waves (sound), light waves} + + \Q According to the image, what is carried on the channel? + \hfill\ans{Codes} + + \Q With verbal communication, what are the codes? + \hfill\ans{Spoken words (syllables, phonemes)} + + \newpage + + \Q Based on the model (and your personal experience), with in-person, face-to-face\key\\[-2.5mm] communication, what channel(s) are used? + \begin{answer}[1in] + Sound, sight (body language), touch, smell + \end{answer} + + \Q In communication, we often find that the message doesn't get through or is misunderstood. Using this model, what are possible causes for this situation? + \begin{answer}[1in] + Poor encoding, changes to codes on the channel, poor decoding + \end{answer} \ No newline at end of file diff --git a/AR/01_communication/figures/braille_chart.png b/AR/01_communication/figures/braille_chart.png new file mode 100644 index 0000000..6e0b301 Binary files /dev/null and b/AR/01_communication/figures/braille_chart.png differ diff --git a/AR/01_communication/figures/braille_code.png b/AR/01_communication/figures/braille_code.png new file mode 100644 index 0000000..0cf5ca9 Binary files /dev/null and b/AR/01_communication/figures/braille_code.png differ diff --git a/AR/01_communication/figures/dog_emoji.png b/AR/01_communication/figures/dog_emoji.png new file mode 100644 index 0000000..564b7ab Binary files /dev/null and b/AR/01_communication/figures/dog_emoji.png differ diff --git a/AR/01_communication/figures/hand.png b/AR/01_communication/figures/hand.png new file mode 100644 index 0000000..396d0dc Binary files /dev/null and b/AR/01_communication/figures/hand.png differ diff --git a/AR/01_communication/figures/morse_tree.png b/AR/01_communication/figures/morse_tree.png new file mode 100644 index 0000000..257b474 Binary files /dev/null and b/AR/01_communication/figures/morse_tree.png differ diff --git a/AR/01_communication/figures/pictographs.png b/AR/01_communication/figures/pictographs.png new file mode 100644 index 0000000..f6fd593 Binary files /dev/null and b/AR/01_communication/figures/pictographs.png differ diff --git a/AR/01_communication/figures/schramm_model.png b/AR/01_communication/figures/schramm_model.png new file mode 100644 index 0000000..b1ee969 Binary files /dev/null and b/AR/01_communication/figures/schramm_model.png differ diff --git a/AR/01_communication/figures/typewriter.png b/AR/01_communication/figures/typewriter.png new file mode 100644 index 0000000..5fde622 Binary files /dev/null and b/AR/01_communication/figures/typewriter.png differ diff --git a/AR/01_communication/morse_code.tex b/AR/01_communication/morse_code.tex new file mode 100644 index 0000000..2874ebb --- /dev/null +++ b/AR/01_communication/morse_code.tex @@ -0,0 +1,53 @@ +\model{Morse Code} + + As suggested by above with American Sign Language, there are ways of presenting letters that don't involve placing ink on paper. Morse Code transfers letters using combinations of short (dot) or long (dash) bursts of light, electricity, radio, or sound. + + \vspace{10pt} + \begin{center} + \begin{tabular}{ll|ll|ll} + A & $\bullet$ -- & J & $\bullet$ --- & S & $\bullet\bullet\bullet$ \\ + B & --$\bullet\bullet\bullet$ & K & --$\bullet$-- & T & -- \\ + C & --$\bullet$-- & L & $\bullet$--$\bullet\bullet$ & U & $\bullet\bullet$-- \\ + D & --$\bullet\bullet$ & M & ---- & V & $\bullet\bullet\bullet$-- \\ + E & $\bullet$ & N & --$\bullet$ & W & $\bullet$---- \\ + F & $\bullet\bullet$--$\bullet$ & O & ----- & X & --$\bullet\bullet$-- \\ + G & ----$\bullet$ & P & $\bullet$----$\bullet$ & Y & --$\bullet$---- \\ + H & $\bullet\bullet\bullet\bullet$ & Q & ----$\bullet$-- & Z & ----$\bullet\bullet$ \\ + I & $\bullet\bullet$ & R & $\bullet$--$\bullet$ & & \\ + \end{tabular} + \end{center} + + {\it\large Refer to Model 3 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q Using the chart above, encode 'COMPUTER'. + \begin{answer}[0.5in] + --$\bullet$--$\bullet$ \quad ----- \quad $\bullet$----$\bullet$ \quad --$\bullet\bullet$ \quad $\bullet\bullet$-- \quad -- \quad $\bullet$ \quad $\bullet$--$\bullet$ + \end{answer} + + \Q Decode the following:\key\\[-2.5mm] + \vspace{5pt} + \begin{center} + $\bullet\bullet\bullet$ \quad --$\bullet$--$\bullet$ \quad $\bullet\bullet\bullet\bullet$ \quad ----- \quad ----- \quad $\bullet$--$\bullet\bullet$ + \end{center} + \begin{answer}[0.5in] + S \quad C \quad H \quad O \quad O \quad L + \end{answer} + + \Q Using the chart above, how many tests or comparisons would you have to make to find each of the letters in question 12 (how many rows would you examine starting your search at the top)? + \begin{answer}[1in] + 19 \quad 3 \quad 8 \quad 15 \quad 15 \quad 12 + \end{answer} + + \Q Using the tree below, how many tests or comparisons would you have to make for each of the letters in question 12 (how many lines would you follow starting your search at the top)? + \begin{answer}[1in] + 3 \quad 4 \quad 4 \quad 3 \quad 3 \quad 4 + \end{answer} + \vspace{10pt} + \begin{center} + {\small Decode Morse Code by following dots to the left and dashes to the right.} + \par\vspace{5pt} + \includegraphics[width=0.9\textwidth]{figures/morse_tree.png} + \end{center} \ No newline at end of file diff --git a/AR/01_communication/shift_and_shift_lock.tex b/AR/01_communication/shift_and_shift_lock.tex new file mode 100644 index 0000000..790b779 --- /dev/null +++ b/AR/01_communication/shift_and_shift_lock.tex @@ -0,0 +1,31 @@ +\model{Shift and Shift Lock} + + One way to reduce the cost of a keyboard is to reduce the number of keys. Early typewriters often left out the digit 1 (see image). Even today's modern computer keyboards (with over 100 keys!) do not have separate keys for uppercase and lowercase letters. + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.5\textwidth]{figures/typewriter.png} + \end{center} + + {\it\large Refer to Model 5 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q How would someone type (encode) the digit 1 (one) on a typewriter missing that key? + \begin{answer}[0.25in] + A lowercase L (l) or uppercase I. + \end{answer} + + \Q How would someone read (decode) the typed page and know that the digit one was intended instead of letters or something else? + \hfill\ans{Context} + + \Q If we think of the keys as codes that tell the typewriter what to print on the paper, how do we type (encode) the '\$' symbol (shared with the '4' key)? How many codes (keys) are used? + \begin{answer}[0.25in] + Two codes (keystrokes): + <4> + \end{answer} + + \Q If we have a continuous sequence of alternate values (say, four uppercase in a row),\key\\[-2.5mm] what option do we have to reduce the number of codes (key presses)? + \begin{answer}[0.25in] + Shift Lock + \end{answer} \ No newline at end of file diff --git a/AR/01_communication/writing.tex b/AR/01_communication/writing.tex new file mode 100644 index 0000000..6094800 --- /dev/null +++ b/AR/01_communication/writing.tex @@ -0,0 +1,46 @@ +\model{Writing} + + One limitation in communication is when the recipient is distant in space or time. In that case you can write your message and deliver it to the recipient (or wait for them to find it). That writing needs to be encoded in a medium that the recipient can decode. + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.4\textwidth]{figures/pictographs.png} + \end{center} + + {\it\large Refer to Model 2 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q What items are depicted in this picture? + \begin{answer}[0.5in] + Four-footed animal (deer?), two-footed animal (duck?), humans, an arch (rainbow? mountain?) + \end{answer} + + \Q Pictograms are little schematic pictures of things, actions, or concepts, and form the basis of cuneiform and hieroglyphs. + Ideograms are graphical symbols that represent ideas. Logogram is the name of the symbols that are used in writing Chinese, Japanese, and Korean. + In what sense would it be easier for children to learn to read if dog were written as '\includegraphics[height=1em]{figures/dog_emoji.png}'? + \begin{answer}[0.5in] + The logogram is an immediate, pictorial representation of the meaning of the word. There is no need to learn a separate alphabet, phonetics, or spelling. + \end{answer} + + \Q While there are over 100,000 Chinese characters, a literate person needs to know only 4,000--5,000 characters. Printing using movable type + (each letter is a separate piece) was invented in China several hundred years before Gutenberg created his press in 15th century Europe. + Why might it have caught on more quickly in Europe? + \begin{answer}[1in] + Creating, storing, and searching 100,000 unique pieces of movable type would be much more cumbersome than doing the same with up to 100 pieces. + \end{answer} + + \Q Even when words are made up of letters, the letters themselves can have different presentations. Consider the following examples of the letters A, B, and C. + What does that suggest about the difference between a letter and how it is written (a glyph)? + \vspace{5pt} + \begin{center} + {\Large ABC} \quad {\large abc} \quad {\Large\textit{ABC}} + \end{center} + \begin{center} + \includegraphics[width=3in]{figures/hand.png} + \end{center} + \begin{answer}[1in] + The idea or meaning of a letter is different from how it is transmitted. The letter 'A' + can be drawn or gestured in a variety of ways, but all have the same meaning. + \end{answer} \ No newline at end of file diff --git a/AR/02_electricity/02_electricity.tex b/AR/02_electricity/02_electricity.tex new file mode 100644 index 0000000..191fb69 --- /dev/null +++ b/AR/02_electricity/02_electricity.tex @@ -0,0 +1,56 @@ +% Source: CPTR 280 Computer Organization and Assembly Language Fall 2020 +% File: "02 Electricity (key).pdf" +% Author: James Foster, pogil@jgfoster.net + +% comment out for student version +% \ifdefined\Student\relax\else\def\Teacher{}\fi + +\documentclass[12pt]{article} + +\title{Activity 2: Electric Circuits and Relays} +\author{James Foster} +\newcommand{\activityeditor}{James Foster} +\newcommand{\activitysource}{\url{pogil@jgfoster.net}} +\date{Fall 2020} + +\input{../../cspogil.sty} +\usepackage{graphicx} +\usepackage{tabularx} + +\begin{document} + + \begin{center} + \maketitle + \rolenames + \end{center} + + \keyquestions{ + \item Model 2, Question \#11 + \item Model 2, Question \#19 + \item Model 3, Question \#20 + } + + \newpage + \maketitle + + Electricity can be used to communicate information over long distances. This is done using relays, which forms a core foundation for building an electronic computer. + + \guides{ + \item Identify the components of a circuit; + \item Use Ohm's Law to solve equations; and, + \item Describe how a relay works. + }{ + \item Draw basic circuit diagrams. + }{ + No additional notes + }{ + \item [1] \url{https://en.wikipedia.org/wiki/Electromagnet} + } + + \input{hidraulic_systems.tex} + \newpage + \input{electric_circuit.tex} + \newpage + \input{telegraphs_and_relays.tex} + +\end{document} \ No newline at end of file diff --git a/AR/02_electricity/electric_circuit.tex b/AR/02_electricity/electric_circuit.tex new file mode 100644 index 0000000..d2a39e2 --- /dev/null +++ b/AR/02_electricity/electric_circuit.tex @@ -0,0 +1,108 @@ +\model{Electric Circuit} + + Water flowing through pipes is often used as an (imperfect) analogy for electricity (electrons flowing through wires). The circuit diagram in Figure 2 has the following components: + \begin{itemize} + \item Battery (left) + \item Switch (top) + \item Resistor (right) + \item Wires (to connect each element) + \end{itemize} + + In practice, the resistor may be a light or a heating element. Portions of the circuit with pressure are shown in green. + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/circuit_open_switch.png} + \par\vspace{5pt} + {\small Figure 2: Circuit with open switch} + \end{center} + + {\it\large Refer to Model 2 above as your team develops consensus answers + to the questions below.} + + \quest{20 min} + + \Q For each of the above components, what is the analogous item in a hydraulic\key\\[-2.5mm] system (you may write it below or next to the component above)? + \begin{answer}[1in] + Battery: Pump; Switch: Faucet; Resistor: Nozzle; Wires: Pipes + \end{answer} + + \Q In the diagram shown above, the switch connecting the battery to the resistor is open and so electricity cannot flow. + How does that compare with how you would describe a valve in a hydraulic system? That is, is the faucet open or closed when the water is moving? + \begin{answer}[1in] + When a faucet is open then water can flow. + \end{answer} + + \Q Even with the switch open, are the electrons between the battery and the switch under pressure? + \begin{answer}[0.75in] + Yes, there is still pressure (shown in green) when the switch is open. + \end{answer} + + \Q With the switch closed (see the diagram below), is there pressure between the switch and the resistor? + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/circuit_closed_switch.png} + \par\vspace{5pt} + {\small Figure 3: Circuit with closed switch} + \end{center} + \begin{answer}[1in] + Yes, there is pressure between the switch and the resistor. + \end{answer} + + \Q Is there pressure between the resistor and the battery along the bottom wire? Does it make a difference if the switch is open or closed? + \begin{answer}[1in] + No, there is no (significant) pressure between the resistor and the battery along the bottom wire. This is the case if the switch is open or closed. + \end{answer} + + \Q An analogy for the circuit in Figure 3 might be a fish tank where water is taken out, run through a filter, and pumped back in. Would the size of the tank impact the amount of water flowing through the filter? + \begin{answer}[1in] + No, the size of the tank does not impact the amount of water flowing through the filter. + \end{answer} + + The new symbol at the bottom of Figure 4 shows an infinite ``reservoir'' of electrons available (and not under pressure) to which the circuit can dump excess electrons or acquire needed electrons to push through the circuit. This new symbol is called ground (or earth). + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/circuit_one_ground.png} + \par\vspace{5pt} + {\small Figure 4: Circuit with one ground} + \end{center} + + \Q The circuit in Figure 5 does not have a wire across the bottom completing the circuit. How would this change impact the number of electrons moving through the circuit? + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/circuit_two_grounds.png} + \par\vspace{5pt} + {\small Figure 5: Circuit with two grounds} + \end{center} + \begin{answer}[1in] + Because the ``reservoir'' is infinite and not under pressure, it makes no difference when the bottom wire is replaced with two grounds. + \end{answer} + + \newpage + + \Q The following table has observations of electrons/second (current is measured in amperes), pressure (voltage is measured in volts), and resistance (measured in ohms). From this data, derive Ohm's Law, a formula for I in terms of E and R. + \vspace{10pt} + \begin{center} + \begin{tabular}{|c|c|c|} + \hline + Amperes (I) & Voltage (E) & Resistance (R) \\ + \hline + 5 & 100 & 20 \\ + \hline + 5 & 200 & 40 \\ + \hline + 10 & 200 & 20 \\ + \hline + 2 & 50 & 25 \\ + \hline + \end{tabular} + \end{center} + + \begin{answer}[1in] + I = E / R + \end{answer} + + \Q While a wire is designed to conduct electricity, it does not do so in a perfect fash-\key\\[-2.5mm] ion. That is, there is some resistance and over a long distance the pressure (voltage) will drop. If we need light at a distant location, what are two things that could be done to make sure that adequate amperage is available? Consider your answers to questions 8 and 18. + \begin{answer}[1in] + Increase the voltage (with a more powerful battery) and/or decrease the resistance (with a thicker wire). + \end{answer} \ No newline at end of file diff --git a/AR/02_electricity/figures/circuit_closed_relay.png b/AR/02_electricity/figures/circuit_closed_relay.png new file mode 100644 index 0000000..b815545 Binary files /dev/null and b/AR/02_electricity/figures/circuit_closed_relay.png differ diff --git a/AR/02_electricity/figures/circuit_closed_switch.png b/AR/02_electricity/figures/circuit_closed_switch.png new file mode 100644 index 0000000..2fd20f1 Binary files /dev/null and b/AR/02_electricity/figures/circuit_closed_switch.png differ diff --git a/AR/02_electricity/figures/circuit_inductor.png b/AR/02_electricity/figures/circuit_inductor.png new file mode 100644 index 0000000..754ec6f Binary files /dev/null and b/AR/02_electricity/figures/circuit_inductor.png differ diff --git a/AR/02_electricity/figures/circuit_one_ground.png b/AR/02_electricity/figures/circuit_one_ground.png new file mode 100644 index 0000000..b0217fe Binary files /dev/null and b/AR/02_electricity/figures/circuit_one_ground.png differ diff --git a/AR/02_electricity/figures/circuit_open_relay.png b/AR/02_electricity/figures/circuit_open_relay.png new file mode 100644 index 0000000..a731ca5 Binary files /dev/null and b/AR/02_electricity/figures/circuit_open_relay.png differ diff --git a/AR/02_electricity/figures/circuit_open_switch.png b/AR/02_electricity/figures/circuit_open_switch.png new file mode 100644 index 0000000..d05323f Binary files /dev/null and b/AR/02_electricity/figures/circuit_open_switch.png differ diff --git a/AR/02_electricity/figures/circuit_two_grounds.png b/AR/02_electricity/figures/circuit_two_grounds.png new file mode 100644 index 0000000..eab2a1f Binary files /dev/null and b/AR/02_electricity/figures/circuit_two_grounds.png differ diff --git a/AR/02_electricity/figures/electromagnet.png b/AR/02_electricity/figures/electromagnet.png new file mode 100644 index 0000000..09e2fba Binary files /dev/null and b/AR/02_electricity/figures/electromagnet.png differ diff --git a/AR/02_electricity/figures/laura_washing_car.png b/AR/02_electricity/figures/laura_washing_car.png new file mode 100644 index 0000000..c7b3a89 Binary files /dev/null and b/AR/02_electricity/figures/laura_washing_car.png differ diff --git a/AR/02_electricity/figures/relay_extend_distance.png b/AR/02_electricity/figures/relay_extend_distance.png new file mode 100644 index 0000000..a994ecc Binary files /dev/null and b/AR/02_electricity/figures/relay_extend_distance.png differ diff --git a/AR/02_electricity/hidraulic_systems.tex b/AR/02_electricity/hidraulic_systems.tex new file mode 100644 index 0000000..90ea648 --- /dev/null +++ b/AR/02_electricity/hidraulic_systems.tex @@ -0,0 +1,68 @@ +\model{Hydraulic Systems} + + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/laura_washing_car.png} + \par\vspace{5pt} + {\small Figure 1: Laura washing the car} + \end{center} + + \vspace{10pt} + + When washing your car, you might connect a hose to a faucet and spray the car with a nozzle. You might also put water in a bucket so you could use a sponge to wipe dirt off the car.\\ + + {\it\large Refer to Model 1 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q What path does the water take to get to the bucket? What is the source? And the source before that? What is the origin? + \begin{answer}[1in] + Water gets to the bucket from the hose; it gets to the hose from the faucet; it get to the faucet from the pipes; + it gets to the pipes from the municipal water supply; it gets to the municipal water supply from a well or river; + it gets to the well or river from rain or snow melt; rain and snow comes from clouds; clouds come from ocean evaporation; + ocean are fed by rivers\ldots + \end{answer} + + \Q Where does the water go when it runs off the car? What is the ultimate destination? + \begin{answer}[0.5in] + From the car to the driveway to the gutter to the storm drain to the river to the ocean. + \end{answer} + + \Q What is the relationship between the ultimate source and the ultimate destination? + \begin{answer}[0.5in] + The water cycle can be seen to start/end with the oceans (or any other point in the cycle). + \end{answer} + + \Q What moves water from a well into an above-ground tank? + \hfill\ans{A pump} + + \Q Is the water behind a faucet under pressure when the faucet valve is closed? + \begin{answer}[0.75in] + Yes, the pressure is there but it isn't moving. + \end{answer} + + \Q Is the water under pressure when it sits in a bucket? + \begin{answer}[0.5in] + No significant pressure (other than gravity holding it in the bucket). + \end{answer} + + \Q What adjustment to the nozzle causes the water pressure to increase? + \begin{answer}[0.5in] + Making the passage through the nozzle smaller increases the speed + (and therefore pressure over the smaller surface area). + \end{answer} + + \Q Does it take more pressure to move a smoothie through a fat straw or a thin straw? + \begin{answer}[0.5in] + More pressure is required to move the same volume through a smaller opening. + \end{answer} + + \Q What two changes to the system would allow you to fill a bucket (or swimming pool) more quickly? + \begin{answer}[0.5in] + Increase the pressure (with the same diameter hose) or increase the hose diameter (with the same pressure). + \end{answer} + + \Q Describe gallons per minute in terms of water pressure and the diameter of the hose. + \begin{answer}[0.5in] + As pressure increases, more fluid will pass; as diameter increases, more fluid will pass. + \end{answer} \ No newline at end of file diff --git a/AR/02_electricity/telegraphs_and_relays.tex b/AR/02_electricity/telegraphs_and_relays.tex new file mode 100644 index 0000000..b03f62f --- /dev/null +++ b/AR/02_electricity/telegraphs_and_relays.tex @@ -0,0 +1,67 @@ +\model{Telegraphs and Relays} + + \quest{10 min} + + \Q An electric circuit could be used by a person controlling a switch to send a mess-\key\\[-2.5mm] age (say, with Morse Code) to a distant person observing a light or buzzer. + But, as suggested by question 19, there is a limit to how long a distance the circuit can stretch. + If a single circuit with a person at each end can transmit a message 10 miles, how would you send a message 20 miles (without modifying or augmenting the circuit)? + \begin{answer}[1in] + Use two circuits with a person in between who could ``repeat'' the code. + \end{answer} + + \vspace{10pt} + + An electromagnet is a type of magnet in which the magnetic field is produced by an electric current. Electromagnets usually consist of wire wound into a coil. + A current through the wire creates a magnetic field which is concentrated in the hole, denoting the center of the coil. The magnetic field disappears when the current is turned off. + The wire turns are often wound around a magnetic core made from a ferromagnetic or ferrimagnetic material such as iron; the magnetic core concentrates the magnetic flux and makes a more powerful magnet. + + The main advantage of an electromagnet over a permanent magnet is that the magnetic field can be quickly changed by controlling the amount of electric current in the winding. + However, unlike a permanent magnet that needs no power, an electromagnet requires a continuous supply of current to maintain the magnetic field. + + Electromagnets are widely used as components of other electrical devices, such as motors, generators, electromechanical solenoids, relays, loudspeakers, hard disks, MRI machines, scientific instruments, and magnetic separation equipment. + Electromagnets are also employed in industry for picking up and moving heavy iron objects such as scrap iron and steel. [1] + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.25\textwidth]{figures/electromagnet.png} + \par\vspace{5pt} + {\small Figure 6: Electromagnet} + \end{center} + + \newpage + + In an electric circuit diagram, an electromagnet is called an inductor and looks + (and acts) very much like a resistor (Figure 7). + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/circuit_inductor.png} + \par\vspace{5pt} + {\small Figure 7: Circuit with inductor} + \end{center} + + \Q Samuel Morse demonstrated that an inductor (magnet) could be used to control (turn on and off) a switch + (see Figures 8 and 9). Use this insight to modify Figure 10 to extend the distance over which you could send a message using a single electric circuit. + \vspace{10pt} + \begin{center} + \begin{minipage}{0.45\textwidth} + \centering + \includegraphics[width=0.9\textwidth]{figures/circuit_open_relay.png} + \par\vspace{5pt} + {\small Figure 8: Circuit with open relay} + \end{minipage} + \hfill + \begin{minipage}{0.45\textwidth} + \centering + \includegraphics[width=0.9\textwidth]{figures/circuit_closed_relay.png} + \par\vspace{5pt} + {\small Figure 9: Circuit with closed relay} + \end{minipage} + \end{center} + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.8\textwidth]{figures/relay_extend_distance.png} + \par\vspace{5pt} + {\small Figure 10: Use of relay to extend distance} + \end{center} \ No newline at end of file diff --git a/AR/03_number_systems/03_number_systems.tex b/AR/03_number_systems/03_number_systems.tex new file mode 100644 index 0000000..9f2d601 --- /dev/null +++ b/AR/03_number_systems/03_number_systems.tex @@ -0,0 +1,59 @@ +% Source: CPTR 280 Computer Organization and Assembly Language Fall 2020 +% File: "03 Number Systems (key).pdf" +% Author: James Foster, pogil@jgfoster.net + +% comment out for student version +% \ifdefined\Student\relax\else\def\Teacher{}\fi + +\documentclass[12pt]{article} + +\title{Activity 3: Number Systems} + +\author{James Foster} +\newcommand{\activityeditor}{James Foster} +\newcommand{\activitysource}{\url{pogil@jgfoster.net}} +\date{Fall 2020} + +\input{../../cspogil.sty} +\usepackage{graphicx} +\usepackage{tabularx} + +\begin{document} + + \begin{center} + \maketitle + \rolenames + \end{center} + + \keyquestions{ + \item Model 1, Question \#6 + \item Model 2, Question \#14 + \item Model 3, Question \#23 + } + + \newpage + \maketitle + + At the fundamental level digital computers work with high and low voltage, interpreted as ones and zeros and represented as binary numbers. Understanding how data is represented as binary numbers is important to understanding how computers work and how to writing programs. + + \guides{ + \item explain the role of exponents in positional notation; and, + \item encode data in binary. + }{ + \item convert between numbers in different bases. + }{ + No additional notes + }{ + \item Based in part on \href{https://drive.google.com/file/d/1twyZLJo5WvwJUgLYUG2FI21QRNWLwURL/view}{This activity} + \item Based in part on \href{https://drive.google.com/file/d/1FR4omsdMQIDgPbypDl73fpQ4MzMTu9nn/view}{This activity} + } + + \input{representing_numbers.tex} + \newpage + \input{positional_notation.tex} + \newpage + \input{convert_between_bases.tex} + \newpage + \input{hexadecimal.tex} + +\end{document} \ No newline at end of file diff --git a/AR/03_number_systems/convert_between_bases.tex b/AR/03_number_systems/convert_between_bases.tex new file mode 100644 index 0000000..1d74c63 --- /dev/null +++ b/AR/03_number_systems/convert_between_bases.tex @@ -0,0 +1,153 @@ +\model{Convert Between Bases} + + There are (at least) two approaches to converting a decimal number to another base. Each approach involves divisions + (by powers of the base) and special treatment of the (integer) quotient and remainder. + + \vspace{10pt} + One approach to converting a decimal number to another base is to start building the number from the left (with the most significant digit) and working to the right (with the least significant digit). + Observe how we use the following table to convert 1000$_{\text{ten}}$ to 1750$_{\text{eight}}$. + + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|} + \hline + \textbf{Step} & 1 & 2 & 3 & 4 \\ + \hline + Start and Remainder & 1,000 & 488 & 40 & 0 \\ + \hline + Place & $8^3$ & $8^2$ & $8^1$ & $8^0$ \\ + \hline + Divide by Place & $\div$ 512 & $\div$ 64 & $\div$ 8 & $\div$ 1 \\ + \hline + Quotient & 1 & 7 & 5 & 0 \\ + \hline + \end{tabular} + \end{center} + + {\it\large Refer to Model 3 above as your team develops consensus answers + to the questions below.} + + \quest{15 min} + + \Q Complete the following table to convert 10,000$_{\text{ten}}$ to octal. + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|} + \hline + Start and Remainder & \ans[0.5in]{10,000} & \ans[0.5in]{1808} & \ans[0.5in]{272} & \ans[0.5in]{16} & \ans[0.5in]{0} \\ + \hline + Place & $8^4$ & $8^3$ & $8^2$ & $8^1$ & $8^0$ \\ + \hline + Divide by Place & $\div$ 4096 & $\div$ 512 & $\div$ 64 & $\div$ 8 & $\div$ 1 \\ + \hline + Quotient & \ans[0.5in]{2} & \ans[0.5in]{3} & \ans[0.5in]{4} & \ans[0.5in]{2} & \ans[0.5in]{0} \\ + \hline + \end{tabular} + \end{center} + + \Q Complete the following table to convert 100$_{\text{ten}}$ to binary. + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|c|c|} + \hline + Start and Remainder & \ans[0.4in]{100} & \ans[0.4in]{36} & \ans[0.4in]{4} & \ans[0.4in]{4} & \ans[0.4in]{4} & \ans[0.4in]{0} & \ans[0.4in]{0} \\ + \hline + Place & $2^6$ & $2^5$ & $2^4$ & $2^3$ & $2^2$ & $2^1$ & $2^0$ \\ + \hline + Divide by Place & $\div$ 64 & $\div$ 32 & $\div$ 16 & $\div$ 8 & $\div$ 4 & $\div$ 2 & $\div$ 1 \\ + \hline + Quotient & \ans[0.4in]{1} & \ans[0.4in]{1} & \ans[0.4in]{0} & \ans[0.4in]{0} & \ans[0.4in]{1} & \ans[0.4in]{0} & \ans[0.4in]{0} \\ + \hline + \end{tabular} + \end{center} + + \newpage + + \Q Recall that one bit can have two values (0 and 1), and that two bits can have four values (00, 01, 10, and 11). + \begin{enumerate} + \item How many values can 3 bits represent? (hint: not 6!) + \hfill\ans{8} + + \item How many values can 4 bits represent? + \hfill\ans{16} + + \item How many values can 8 bits represent? + \hfill\ans{256} + + \item How many values can 10 bits represent? + \hfill\ans{1024} + + \item What is the formula for how many values N bits can represent? + \hfill\ans[0.6in]{$2^N$} + \end{enumerate} + + \vspace{5pt} + \textit{These values are very useful; remember them!}\\ + + Another approach to converting from decimal to a base is to start building the number from the right and work left. In this case we always divide by the base. Observe how we use the following table to convert 1000$_{\text{ten}}$ to 1750$_{\text{eight}}$. + + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|} + \hline + \textbf{Step} & 4 & 3 & 2 & 1 \\ + \hline + Start and Quotient & 1 & 15 & 125 & 1000 \\ + \hline + Divide by Base & $\div$ 8 & $\div$ 8 & $\div$ 8 & $\div$ 8 \\ + \hline + Remainder & 1 & 7 & 5 & 0 \\ + \hline + \end{tabular} + \end{center} + + \Q Complete the following table to convert 10,000$_{\text{ten}}$ to octal. + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|} + \hline + Start and Quotient & \ans[0.5in]{2} & \ans[0.5in]{19} & \ans[0.5in]{156} & \ans[0.5in]{1250} & \ans[0.5in]{10,000} \\ + \hline + Divide by Base & $\div$ 8 & $\div$ 8 & $\div$ 8 & $\div$ 8 & $\div$ 8 \\ + \hline + Remainder & \ans[0.5in]{2} & \ans[0.5in]{3} & \ans[0.5in]{4} & \ans[0.5in]{2} & \ans[0.5in]{0} \\ + \hline + \end{tabular} + \end{center} + + \Q Complete the following table to convert 100$_{\text{ten}}$ to binary. + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|c|c|} + \hline + Start and Quotient & \ans[0.4in]{1} & \ans[0.4in]{3} & \ans[0.4in]{6} & \ans[0.4in]{12} & \ans[0.4in]{25} & \ans[0.4in]{50} & \ans[0.4in]{100} \\ + \hline + Divide by Base & $\div$ 2 & $\div$ 2 & $\div$ 2 & $\div$ 2 & $\div$ 2 & $\div$ 2 & $\div$ 2 \\ + \hline + Remainder & \ans[0.4in]{1} & \ans[0.4in]{1} & \ans[0.4in]{0} & \ans[0.4in]{0} & \ans[0.4in]{1} & \ans[0.4in]{0} & \ans[0.4in]{0} \\ + \hline + \end{tabular} + \end{center} + + \newpage + As a general rule, converting between non-decimal bases is done by converting to decimal and then the target base (unless you want to learn multiplication and division in other bases!). But shortcuts are possible when converting between bases where one is a power of the other. Specifically, converting between binary and octal (and later hexadecimal) is trivial. Note that each single octal digit (0-7) is always represented by exactly three binary digits, so you can build (or memorize) a simple conversion table. + + \Q Complete the following octal to binary conversion table: + \vspace{10pt} + \begin{center} + \begin{tabular}{|c|c|c|c|c|c|c|c|c|} + \hline + \textbf{Octal} & 7 & 6 & 5 & 4 & 3 & 2 & 1 & 0 \\ + \hline + \textbf{Binary} & \ans[0.4in]{111} & \ans[0.4in]{110} & \ans[0.4in]{101} & \ans[0.4in]{100} & \ans[0.4in]{011} & \ans[0.4in]{010} & \ans[0.4in]{001} & \ans[0.4in]{000} \\ + \hline + \end{tabular} + \end{center} + + \Q What is 4321$_{\text{eight}}$ in binary? + \hfill\ans{100 011 010 001} + + \Q What is 11010101$_{\text{binary}}$ in octal?\key\\[-2.5mm] + \begin{answer}[0.5in] + 325 + \end{answer} \ No newline at end of file diff --git a/AR/03_number_systems/figures/cat.png b/AR/03_number_systems/figures/cat.png new file mode 100644 index 0000000..8a9b75a Binary files /dev/null and b/AR/03_number_systems/figures/cat.png differ diff --git a/AR/03_number_systems/figures/ducks.png b/AR/03_number_systems/figures/ducks.png new file mode 100644 index 0000000..4fbfa15 Binary files /dev/null and b/AR/03_number_systems/figures/ducks.png differ diff --git a/AR/03_number_systems/figures/number.png b/AR/03_number_systems/figures/number.png new file mode 100644 index 0000000..7de0f06 Binary files /dev/null and b/AR/03_number_systems/figures/number.png differ diff --git a/AR/03_number_systems/hexadecimal.tex b/AR/03_number_systems/hexadecimal.tex new file mode 100644 index 0000000..50f6be4 --- /dev/null +++ b/AR/03_number_systems/hexadecimal.tex @@ -0,0 +1,67 @@ +\model{Hexadecimal} + + \vspace{10pt} + So far, we have looked at number systems with bases of ten or less. But if we had six fingers per hand, then we would likely grow up using base twelve + (which is evenly divisible by 2, 3, 4, and 6, so has advantages!). + + As it happens, while octal was popular in the early days of computers, it is more common today to use hexadecimal (base 16) to represent internal values. + By convention, we use A-F to represent ten through fifteen.\\ + + {\it\large Refer to Model 4 above as your team develops consensus answers + to the questions below.} + + \quest{15 min} + + \Q Complete the following table to convert the hexadecimal number 7E3$_{\text{sixteen}}$ to base ten. + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|} + \hline + \textbf{Hexadecimal Numbers} & two hundred fifty-sixes & sixteens & ones & \textbf{Total} \\ + \hline + Digit & 7 & E & 3 & \\ + \hline + Place (full) & 256 & 16 & 1 & \\ + \hline + Place (exponent notation) & $16^2$ & $16^1$ & $16^0$ & \\ + \hline + Digit * Place & \ans[0.5in]{1792} & \ans[0.5in]{224} & \ans[0.5in]{3} & \ans[0.5in]{2025} \\ + \hline + \end{tabular} + \end{center} + + \Q Complete the following table to convert 99,324$_{\text{ten}}$ to hexadecimal. + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|} + \hline + Start and Quotient & \ans[0.5in]{1} & \ans[0.5in]{24} & \ans[0.5in]{387} & \ans[0.5in]{6207} & \ans[0.5in]{99,324} \\ + \hline + Divide by Base & $\div$ 16 & $\div$ 16 & $\div$ 16 & $\div$ 16 & $\div$ 16 \\ + \hline + Remainder & \ans[0.5in]{1} & \ans[0.5in]{8} & \ans[0.5in]{3} & \ans[0.5in]{F} & \ans[0.5in]{C} \\ + \hline + \end{tabular} + \end{center} + + \Q As an extension to question 21, complete the following hexadecimal to binary table: + \vspace{10pt} + \begin{center} + \begin{tabular}{|c|c|c|c|c|c|c|c|c|} + \hline + \textbf{Hexadecimal} & F & E & D & C & B & A & 9 & 8 \\ + \hline + \textbf{Binary} & \ans[0.4in]{1111} & \ans[0.4in]{1110} & \ans[0.4in]{1101} & \ans[0.4in]{1100} & \ans[0.4in]{1011} & \ans[0.4in]{1010} & \ans[0.4in]{1001} & \ans[0.4in]{1000} \\ + \hline + \end{tabular} + \end{center} + + \Q What is 1101'0101$_{\text{binary}}$ in hexadecimal (the apostrophe character is used to group four binary digits, much like commas are used to group three decimal digits)? + \begin{answer}[0.3in] + D5 + \end{answer} + + \Q Instead of using a subscript with the base spelled out as a word, many languages use a prefix of ``0x'' to designate a hexadecimal number. What is 0x7C1 in binary? + \begin{answer}[0.2in] + 0111'1100'0001 + \end{answer} \ No newline at end of file diff --git a/AR/03_number_systems/positional_notation.tex b/AR/03_number_systems/positional_notation.tex new file mode 100644 index 0000000..1b5cd99 --- /dev/null +++ b/AR/03_number_systems/positional_notation.tex @@ -0,0 +1,90 @@ +\model{Positional Notation} + + The structure of the Hindu-Arabic number system is revealed in the way we pronounce numbers. The year one thousand, nine hundred, fifty-eight is represented as follows: + + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|c|} + \hline + \textbf{Decimal Numbers} & ten-thousands & thousands & hundreds & tens & ones & one-tenths \\ + \hline + Digit & 0 & 1 & 9 & 5 & 8 & 0 \\ + \hline + Place (full) & 10,000 & 1,000 & 100 & 10 & 1 & 0.1 \\ + \hline + Place (exponent notation) & $10^4$ & $10^3$ & $10^2$ & $10^1$ & $10^0$ & $10^{-1}$ \\ + \hline + Digit * Place & 0 & 1,000 & 900 & 50 & 8 & 0 \\ + \hline + \end{tabular} + \end{center} + + {\it\large Refer to Model 2 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q What is the value of the exponent for the hundreds place? + \hfill\ans{two (2)} + + \Q Without changing the number represented, complete the column to the left of the thousands. What would be the digit for each additional column to the left for the given number? + \begin{answer}[0.5in] + 0 + \end{answer} + + \Q Without changing the number represented, complete the column to the right of the ones. What would be the digit for each additional column to the right for the given number? + \begin{answer}[0.5in] + 0 + \end{answer} + + \Q The use of ten as a base is presumably a consequence of most people having ten digits (fingers and thumbs on two hands) that are easy to use for counting. But there is nothing magical about base ten---other bases work just the same (and have some advantages, as we will see). + Complete the following table to convert the octal number 1776$_{\text{eight}}$ to base ten (use of a calculator is fine). + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|} + \hline + \textbf{Octal Numbers} & five hundred twelves & sixty-fours & eights & ones & \textbf{Total} \\ + \hline + Digit & 1 & 7 & 7 & 6 & \\ + \hline + Place (full) & 512 & 64 & 8 & 1 & \\ + \hline + Place (exponent notation) & $8^3$ & $8^2$ & $8^1$ & $8^0$ & \\ + \hline + Digit * Place & \ans[0.5in]{512} & \ans[0.5in]{448} & \ans[0.5in]{56} & \ans[0.5in]{6} & \ans[0.5in]{1022} \\ + \hline + \end{tabular} + \end{center} + + \Q Complete the following table to convert the binary number 101010$_{\text{two}}$ to decimal. + \vspace{10pt} + \begin{center} + \begin{tabular}{|l|c|c|c|c|c|c|c|} + \hline + \textbf{Binary Numbers} & 32s & sixteens & eights & fours & twos & ones & \textbf{Total} \\ + \hline + Digit & 1 & 0 & 1 & 0 & 1 & 0 & \\ + \hline + Place (full) & 32 & 16 & 8 & 4 & 2 & 1 & \\ + \hline + Place (exponent notation) & $2^5$ & $2^4$ & $2^3$ & $2^2$ & $2^1$ & $2^0$ & \\ + \hline + Digit * Place & \ans[0.4in]{32} & \ans[0.4in]{0} & \ans[0.4in]{8} & \ans[0.4in]{0} & \ans[0.4in]{2} & \ans[0.4in]{0} & \ans[0.5in]{= 42} \\ + \hline + \end{tabular} + \end{center} + + \Q Convert the number 10010000$_{\text{two}}$ to decimal. + \hfill\ans{144} + + \vspace{-20pt} + + \Q What two symbols (digits) are used to represent quantities in a binary system?\key\\[-2.5mm] + \begin{answer}[0.5in] + 0 and 1 + \end{answer} + + \Q In binary, what do all odd numbers have in common? + \begin{answer}[0.5in] + The one's place digit is always 1. + \end{answer} \ No newline at end of file diff --git a/AR/03_number_systems/representing_numbers.tex b/AR/03_number_systems/representing_numbers.tex new file mode 100644 index 0000000..acdf0fd --- /dev/null +++ b/AR/03_number_systems/representing_numbers.tex @@ -0,0 +1,75 @@ +\model{Representing Numbers} + + Whether we write cat, gato, or chat, we are referring to a \includegraphics[width=0.05\textwidth]{figures/cat.png}. Different words can be code for the same meaning. In a similar way, there are various ways of recording a number of ducks: + + \vspace{10pt} + \begin{center} + \includegraphics[width=0.3\textwidth]{figures/ducks.png} \quad VII\quad \includegraphics[width=0.05\textwidth]{figures/number.png} + \end{center} + + {\it\large Refer to Model 1 above as your team develops consensus answers + to the questions below.} + + \quest{10 min} + + \Q Write the number of ducks as a numeral and as a word. + \ans{Seven (7)} + + \Q Recall that in Roman Numerals, X represents the number of digits (fingers and thumbs on two hands) for a typical person. Provide the representation for the number of items in a dozen using Roman Numerals and at least two other representations. + \begin{answer}[0.5in] + XII, 12, twelve + \end{answer} + + \Q While Roman Numerals has some disadvantages, it works pretty well for some addition and subtraction problems. Calculate the following and record the answer in Roman Numerals. How does the answer compare to the problem? + \vspace{5pt} + \begin{center} + XI + VII = \ans[1in]{XVIII} + \end{center} + \begin{answer}[0.5in] + Uses the same symbols, just combining (and rearranging) + \end{answer} + + \Q Can you think of another way Roman Numerals might be easy to use, especially for someone carving dates on stone? + \begin{answer}[0.5in] + Straight lines are easier to cut + \end{answer} + + \vspace{10pt} + Our number system is known as the Hindu-Arabic or Indo-Arabic, or just Arabic number system and was brought to Europe from India by Arab mathematicians. + + \newpage + + \Q Compare the numbers II (Roman) and 11 (Arabic). + \begin{enumerate} + \item What is the value/meaning of the second (right-hand) of each of the numerals? + \begin{answer}[0.5in] + One + \end{answer} + + \item What is the value/meaning of the first (left-hand) of the two Roman Numerals? + \begin{answer}[0.5in] + Also one + \end{answer} + + \item What is the value/meaning of the first (left-hand) of the two Arabic Numerals? + \begin{answer}[0.5in] + Because of its position, it represents ten + \end{answer} + + \item How would you describe the difference? + \begin{answer}[0.5in] + In Arabic Numerals, position contains part of the meaning + \end{answer} + \end{enumerate} + + \vspace{-20pt} + + \Q Compare the numbers M (Roman) and 1000 (Arabic). What is the role of zero?\key\\[-2.5mm] + \begin{answer}[1in] + Zero acts as a placeholder to help the digits to the left find their right positional value. + \end{answer} + + \Q Why do Arabic Numerals not have special symbols for ten, one hundred, and one thousand? + \begin{answer}[1in] + Because we communicate these values by the digit one with a position. + \end{answer} \ No newline at end of file diff --git a/cspogil.sty b/cspogil.sty index a102064..f217783 100644 --- a/cspogil.sty +++ b/cspogil.sty @@ -291,7 +291,7 @@ Record your team's answers to the key questions (marked with \mbox{\key}) below. \end{tabular} } -% instructor's guide template +% instructor's guide template for CS1 and CS2 activities \newcommand{\guide}[3]{ \subsection*{Content Learning Objectives} \textit{After completing this activity, students should be able to:} @@ -336,6 +336,59 @@ Record your team's answers to the key questions (marked with \mbox{\key}) below. \clearpage } +% instructor's guide template for AR Architecture and Organization activities +\newcommand{\guides}[4]{ +\subsection*{Content Learning Objectives} +\textit{After completing this activity, students should be able to:} + +\begin{itemize}[itemsep=0pt,after=] +#1 +\end{itemize} + +\subsection*{Process Skill Goals} +\textit{During the activity, students should make progress toward:} + +\begin{itemize}[itemsep=0pt,after=] +#2 +\end{itemize} + +\ifdefined\Teacher +\vspace*{-13pt}\color{answers} +\subsection*{Facilitation Notes} +\vspace{-\bigskipamount} +\setlength{\parskip}{\bigskipamount} +#3 +\setlength{\parskip}{0pt} +\normalcolor +\fi + +%\usepackage{xstring} +%\IfSubStr{\theauthor}{ and } +% {\subsection*{Activity Authors}} +% {\subsection*{Activity Author}} +%\theauthor + +\vfill +\hrule + +\subsection*{Sources} +\begin{itemize}[itemsep=0pt,after=] +#4 +\end{itemize} + +\vspace{\baselineskip} +\begin{minipage}{0.133\linewidth} +\includegraphics[width=\linewidth]{../../figures/by-nc-sa.png} +\end{minipage} +\hfill +\begin{minipage}{0.853\linewidth} +\small +\textsuperscript{\textcopyright}2019 by \activityeditor{}, \activitysource{}. This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. +\end{minipage} +\clearpage +} + + % links on GitHub \newcommand{\github}[2]{\href{https://github.com/cspogil/PythonCS1/blob/master/#1}{#2}} \newcommand{\src}[2]{\href{https://drive.google.com/drive/folders/1CxGpmO-vsoYlrcQZ-6qSbmgnw2mLdbn9?usp=sharing}{\it #2}}