Optional Lesson: Encoding Numbers in the Real World

Overview

In this lesson, students explore some fascinating stories from the news and history (and the future) about number encodings in computers. These stories should serve to illuminate how the kinds of decisions students have been making about number encodings are the same kinds of things that real scientists in the world have to worry about, sometimes with disastrous consequences. While this lesson has the possibility of running long, it is meant only as a short excursion into real-world application and should be limited to one class period.

Purpose

Determining the number of bits that will be used in each binary number can have a profound impact on computing systems we rely upon. Many older operating systems and protocols for encoding time made use of 32-bit numbers. As computational power and time have both progressed, standards have migrated to larger binary numbers, usually 64-bit, in order to accommodate changing demands of these systems. Moving all members of the computing community over to these new standards can take some time, however, as many users continue to expect to receive and send information using the older 32-bit protocol.

Agenda

Activity

Getting Started

Assessment

Extended Learning

Wrap-up

Readings

View on Code Studio

Objectives

Students will be able to:

  • Discover the different ways number systems have been constructed and used throughout history.
  • Examine real-world issues related to number encodings in computers.

Preparation

  • (Optional) A set of articles about number encoding tailored for your class/students

Links

Heads Up! Please make a copy of any documents you plan to share with students.

For the Teachers

For the Students

Teaching Guide

Activity

Introduction

Students will need to be placed in groups of 2 to 4 people to complete their initial research. Distribute the Activity Guide - Encoding Numbers in the Real World, one copy per student. Assign each group one of the topics -- they can be found on Code Studio as well as below in this lesson guide -- and ask that they complete the top portion of the sheet. Encourage groups to divide up the work and find additional resources if they wish, but ask that everyone finish this initial research session at the same point.

Research

Provide students 15 to 20 minutes to conduct their initial research in groups and complete the top portion of their Activity Guide. Visit groups and encourage them to stay focused on the core ideas of their topic before moving on to understanding more detailed or technical aspects of the topic.

Jigsaw

Students should find three classmates who researched a different article and exchange the information they learned. They should record the key points from each topic in the space provided at the bottom of their Activity Guides.

Teaching Tips

Provide students a hard time limit when conducting research at the beginning of class and consider projecting a countdown timer. Use this constraint to encourage students to divide up their work and focus their attention on the overall topic, rather than specific technical details.

During the Jigsaw, consider providing students with 5- to 8-minute periods during which they can exchange information with a classmate. As before, their job is to cover the key points and make connections to their study of binary numbers.

Getting Started

Goal

Students will spend the majority of today’s lesson independently researching a topic related to real-world number systems. These brief comments serve to contextualize the topics students will see today as part of a broader investigation into the impacts different number systems have upon the way we represent and reason about numbers.

Mini Lecture

Say: Over the past couple of lessons, we have been studying the binary number system, since it can be constructed using only bits, the building blocks of information within a computer. Throughout history, many different number systems have been used to represent numbers. Each number system has its associated pros and cons, and often there are unintended consequences that arise from how those number systems are structured. For today’s activity, you will be researching one of these number systems to further contextualize the ideas we’ve explored for the binary number system.

Assessment

Suggestions

  • Collect the Activity Guide and assess for completeness and optionally for accuracy.
  • Reflection: Choose one of the topics you most enjoyed learning about today. Describe what new information you learned and how it relates to the way we create and use number systems.

Extended Learning

  • Ask students to conduct further research into a topic they found compelling. Use this activity to develop skills students will need to employ for the Explore Performance Task.

Wrap-up

Discussion

Conclude the lesson with a sense-making discussion summarizing the broad themes running through this activity. The key points are that the binary number system, like any number system, has benefits while also imposing limits upon how we represent information. Give particular focus to at least one topic in which selecting a certain width binary number created unforeseen challenges later on. Some conversation starters are listed below. Prompts:

  • Does the way you represent numbers make a difference in the way you think about numbers?
  • How might the way you choose to represent numbers in a computer go wrong? What potential problems might arise from the way you choose to represent numbers?
  • Of all the number systems in the world, why do you think modern computers have settled on binary? Why didn’t someone build a computer that used base 10?
  • List a few rules number encoding systems must follow in order to be useful.
  • Why do you think some number encoding systems are more successful than others?

