Ch. 1 Data Storage – Part 2

ASCII-7

•In the early days, a ______was used, with ______of 0’s and 1’s, enough for a typical keyboard.

•The standard was developed by ______(American Standard Code for Information Interchange)

•Each group of 7 bits was mapped to a single keyboard character.

Byte = ______

•More common: 8 bits = 1 byte

•Abbreviation: ____

1 byte (B)

Kilobyte (KB) = 1,024 bytes (210)

•“one ______bytes”

1,024 = 2 * 2 * 2 * 2 * 2 * 2 * 2 * 2 * 2 * 2

Megabyte (MB) = 1,048,576 bytes (220)

•“one ______bytes”

Gigabyte (GB) = 1,073,741,824 bytes (230)

•“one ______bytes”

ASCII-8

•IBM later extended the standard, using 8 ______

•This was known as ______

•This gave ______unique combinations of 0’s and 1’s.

Unicode

•Although ASCII works fine for English, many other languages need more than 256 characters, including numbers and punctuation.

•Unicode uses a 16 bit representation, with 65,536 possible symbols.

•Unicode can handle all languages.

Non-text Files:
Representing Images and Sound

Pixels

•A monitors screen is divided into a grid of small unit called picture elements or pixels.

•Each Color intensity of red, green and blue represented as a quantity from 0 through 255.

•Higher the number the more intense the color.

•Black has no intensity or no color and has the value (0, 0, 0)

•White is full intensity and has the value (255, 255, 255)

•Between these extremes is a whole range of colors and intensities.

•Grey is somewhere in between (127, 127, 127)

First a word about Pixels Per Inch

•PPI stands for pixels per inch.

•PPI is a measurement of image resolution that defines the ______.

•An image that is 1600 by 1200 pixels at 300ppi will print at a size of 5.3 by 4 inches.

•Or it could be printed at 180 ppi for a printed size of 8.89 by 6.67 inches.

•The ______. you will get--but only up to a point.

•______is generally considered the

______when it comes to ink jet printing of digital photos.

•The higher the PPI value, the better quality print you will get--but only up to a point.

•“True color” systems require 3 bytes or 24 bits per pixel.

•There is 8 bit and 16 bit color, which gives you less of a color palette.

•An 8 inch by 10 inch image scanned in at 300 pixels per inch:

–8 x 300 = 2,400 pixels 10 x 300 = 3,000 pixels

–2,400 pixels by 3,000 pixels = 7,200,000 pixels or 7.2 megapixels

–At 24 bits per pixel (7,200,000 x 24)

•= 172,800,000 bits or 21,600,000 bytes (21.6 megabytes)

RAM memory, video memory, disk space, bandwidth,…

File Compression

•Typical computer screen only has about 100 pixels per inch, not 300.

•Images still require a lot of memory and disk space, not to mention transferring images over the network or Internet.

•______– A means to change the representation to use fewer bits to store or transmit information.

•Information sent via a fax is either black or white, long strings of 0’s or long strings of 1’s.

Run-length encoding

•Many fax machines use run-length encoding.

•______uses binary numbers to specify how long the first sequence (run) of 0’s is, then how long the following sequence of 1’s is, then how long the following sequence of 0’s is, and so on.

•0-100 1-373 0-96 etc.

•Fewer bits needed than sending 100 0’s, then 373 1’s etc.

•Run-length encoding is a ______, meaning that the original representation of 0’s and 1’s can be reconstructed exactly.

JPEG Compression

•JPEG – Joint Photographic Experts Group

•JPEG is a______

•Our eyes are not very sensitive to small changes in hue (chrominance), but we are sensitive to brightness (luminance).

•This means we can store less accurate description of the hue of the picture (fewer bits) and our eyes will not notice it.

•This is a lossy compression scheme, because we have lost some the original representation of the image and it cannot be reconstructed exactly.

•With JPEG we can get ______or more, without being able to see a difference.

•There are ______in pictures that can be lumped together without our noticing.

•Because of this, when Run-length compression is used there is more compression because there is less variations in the hue.

MPEG Compression Scheme

•MPEG (Motion Pictures Experts Group)

•MPEG compression is similar to JPEG, but applied to movies.

–JPEG compression is applied to each frame.

–Then interframe coherency is used, which only records and transmits the “differences” between frames.

Hexadecimal Number System

•With web applications like HTML (Hypertext Markup Language), colors are sometime

described using their RGB color specification in ______.

•All digits______

•A Base-n number system has n number of digits:

–Decimal: Base-10 has 10 digits

–Binary: Base-2 has 2 digits

Hexadecimal: Base-16 has ______

•The first column is always the number of 1’s

•Each of the following columns is n times the previous column (n = Base-n)

Base 10: 10,000 1,000 100 10 1

Base 2: 16 8 4 2 1

–Base 16: 65,536 4,096 256 16 1

Why Hexadecimal?

•Hexadecimal is perfect for matching 4 bits.

•Every combination of 4 bits can be matched with one hex number.

•______can be represented by ______

•______can be represented by ______

Red Green Blue

Decimal 0 0 255

Hexadecimal______

Binary______

Red Green Blue

Decimal 200 48 127

Hexadecimal______

Binary______

Red Green Blue

Decimal 74 132 40

Hexadecimal______

Binary______

Red Green Blue

Decimal 255 255 255

Hexadecimal______

Binary______

Red Green Blue

Decimal 50 128 60

Hexadecimal______

Binary______

Digitizing Sound

•Many definitions of analog.

•(Our definition)______is a wave form analogous to the human voice.

•The telephone systems uses an analog wave to transmit your voice over the telephone line to their Central Office.

•Two parts of the wave:

–Amplitude – ______of the wave which equates to volume.

–Frequency – ______per second, which equates to pitch.

•Computers are digital devices, so the analog wave needs to be converted to a digital format.

•Converting Analog to Digital requires three steps:

1. ______

2. ______

3. ______

•Sampling – ______.

•The more samples you take, the more accurately you represent the original wave, and the more accurately you can reproduce the original wave.

•Quantifying – This is the process of giving a value to each of the samples taken.

•The larger the range of numbers, the more detailed or specific you can be in your quantifying.

•Coding – This is the process taking the value quantified and representing it as a binary number.

•Audio CDs use ______for coding.

•16 bits gives a range from ______.

•Actually:

–15 bits are used for the range of numbers

–1 bit is used for + (positive) or – (negative)

•32,768 positive values and 32,768 negative values

•How many bits does it take to record one minute of digital audio?

•1 minute = ______

•______samples per second

•This equals ______.

•Each sample requires ______bits.

•2,646,000 samples times 16 bits per sample equals ______bits.

•42,336,000 bits times 2 for stereo equals ______for 1 minute of audio.

•84,672,000 bits divided by 8 bits per byte equals 10,584,000 bytes for ______of audio.

(More than ______)

•______of audio equals 635,040,000 bytes or ______(megabytes)!

MP3 Compression

•Compressing digital audio means to reduce the number of bits needed to represent the information.

•There are many sounds, frequencies, that the human ear cannot hear, some too high, some too low.

•These waves can be removed without impacting the quality of the audio.

•MP3 uses this sort of compression for a typical compression ratio of 10:1, so a one

minute of______music takes ______instead of 10 megabytes.

•A key advantage to digital representation of information, images and sounds, is that the

it can be ______without losing a “bit” of the quality.

1