Chapter 7.1 Representing Information Digitally: Binary, Hexadecimal, and Encoding Standards
Fundamental Principles of Digitizing Information
Digitizing Data
Digitizing involves more than just representing letters, numbers, and metadata.
It encompasses various forms of information categorized as multimedia, including photos, audio, and video.
The core principles used to encode letters and numbers into bits are identical to those used for digitizing multimedia.
Digitizing Discrete Information
To digitize is to represent information using digits, which are normally base numerals ranging from to .
The primary advantage of using digits for encoding is that items can be organized in numerical order.
When using symbols other than digits, an ordering system known as a collating sequence is required.
A collating sequence is a universally agreed-upon order of symbols from the smallest to the largest value.
When selecting symbols for encoding, it is essential to consider how those symbols interact with the objects being encoded.
Analog versus Digital Systems
Analog Information
Analog data is continuous in nature.
Examples include sound waves and sound pressure.
In a graph of sound pressure over time, analog information appears as a continuous, undulating wave.
Digital Information
Digital data is discrete, meaning it consists of distinct or separable samples.
Digital information exists in a series of many distinct data points rather than a continuous stream.
Digital information is stored using PandA (Presence and Absence) representation.
All data within a computer system is fundamentally represented in binary.
Converting Analog to Digital Sound
To digitize an analog sound wave, it must be converted into bits.
This is achieved by using binary numbers to record the magnitude of the wave (how far it is above or below the zero line) at specific sampling points on a graph.
Representing Color and Light in Digital Systems
Color Scheme (RGB)
Computer displays use pixels, which are small points of colored light arranged in a grid.
Each pixel is created by combining three primary colored lights: red, green, and blue.
This color model is referred to as RGB.
Encoding Black and White
Black is defined as the total absence of light. In the RGB bit assignment, black is represented by all zero-intensity values:
Red:
Green:
Blue:
Full sequence:
White is defined as the full intensity of red, green, and blue light. The RGB bit assignment for white uses all full-intensity values:
Red:
Green:
Blue:
Full sequence:
The PandA (Presence and Absence) Representation
The Intersection of Physical and Logical Worlds
The most fundamental patterns in IT occur when physical phenomena meet logical concepts.
The basic form of information is the presence or absence of a physical phenomenon, such as:
Is matter in a specific place at a specific time?
Is light detected at a specific place and time?
Is magnetism sensed at a certain spot at a certain time?
The specific intensity (brightness of light or strength of magnetism) is irrelevant; only the detection of the state (presence or absence) matters.
Logical Implementation
Logic, based on the concepts of True and False, is the foundation of both human reasoning and mechanical computing.
By associating "True" with the presence of a phenomenon and "False" with its absence, the physical world is used to implement logical systems, creating information technology.
This association is termed PandA representation.
Characteristics of PandA
PandA is a discrete system, meaning values are distinct and separable.
It is impossible to transform one value into another through tiny gradations; there are no "shades of gray."
Because it relies on only two patterns (present and absent), it is inherently a binary system.
Interpretations of Presence and Absence
| Present | Absent |
| :--- | :--- |
| True | False |
| | |
| On | Off |
| Yes | No |
| | |
| Black | White |
| For | Against |
Units of Representation: The Bit
A bit (a contraction of "binary digit") is the unit of PandA representation.
It represents a specific place in space and time where a phenomenon can be set and detected.
Bit sequences can be interpreted as binary numbers, and groups of bits are used to form symbols.
Bit Storage and Pattern Combinations
Computer Memory Arrangement
Inside a computer, memory is organized as a long sequence of bits where physical phenomena can be set and detected as present or absent.
Sidewalk Memory Analogy: Imagine a sidewalk where each square represents a memory slot (bit). A stone placed on a square represents the value (presence), and an empty square represents the value (absence).
Following this analogy, if a sequence of sidewalk squares is "Stone, No Stone, Stone, No Stone, No Stone, No Stone, Stone, No Stone," the PandA symbol is "PAPA AAPA."
Alternative physical PandA Encodings
Stones on all squares, but using black stones for one state and white for another.
Multiple colored stones per square (e.g., more black than white equals , more white than black equals ).
Positioning: A stone in the center represents one state, while an off-center stone represents the other.
The Binary System and Base 2
Computers use base to represent numbers.
Counting in binary (base ) only uses the digits and . The sequence of counting is:
Eight bits grouped together form a byte.
Calculating Possible symbols
The number of symbols possible from a sequence of bits is calculated as .
| Bits | Symbols |
| :--- | :--- |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
Hexadecimal System
Defining Hexadecimal (Hex)
Hex is short for base .
It uses the decimal digits followed by the first six Latin letters: .
Values of Hex letters: .
Utility of Hex
Binary sequences are long, tedious, and prone to error when written.
Hex is a compact way to represent binary. Each hex digit represents a group of four bits (a nibble).
Example Conversion:
Binary:
Separated Nibbles:
Hex Result:
Digital Storage Size Measurements
Sizes and Capacities
Bit: A single or .
Nibble: bits (represented by hex character).
Byte: bits.
Kilobyte (KB): bytes (approximately one thousand).
Megabyte (MB): bytes (approximately one million).
Gigabyte (GB): bytes (approximately one billion).
Terabyte (TB): bytes (approximately one trillion).
Digitizing Text: ASCII and Unicode
Standard ASCII
American Standard Code for Information Interchange (ASCII).
Originally a -bit code, allowing for symbols.
It includes uppercase and lowercase Roman letters, Arabic numerals, arithmetic characters, punctuation characters (including space), and non-printable control characters (new line, tab, backspace).
A total of printable characters are sufficient for English text.
Extended ASCII
Introduced by IBM in the mid-1960s to handle non-English text.
Uses bits (one byte) per character, allowing for symbols.
The first characters match standard ASCII (with a leading added to the byte). The remaining slots provide room for Western European languages and other special symbols.
Unicode
Created in the 1990s to support numerous languages with different character sets.
Initially used bytes ( bits) to represent over characters ().
It is backward compatible with -bit ASCII (the first characters are the same).
Current standards use more bits to represent over characters in scripts, including ancient scripts like Egyptian hieroglyphics and modern scripts like Kanji, Arabic, Cyrillic, and Hebrew.
ASCII Character Listings (Decimal/Hex/Character)
: NUL | : SOH | : STX | : ETX | : EOT | : ENQ | : ACK
: BEL | : BS | : HT | : NL | : VT | : NP | : CR
: [Space] | : ! | : " | : # | : $ | : % | : &
: | : | : | : | : | : | :
: A | : B | : C | : D | : E | : F
: a | : b | : c | : d | : e | : f
: DEL
Encoding Example: Phone Numbers
A phone number like is stored not as a single large number, but as a string of symbols.
Each digit is encoded with its specific ASCII byte:
is represented as
is represented as
Origin of the Term "Byte"
The term was coined by IBM engineers seeking a word for a quantity of memory between a bit and a "word" (usually bits).
They chose "bite" but changed the spelling to "byte" to prevent engineers from accidentally confusing "bite" with "bit" in documentation or typing errors.