SlideShare a Scribd company logo
1 of 55
Download to read offline
DATA STORAGE
Chapter 1
1.1 BITS AND THEIR STORAGE
Data Storage1-2
BITS AND BIT PATTERNS
 Bit: Binary Digit (0 or 1)
 Bit Patterns are used to represent
information.
 Numbers
 Text characters
 Images
 Sound
 And others
1-3
BOOLEAN OPERATIONS
 Boolean Operation: An operation that manipulates
one or more true/false values
 Specific operations
 AND
 OR
 XOR (exclusive or)
 NOT
1-4
THE BOOLEAN OPERATIONS AND, OR, AND XOR
(EXCLUSIVE OR)
1-5
GATES
 Gate: A device that computes a Boolean operation
 Often implemented as (small) electronic circuits
 Provide the building blocks from which computers are
constructed
 VLSI (Very Large Scale Integration)
1-6
A PICTORIAL REPRESENTATION OF AND, OR, XOR, AND NOT
GATES AS WELL AS THEIR INPUT AND OUTPUT VALUES
1-7
FLIP-FLOPS
 Flip-flop: A circuit built from gates that can store one bit.
 One input line is used to set its stored value to 1
 One input line is used to set its stored value to 0
 While both input lines are 0, the most recently stored value is
preserved
1-8
A SIMPLE FLIP-FLOP CIRCUIT
1-9
1.2 MAIN MEMORY
Data Storage1-10
MAIN MEMORY CELLS
 Cell: A unit of main memory (typically 8 bits
which is one byte)
 Most significant bit: the bit at the left (high-order) end
of the conceptual row of bits in a memory cell
 Least significant bit: the bit at the right (low-order) end
of the conceptual row of bits in a memory cell
1-11
THE ORGANIZATION OF A BYTE-SIZE MEMORY CELL
1-12
MAIN MEMORY ADDRESSES
 Address: A “name” that uniquely identifies
one cell in the computer’s main memory
 The names are actually numbers.
 These numbers are assigned consecutively starting at
zero.
 Numbering the cells in this manner associates an order
with the memory cells.
1-13
MEMORY CELLS ARRANGED BY ADDRESS
1-14
MEASURING MEMORY CAPACITY
 Kilobyte: 210 bytes = 1024 bytes
 Example: 3 KB = 3 times1024 bytes
 Sometimes “kibi” rather than “kilo”
 Megabyte: 220 bytes = 1,048,576 bytes
 Example: 3 MB = 3 times 1,048,576 bytes
 Sometimes “megi” rather than “mega”
 Gigabyte: 230 bytes = 1,073,741,824 bytes
 Example: 3 GB = 3 times 1,073,741,824 bytes
 Sometimes “gigi” rather than “giga”
1-15
1.3 MASS STORAGE
Data Storage1-16
MASS STORAGE
 On-line versus off-line
 Typically larger than main memory
 Typically less volatile than main memory
 Typically slower than main memory
1-17
MASS STORAGE SYSTEMS
 Magnetic Systems
 Disk
 Tape (all but obsolete)
 Optical Systems
 CD
 DVD
 Blu-Ray
 Flash Drives
 Solid State Drives (SSDs)
1-18
MAGNETIC DISKS
1-19
GAP BETWEEN HEAD AND PLATTER
1-20
Head
Smoke
Particle
Human
Hair
Dust
Particle
DISK PERFORMANCE
1-21
Disk
Performance
Seek time
Rotational
latency
Transfer
rate
OPTICAL DISKS
1-22
CD AND DVD TRACK COMPARISON
1-23
CD DVD
FILES
 A file is a named collection of bits
 Files are often stored in pieces
 1 byte chunks in memory
 Sector-sized chunks on disk
1-24
1.4 REPRESENTING INFORMATION AS BIT
PATTERNS
Data Storage1-26
REPRESENTING TEXT
 Each character (letter, punctuation, etc.) is
assigned a unique bit pattern
 ASCII
 American Standard Code for Information Interchange
 Uses patterns of 7-bits to represent most symbols used in
written English text
 128 (27) unique characters
 Unicode
 Uses patterns of 16-bits to represent the major symbols used