Readings

Below is a set of readings that address different numbering systems and their uses. Feel free to select some, all, or go find your own sources as well.

View on Code Studio

Student Instructions

Unit 1: Lesson 2 - Sending Binary Messages

Background

One of the most simple forms of communication is the transmission of a binary message. Interestingly enough, "binary" is not a computing term. The word "binary" is used to describe something that can be in one of only two possible states. For example, the question, "Do we have a quiz today?" is a binary question, as there are only two possible responses: "yes" and "no." In fact, any question that can only be answered with a "yes/no" or "true/false" or something along those lines would be considered a binary question. It is also possible to make a question binary by limiting the acceptable responses to two, as in, "Which do you prefer: Coke or Pepsi? Country music or hip hop?"

Vocabulary

  • Binary Question: a question to which there are only two possible answers.
  • Binary Message: a message that can only be one of two possible values.

Lesson

  • Think of a message that can be communicated with such a simple method.
  • Build a device from everyday objects to communicate the message across the room.
  • Work with your teammates in an iterative design process of rapidly building and improving your device.

Resources

View on Code Studio

Student Instructions

View on Code Studio

Student Instructions

Provide an example of a question that could NOT be answered with a binary message. Explain why this is the case making reference to the definition of a binary message.

View on Code Studio

Student Instructions

Recall when you built your binary message sending device. Why did we decide to send a message as a sequence of states (A and B) rather than modifying our devices to represent more states (State C, State D, State E, ...)?

View on Code Studio

Student Instructions

How did collaboration impact the development of your protocol? What challenges did working in a group present and in what ways did it positively impact your final product?

Standards Alignment

View full course alignment

CSTA K-12 Computer Science Standards (2011)

CI - Community, Global, and Ethical Impacts
  • CI.L2:2 - Demonstrate knowledge of changes in information technologies over time and the effects those changes have on education, the workplace and society.
CL - Collaboration
  • CL.L2:3 - Collaborate with peers, experts and others using collaborative practices such as pair programming, working in project teams and participating in-group active learning activities.
CT - Computational Thinking
  • CT.L2:14 - Examine connections between elements of mathematics and computer science including binary numbers, logic, sets and functions.
  • CT.L2:7 - Represent data in a variety of ways including text, sounds, pictures and numbers.
  • CT.L2:8 - Use visual representations of problem states, structures and data (e.g., graphs, charts, network diagrams, flowcharts).
  • CT.L3A:6 - Analyze the representation and trade-offs among various forms of digital information.

Computer Science Principles

2.1 - A variety of abstractions built upon binary sequences can be used to represent all digital data.
2.1.1 - Describe the variety of abstractions used to represent data. [P3]
  • 2.1.1A - Digital data is represented by abstractions at different levels.
  • 2.1.1B - At the lowest level, all digital data are represented by bits.
  • 2.1.1C - At a higher level, bits are grouped to represent abstractions, including but not limited to numbers, characters, and color.
  • 2.1.1D - Number bases, including binary, decimal, and hexadecimal, are used to represent and investigate digital data.
  • 2.1.1E - At one of the lowest levels of abstraction, digital data is represented in binary (base 2) using only combinations of the digits zero and one.
  • 2.1.1F - Hexadecimal (base 16) is used to represent digital data because hexadecimal representation uses fewer digits than binary.
  • 2.1.1G - Numbers can be converted from any base to any other base.
2.1.2 - Explain how binary sequences are used to represent digital data. [P5]
  • 2.1.2A - A finite representation is used to model the infinite mathematical concept of a number.
  • 2.1.2B - In many programming languages, the fixed number of bits used to represent characters or integers limits the range of integer values and mathematical operations; this limitation can result in overflow or other errors.
  • 2.1.2D - The interpretation of a binary sequence depends on how it is used.
  • 2.1.2E - A sequence of bits may represent instructions or data.
  • 2.1.2F - A sequence of bits may represent different types of data in different contexts.