\input{../../../../base/worksheet.tex}

\noprintanswers

\title{Arbeitsblatt Zahlensysteme}
\header{Informatik}{}{13.11.2021}
\footer{Stefan Rothe}{}{}

\begin{document}
  \maketitle
  \begin{questions}

    % --------------------------------------------------------------------------
    {\bf \question Rechnen Sie die Dezimalzahlen ins Binärsystem um. Erkennen
      Sie ein Muster?}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Binär} \\
          \hline
            $1$ &   \answer{$1_2$} \\
          \hline
            $3$ &  \answer{$11_2$} \\
          \hline
            $5$ & \answer{$101_2$} \\
          \hline
            $7$ & \answer{$111_2$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Binär} \\
          \hline
            $30$ &  \answer{$1\,1110_2$} \\
          \hline
            $31$ &  \answer{$1\,1111_2$} \\
          \hline
            $32$ & \answer{$10\,0000_2$} \\
          \hline
            $33$ & \answer{$10\,0001_2$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Binär} \\
          \hline
            $128$ &      \answer{$1000\,0000_2$} \\
          \hline
            $256$ &   \answer{$1\,0000\,0000_2$} \\
          \hline
            $512$ &  \answer{$10\,0000\,0000_2$} \\
          \hline
            $1024$ & \answer{$100\,0000\,0000_2$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}

    % ---------------------------------------------------------------------------
    {\bf \question Rechnen Sie die Binärzahlen ins Dezimalsystem um. Erkennen
      Sie ein Muster?}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Binär} & \textbf{Dezimal} \\
          \hline
            $1_2$ & \answer{$1$} \\
          \hline
            $10_2$ & \answer{$2$} \\
          \hline
            $100_2$ & \answer{$4$} \\
          \hline
            $1000_2$ & \answer{$8$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Binär} & \textbf{Dezimal} \\
          \hline
            $1001_2$ & \answer{$9$} \\
          \hline
            $1\,0001_2$ & \answer{$17$} \\
          \hline
            $10\,0001_2$ & \answer{$33$} \\
          \hline
            $100\,0001_2$ & \answer{$65$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Binär} & \textbf{Dezimal} \\
          \hline
            $10\,1010_2$ & \answer{$42$} \\
          \hline
            $10\,1011_2$ & \answer{$43$} \\
          \hline
            $10\,1100_2$ & \answer{$44$} \\
          \hline
            $10\,1101_2$ & \answer{$45$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}

    % --------------------------------------------------------------------------
    {\bf \question Rechnen Sie die Dezimalzahlen ins Binärsystem um.}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Binär} \\
          \hline
            $12$ & \answer{$1100_2$} \\
          \hline
            $28$ & \answer{$1\,1100_2$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Binär} \\
          \hline
            $38$ & \answer{$10\,0110_2$} \\
          \hline
            $136$ & \answer{$1000\,1000_2$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Binär} \\
          \hline
            $199$ & \answer{$1100\,0111_2$} \\
          \hline
            $254$ & \answer{$1111\,1110_2$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}

    % --------------------------------------------------------------------------
    {\bf \question Rechnen Sie die Binärzahlen ins Dezimalsystem um.}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.4\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Binär} & \textbf{Dezimal} \\
          \hline
            $0010\,0001_2$ & \answer{$32+1=33$} \\
          \hline
            $0001\,1010_2$ & \answer{$16+8+2=26$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.5\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Binär} & \textbf{Dezimal} \\
          \hline
            $1110\,0101_2$ & \answer{$128+64+32+4+1=229$} \\
          \hline
            $1101\,0110_2$ & \answer{$128+64+16+4+2=214$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}

    % --------------------------------------------------------------------------
    {\bf \question Welches ist die grösste natürliche Zahl, welche mit den folgenden Anzahl Bit dargestellt werden kann?}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.45\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Anzahl Bit} & \textbf{grösste Zahl} \\
          \hline
            $4$ & \answer{$2^4-1 = 15$} \\
          \hline
            $8$ & \answer{$2^8-1 = 255$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.45\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Anzahl Bit} & \textbf{grösste Zahl} \\
          \hline
            $16$ & \answer{$2^{16}-1 = 65\,535$} \\
          \hline
            $32$ & \answer{$2^{32}-1 = 4\,294\,967\,295$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}

    % --------------------------------------------------------------------------
    {\bf \question Rechnen Sie die Dezimalzahlen ins Hexadezimalsystem um. Erkennen
      Sie ein Muster?}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Hexadezimal} \\
          \hline
            $9$ &   \answer{$9_{16}$} \\
          \hline
            $10$ &  \answer{$A_{16}$} \\
          \hline
            $11$ &  \answer{$B_{16}$} \\
          \hline
            $12$ &  \answer{$C_{16}$} \\
          \hline
       \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Hexadezimal} \\
          \hline
            $13$ &  \answer{$D_{16}$} \\
          \hline
            $14$ &  \answer{$E_{16}$} \\
          \hline
            $15$ &  \answer{$F_{16}$} \\
          \hline
            $16$ & \answer{$10_{16}$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Dezimal} & \textbf{Hexadezimal} \\
          \hline
            $30$ & \answer{$1E_{16}$} \\
          \hline
            $31$ & \answer{$1F_{16}$} \\
          \hline
            $32$ & \answer{$20_{16}$} \\
          \hline
            $33$ & \answer{$21_{16}$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}

    % --------------------------------------------------------------------------
    {\bf \question Rechnen Sie die Hexadezimalzahlen ins Dezimalsystem um. Erkennen
      Sie ein Muster?}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Hexadezimal} & \textbf{Dezimal} \\
          \hline
            $1A_{16}$ &   \answer{$26$} \\
          \hline
            $2A_{16}$ &  \answer{$42$} \\
          \hline
            $3A_{16}$ &  \answer{$58$} \\
          \hline
            $4A_{16}$ &  \answer{$74$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Hexadezimal} & \textbf{Dezimal} \\
          \hline
            $FC_{16}$ &  \answer{$252$} \\
          \hline
            $FD_{16}$ &  \answer{$253$} \\
          \hline
            $FE_{16}$ &  \answer{$254$} \\
          \hline
            $FF_{16}$ & \answer{$255$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Hexadezimal} & \textbf{Dezimal} \\
          \hline
            $10_{16}$ & \answer{$16$} \\
          \hline
            $20_{16}$ & \answer{$32$} \\
          \hline
            $30_{16}$ & \answer{$48$} \\
          \hline
            $40_{16}$ & \answer{$64$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}

    % --------------------------------------------------------------------------
    {\bf \question Rechnen Sie Zahlen zwischen Hexadezimal- und Binärsystem um.}
    \begin{figure}[H]
      \centering
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
          \textbf{Hex.} & \textbf{Binär} \\
          \hline
            $7_{16}$ & \answer{$0111_2$} \\
          \hline
            \answer{$9_{16}$} & $1001_2$ \\
          \hline
            $C_{16}$ & \answer{$1100_2$} \\
          \hline
            \answer{$F_{16}$} & $1111_2$ \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Hex.} & \textbf{Binär} \\
          \hline
            $\answer{BA_{16}}$ & $1011\,1010_2$ \\
          \hline
            $\answer{92_{16}}$ & $1001\,0010_2$ \\
          \hline
            $\answer{CC_{16}}$ & $1100\,1100_2$ \\
          \hline
            $\answer{66_{16}}$ & $0110\,0110_2$ \\
          \hline
        \end{tabularx}
      \end{subfigure}
      \begin{subfigure}{0.3\textwidth}
        \begin{tabularx}{\textwidth}{|r|R|}
          \hline
            \textbf{Hex.} & \textbf{Binär} \\
          \hline
            $DA_{16}$ & \answer{$1101\,1010_2$} \\
          \hline
            $BA_{16}$ & \answer{$1011\,1010_2$} \\
          \hline
            $81_{16}$ & \answer{$1000\,0001_2$} \\
          \hline
            $92_{16}$ & \answer{$1001\,0010_2$} \\
          \hline
        \end{tabularx}
      \end{subfigure}
    \end{figure}
  \end{questions}
\end{document}
