Module 1 – Part 1: Data Storage
Detailed Elaborated Notes (Student-Friendly Version)
Overview
The concept of data storage is fundamental in computer science. Every piece of
information processed by a computer—text, numbers, images, or sound—must be stored
in binary form (0s and 1s). This chapter explores how data is represented, stored, and
managed in a computer system, including memory organization, mass storage, and
encoding techniques.
1.1 Bits and Their Storage
**Bits and Binary Representation**
Computers store and process information as binary digits called bits (0s and 1s). A bit
represents the smallest unit of data and can have only two possible states—typically 0
(off/false) or 1 (on/true). Sequences of bits can represent complex data like characters,
images, or numbers.
**Boolean Operations**
Boolean operations are logical manipulations of true/false values. The three core
operations are: - **AND** – True only if both inputs are true (1 AND 1 = 1). - **OR** – True
if at least one input is true (1 OR 0 = 1). - **XOR (Exclusive OR)** – True only if one input
is true but not both. - **NOT** – Inverts the input (NOT 1 = 0).
**Gates and Flip-Flops**
Logic gates are physical circuits that implement Boolean operations. They are the building
blocks of digital circuits. A **flip-flop** is a simple circuit that can store one bit of data—it
holds its value (0 or 1) until changed by an input signal. Millions of flip-flops can be
fabricated on a single chip using **VLSI (Very Large-Scale Integration)**.
**Hexadecimal Notation**
Binary patterns can become lengthy and hard to read. **Hexadecimal notation (base 16)**
simplifies this by representing four bits as one symbol (0–9, A–F). For example, binary
10110101 becomes **B5** in hexadecimal. This system is widely used in programming
and debugging.
1.2 Main Memory
Main memory, also known as **primary storage**, temporarily holds data and instructions
that the CPU is currently using. It is composed of tiny storage units called **memory
cells**, each capable of storing one byte (8 bits).
**Memory Organization**
Each memory cell has a unique numeric address, much like house numbers on a street.
Cells are accessed using these addresses for reading and writing operations. This
organization allows **random access**, meaning any cell can be accessed
directly—hence the name **RAM (Random Access Memory)**.
**Types of RAM**
- **DRAM (Dynamic RAM)** – Stores bits as electrical charges that need to be refreshed
constantly. - **SDRAM (Synchronous DRAM)** – An improved DRAM that synchronizes
with the system clock for faster access.
**Measuring Memory Capacity**
Memory size is measured in powers of two. Key units include: - 1 KB = 1024 bytes - 1 MB
= 1024 KB - 1 GB = 1024 MB - 1 TB = 1024 GB Note: In computing, kilo-, mega-, and
giga- often mean powers of two, not powers of ten as in metric measurements.
1.3 Mass Storage
Because RAM is volatile (data is lost when power is off), computers rely on **mass
storage** devices for long-term data retention. Common types include:
1. **Magnetic Storage (Hard Disks, Tapes)** – Data stored magnetically on spinning
platters. Key terms: *track*, *sector*, *seek time*, *latency*. 2. **Optical Storage (CD,
DVD, Blu-ray)** – Data stored as pits and lands on reflective disks read by a laser beam.
3. **Flash Memory (USB, SSD, SD Cards)** – Non-volatile, solid-state storage with no
moving parts. Faster, shock-resistant, and ideal for portable devices.
**Key Performance Metrics:** - Seek Time – Time to locate a track. - Latency – Delay
waiting for rotation. - Transfer Rate – Speed of data movement.
1.4 Representing Information as Bit Patterns
All data—text, numbers, images, and sound—must be represented as bit patterns.
**Representing Text**
Early computers used **ASCII (American Standard Code for Information Interchange)**, a
7-bit code, to represent English letters, digits, and symbols. Later, **Unicode** was
developed to represent characters from all major languages using up to 32 bits per
character.
**Representing Numbers**
Binary notation stores numbers efficiently using base 2 digits. Integers use **two’s
complement** for positive and negative values, while fractions use **floating-point
notation** to represent real numbers with decimals.
**Representing Images**
Images are represented as **bitmaps**—grids of pixels, each encoded with color
information (RGB or luminance/chrominance). Alternatively, **vector graphics** use
geometric shapes (lines, curves) for scalable, high-quality images.
**Representing Sound**
Sound waves are converted into digital data through **sampling**, where amplitude values
are recorded at fixed intervals. CD-quality audio uses 44,100 samples per second at 16
bits per sample. **MIDI** encodes musical notes and instrument instructions instead of
sound itself, requiring far less storage.
1.5 The Binary System
Binary is the base-2 number system using only digits 0 and 1. Each position represents a
power of 2 (1, 2, 4, 8, 16, …). Binary arithmetic follows simple rules where 1+1=10 (carry
over). Fractions are represented using binary fractions with radix points.
**Analog vs Digital**
Analog systems store continuous values (e.g., voltage, sound waves), while digital
systems store discrete values (bits). Digital storage is more accurate and less prone to
noise, making it ideal for computers, audio, and video technology.
**Key Takeaways**
- All data is stored as binary bit patterns. - Memory is organized in bytes and addressed for
quick access. - Mass storage ensures long-term retention. - Text, images, sound, and
numbers use unique encoding methods. - Binary arithmetic forms the basis of computer
computation.
Glossary of Key Terms
- **Bit**: The smallest unit of data (0 or 1). - **Byte**: 8 bits; basic unit of memory. -
**Boolean Logic**: Logical operations (AND, OR, NOT, XOR). - **Flip-Flop**: Basic
memory circuit storing one bit. - **RAM**: Volatile memory used for temporary storage. -
**Hexadecimal**: Base 16 number system for compact binary representation. -
**ASCII/Unicode**: Standards for encoding text. - **Bitmap**: Pixel-based image
representation. - **MIDI**: Digital music encoding standard. - **Binary System**: Number
system using 0 and 1 only.