in languages world side
 65,536 (216) possible characters
 ISO
 International Organization for Standardization
 4,294,967,296 (232) possible characters
1-27
“HELLO.” IN ASCII
1-28
REPRESENTING NUMERIC VALUES
 Binary: a number system using only the digits 0
(zero) and 1 (one)
 Maps well to the internal characteristics of the
computer
 Limitations of computer representations of numeric
values
 Overflow: happens when a value is too big to be
represented
 Truncation: happens when a value is between two
representable values
1-32
REPRESENTING IMAGES
1-33
 Bit map techniques
 Pixel: short for “picture
element”
 RGB
 Luminance and
chrominance
 Vector techniques
 Scalable
 TrueType and
PostScript
SCALABLE VS. BITMAPPED FONTS
1-34
A SOUND WAVE REPRESENTED BY THE SEQUENCE 0,
1.5, 2.0, 1.5, 2.0, 3.0, 4.0, 3.0, 0
1-35
1.5 THE BINARY SYSTEM
Data Storage1-36
THE BASE TEN AND BINARY SYSTEMS
1-37
DECODING THE BINARY REPRESENTATION 100101
1-38
FINDING THE BINARY REPRESENTATION OF 13
1-39
BINARY ADDITION
1-40
DECODING THE BINARY REPRESENTATION 101.101
1-41
1-42
There are 10 kinds of people in
the world: those who understand
binary and those who don’t.
HEXADECIMAL NOTATION
 Hexadecimal notation: A shorthand notation for long
bit patterns
 Divides a pattern into groups of four bits each
 Represents each group by a single symbol
 Example: 1010 0011 becomes A3
1-43
THE HEXADECIMAL CODING SYSTEM
1-44
1-45
How many people can read hex
if only you and DEAD people
can read hex? 57,006
1.6 STORING INTEGERS
Data Storage1-46
STORING INTEGERS
 Two’s complement notation: The most popular
means of representing integer values
 Excess notation: Another means of representing
integer values
 Both can suffer from overflow errors.
1-47
TWO’S COMPLEMENT
1-48
 Fixed number of bits
 MSB is sign bit
 1 = negative
 0 = positive
ENCODING IN TWO’S COMPLEMENT NOTATION
1-49
ADDITION AND SUBTRACTION USING TWO’S
COMPLEMENT
1-50
TAKING ISSUE WITH THE BOOK
“The point is that computers
can make mistakes.”
-J. Glenn Brookshear, Computer Science, an Overview, p. 54
1-51
WRONG
TAKING ISSUE WITH THE BOOK
Computers don’t make
mistakes. They do exactly
what you tell them to.
1-61
EXCESS NOTATION
 Another system of representing signed integers
1. List all bit patterns of a given length
2. Find the first bit pattern with a 1 in the MSB; this will
represent zero
3. Patterns below our zero represent negative number,
patterns preceding it represent positive numbers
1-62
EXCESS EIGHT CONVERSION TABLE
1-63
1.7 STORING FRACTIONS
Data Storage1-64
STORING FRACTIONS
 Floating-point Notation: Consists of a sign bit, a
mantissa field, and an exponent field.
 Related topics include
 Normalized form
 Truncation errors
1-65
FLOATING-POINT NOTATION COMPONENTS
1-66
ENCODING THE VALUE 25⁄8
1-67

More Related Content

What's hot

Topic 1 Data Representation
Topic 1 Data RepresentationTopic 1 Data Representation
Topic 1 Data Representation
ekul
 
Computers numbering systems
Computers   numbering systemsComputers   numbering systems
Computers numbering systems
sld1950
 
Data Representation
Data RepresentationData Representation
Data Representation
Rick Jamil
 

What's hot (20)

Topic 1 Data Representation
Topic 1 Data RepresentationTopic 1 Data Representation
Topic 1 Data Representation
 
Addressability
AddressabilityAddressability
Addressability
 
Data representation
 Data representation Data representation
Data representation
 
Number system
Number system Number system
Number system
 
09 Tait
09 Tait09 Tait
09 Tait
 
Int Cs Rev
Int Cs RevInt Cs Rev
Int Cs Rev
 
