Digitizing Letters, Numbers and Objects Using Binary Codes
Digitizing Letters, Numbers and Objects Using Binary Codes
2 Data is a text and numerical values Information is refined form of actual data
Orange
As an example, consider measuring the weight of an orange. Although the orange could
weigh exactly 200 grams, it might also weigh 229.3 grams or 229.31533 grams or even
229.31533480185993 grams. The weight of an orange is an example of continuous data since
there are an infinite number of possible values that might describe the weight of an orange.
On the other hand, consider asking your friends how many biological parents they have who
are still living. They may respond with the numbers 0 or 1 or 2. Since no person has more
than 2 biological parents, numbers larger than 2 are not possible and it should be obvious that
it is not possible to have a fractional number of living parents. The number of living parents
is an example of discrete data since there are only a finite number of values that describe this
situation. In electronics, a signal may be either analog or digital. An analog signal is an
encoding of continuous data, whereas a digital signal is an encoding of discrete data.
In digital systems, the smallest unit of data is known as a binary digit, or bit. At any point in
time, a bit can only take on one of two possible values: ON or OFF. You can think of a bit as
an extremely small battery that can be very quickly charged or discharged. When charged, the
bit is ON and when discharged, the bit is OFF. Mathematically speaking, a bit is usually
denoted as the value 0 when OFF and the value 1 when ON. Determining whether a bit is ON
or OFF is straightforward. Computing systems encode all information as a sequence of bits.
Pictures, sound, textbooks, and video are encoded as long sequences of bits. A sequence of
bits is commonly referred to as a bit string. Since the bits in the string are able to vary in the
values that they hold, some bits being 1 while other bits are 0, a bit string is able to display a
great number of different patterns. For a single bit (i.e., a bit string of length one), there are
only two patterns that the string could exhibit at any one point in time. The bit could either be
0 or 1. Consider, however, a string of two lightbulbs. How many different patterns could the
string exhibit? Two of the patterns are obvious: both lightbulbs could be 0 or both lightbulbs
could be 1. Two other patterns are also possible. The first light bulb could be 0 and the
second lightbulb could be 1. It is also possible that the first light bulb could be 1 and the
second lightbulb could be 0.
The four patterns that a string of two bits can exhibit are 00, 01, 10, and 11
There are eight patterns that a string of three bits can exhibit
There are eight patterns that a bit string of length three can exhibit at any one point in time.
More specifically, we note that the number of patterns that a bit string of length N can exhibit
is 2N.
1 21 = 2
2 22 = 4
3 23 = 8
4 24 = 16
5 25 = 32
8 28 = 256
N 2N
Coin toss 2 1
Day of week 7 3
Month of Year 12 4
Day of Month 31 5
A word is a fixed-length sequence of bits that are processed as a single item by the
processor. The number of bits in a word varies by computing system but will typically
be a multiple of eight. You may have heard of 32 bit processors or 64 bit systems.
These phrases describe the word-length of a particular computing system. Common
word lengths include 8, 16, 32, and 64. Prefixes are used as multipliers to measure
very large data capacities and the symbol B is used to denote a single byte. The
computing industry uses terms such as kilobyte, megabyte, and gigabyte, and
corresponding symbols KB, MB, and GB as common measures of data capacity.