Binary System by Bray Avila
Binary System by Bray AvilaBinary System by Bray Avila
Binary System by Bray Avila
 
Binary number
Binary numberBinary number
Binary number
 
Binary number system (part 1)
Binary number system (part 1)Binary number system (part 1)
Binary number system (part 1)
 
Data representation in computers
Data representation in computersData representation in computers
Data representation in computers
 
CSC103 Bits, Bytes & Binary
CSC103 Bits, Bytes & BinaryCSC103 Bits, Bytes & Binary
CSC103 Bits, Bytes & Binary
 
1.1.1 BINARY SYSTEM
1.1.1 BINARY SYSTEM1.1.1 BINARY SYSTEM
1.1.1 BINARY SYSTEM
 
Binary, Decimal and Hexadecimal
Binary, Decimal and HexadecimalBinary, Decimal and Hexadecimal
Binary, Decimal and Hexadecimal
 
Computers numbering systems
Computers   numbering systemsComputers   numbering systems
Computers numbering systems
 
As Level Computer Science Book -1
As Level Computer Science  Book -1As Level Computer Science  Book -1
As Level Computer Science Book -1
 
Data representation
Data representationData representation
Data representation
 
Data Representation
Data RepresentationData Representation
Data Representation
 
Data Representation
Data RepresentationData Representation
Data Representation
 
Number system
Number systemNumber system
Number system
 
خاص Binary
خاص Binaryخاص Binary
خاص Binary
 

Similar to Cs160 chapter 1

LIS3353 SP 12 Week 2a
LIS3353 SP 12 Week 2aLIS3353 SP 12 Week 2a
LIS3353 SP 12 Week 2a
Amanda Case
 
Computer Lecture 3
Computer  Lecture 3Computer  Lecture 3
Computer Lecture 3
Moiz Barry
 
Ap Power Point Chpt1
Ap Power Point Chpt1Ap Power Point Chpt1
Ap Power Point Chpt1
dplunkett
 
Learning&Teaching Systems Ppt
Learning&Teaching Systems PptLearning&Teaching Systems Ppt
Learning&Teaching Systems Ppt
ekul
 
Learning& Teaching Systems Ppt
Learning& Teaching  Systems PptLearning& Teaching  Systems Ppt
Learning& Teaching Systems Ppt
Naruin
 
Learning&Teaching Systems Ppt
Learning&Teaching Systems PptLearning&Teaching Systems Ppt
Learning&Teaching Systems Ppt
Kyle
 
Introduction to programming concepts
Introduction to programming conceptsIntroduction to programming concepts
Introduction to programming concepts
hermiraguilar
 

Similar to Cs160 chapter 1 (20)

Chapter 2
Chapter 2Chapter 2
Chapter 2
 
CST-20363-Session 1-In the Bitginning
CST-20363-Session 1-In the BitginningCST-20363-Session 1-In the Bitginning
CST-20363-Session 1-In the Bitginning
 
Basics of Computer For Begginers
Basics of Computer For BegginersBasics of Computer For Begginers
Basics of Computer For Begginers
 
Class2
Class2Class2
Class2
 
Session01_Intro.pdf
Session01_Intro.pdfSession01_Intro.pdf
Session01_Intro.pdf
 
1.1.1 binary systems By Zak
1.1.1 binary systems By Zak1.1.1 binary systems By Zak
1.1.1 binary systems By Zak
 
LIS3353 SP 12 Week 2a
LIS3353 SP 12 Week 2aLIS3353 SP 12 Week 2a
LIS3353 SP 12 Week 2a
 
Computer Lecture 3
Computer  Lecture 3Computer  Lecture 3
Computer Lecture 3
 
COMPUTER FUNDAMENTALS PPT.pptx
COMPUTER FUNDAMENTALS PPT.pptxCOMPUTER FUNDAMENTALS PPT.pptx
COMPUTER FUNDAMENTALS PPT.pptx
 
Coa presentation1
Coa presentation1Coa presentation1
Coa presentation1
 
Cs ch01
Cs ch01Cs ch01
Cs ch01
 
Database Sizing
Database SizingDatabase Sizing
Database Sizing
 
Humming code error detector 7_communications.ppt
Humming code error detector 7_communications.pptHumming code error detector 7_communications.ppt
Humming code error detector 7_communications.ppt
 
Ap Power Point Chpt1
Ap Power Point Chpt1Ap Power Point Chpt1
Ap Power Point Chpt1
 
Learning&Teaching Systems Ppt
Learning&Teaching Systems PptLearning&Teaching Systems Ppt
Learning&Teaching Systems Ppt
 
Learning& Teaching Systems Ppt
Learning& Teaching  Systems PptLearning& Teaching  Systems Ppt
Learning& Teaching Systems Ppt
 
Learning&Teaching Systems Ppt
Learning&Teaching Systems PptLearning&Teaching Systems Ppt
Learning&Teaching Systems Ppt
 
Computer Systems
Computer SystemsComputer Systems
Computer Systems
 
New Computer Systems
New Computer SystemsNew Computer Systems
New Computer Systems
 
Introduction to programming concepts
Introduction to programming conceptsIntroduction to programming concepts
Introduction to programming concepts
 

Recently uploaded

Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
AnaAcapella
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
QucHHunhnh
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
heathfieldcps1
 

Recently uploaded (20)

UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdfUGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
UGC NET Paper 1 Mathematical Reasoning & Aptitude.pdf
 
Unit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptxUnit-V; Pricing (Pharma Marketing Management).pptx
Unit-V; Pricing (Pharma Marketing Management).pptx
 
Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024Mehran University Newsletter Vol-X, Issue-I, 2024
Mehran University Newsletter Vol-X, Issue-I, 2024
 
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17  How to Extend Models Using Mixin ClassesMixin Classes in Odoo 17  How to Extend Models Using Mixin Classes
Mixin Classes in Odoo 17 How to Extend Models Using Mixin Classes
 
Third Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptxThird Battle of Panipat detailed notes.pptx
Third Battle of Panipat detailed notes.pptx
 
Sociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning ExhibitSociology 101 Demonstration of Learning Exhibit
Sociology 101 Demonstration of Learning Exhibit
 
ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701ComPTIA Overview | Comptia Security+ Book SY0-701
ComPTIA Overview | Comptia Security+ Book SY0-701
 
Key note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdfKey note speaker Neum_Admir Softic_ENG.pdf
Key note speaker Neum_Admir Softic_ENG.pdf
 
ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.ICT role in 21st century education and it's challenges.
ICT role in 21st century education and it's challenges.
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
Python Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docxPython Notes for mca i year students osmania university.docx
Python Notes for mca i year students osmania university.docx
 
Spellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please PractiseSpellings Wk 3 English CAPS CARES Please Practise
Spellings Wk 3 English CAPS CARES Please Practise
 
Spatium Project Simulation student brief
Spatium Project Simulation student briefSpatium Project Simulation student brief
Spatium Project Simulation student brief
 
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
2024-NATIONAL-LEARNING-CAMP-AND-OTHER.pptx
 
1029-Danh muc Sach Giao Khoa khoi 6.pdf
1029-Danh muc Sach Giao Khoa khoi  6.pdf1029-Danh muc Sach Giao Khoa khoi  6.pdf
1029-Danh muc Sach Giao Khoa khoi 6.pdf
 
Holdier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdfHoldier Curriculum Vitae (April 2024).pdf
Holdier Curriculum Vitae (April 2024).pdf
 
PROCESS RECORDING FORMAT.docx
PROCESS      RECORDING        FORMAT.docxPROCESS      RECORDING        FORMAT.docx
PROCESS RECORDING FORMAT.docx
 
General Principles of Intellectual Property: Concepts of Intellectual Proper...
General Principles of Intellectual Property: Concepts of Intellectual  Proper...General Principles of Intellectual Property: Concepts of Intellectual  Proper...
General Principles of Intellectual Property: Concepts of Intellectual Proper...
 
Introduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The BasicsIntroduction to Nonprofit Accounting: The Basics
Introduction to Nonprofit Accounting: The Basics
 
The basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptxThe basics of sentences session 3pptx.pptx
The basics of sentences session 3pptx.pptx
 

Cs160 chapter 1