Quiz on Ch · • All electronic signals (both analog and digital) degrade due to absorption in...
Transcript of Quiz on Ch · • All electronic signals (both analog and digital) degrade due to absorption in...
Quiz on Ch.2
Count up six times starting with each number:
• AB3C16
• 1011012
• 12345
Quiz on Ch.2
What is the largest positive integer that can be represented with 7 bits?
Extra-credit QUIZ:
3
Conclusion: We can convert from hex to octal, using binary as a stepping-stone!
4
binary
hexadecimal
octal
Chapter 3
Data Representation
Data compression
Reduction in the amount of space (memory) needed to store or transmit the data
Measured by the Compression ratio = The size of the compressed data divided by the size of the original data
Example: A file of size 200 MB is compressed with the ZIP utility, and its size is 150 MB after compression.
What is the compression ratio?𝟏𝟓𝟎 𝑴𝑩
𝟐𝟎𝟎 𝑴𝑩=
𝟏𝟓
𝟐𝟎=
𝟑
𝟒= 𝟎. 𝟕𝟓 = 𝟕𝟓%
6
QUIZ
Two files are compressed with the ZIP utility:
• One is originally 200 MB, and becomes 150 MB after compression
• The other is originally 15 MB, and 11 MB after compression
Which file is better/more compressed?
7
Solution
Two files are compressed with the ZIP utility:
• One is originally 200 MB, and becomes 150 MB after compression
• The other is originally 15 MB, and 11 MB after compression
8
r1 = 0.75
r2 = 11 MB / 15 MB = 11/15 = 0.733
r2 < r1, so the second file has (slightly) better compression
Quiz
A video file is originally 3.5 GB long.
We compress with a compression ratio of 0.2 (20%).
What is the final size of the file?
9
Solution
A video file is originally 3.5 GB long.
We compress with a compression ratio of 0.2 (20%).
What is the final size of the file?
10
r = 0.2 = 𝑓𝑖𝑛𝑎𝑙 𝑠𝑖𝑧𝑒
𝑖𝑛𝑖𝑡𝑖𝑎𝑙 𝑠𝑖𝑧𝑒
final size = 0.2 x initial size = 0.2 x 3.5 GB = 0.7 GB = 700 MB
Data compression
The Compression ratio is always between 0 and 1
(0% and 100%)
Compression techniques can be
Lossless → the data can be retrieved without any loss of the original information
Lossy → some information may be lost in the process (but it doesn’t matter for the purposes of the intended application)
11
Information can be represented in one of two ways: analog or digital
Analog data
A continuous representation, similar to the actual information it represents
Digital data
A discrete representation, breaking the information up into separate elements
12
Analog vs. Digital
Computers cannot work well with analog data, so we digitize the data
Digitizing = Breaking data into pieces and representing those pieces separately, by using a finite number of binary digits
There are two operations performed:
• one in time (a.k.a. sampling)
• the other in amplitude (a.k.a. quantizing)
13
There are two operations performed when digitizing a continuous signal:
• one in time (a.k.a. sampling)
• the other in amplitude (a.k.a. quantizing)
14
Quiz
A digital compass reads the position of a robot 20 times a second.
What is the time elapsed between two consecutive readings?
Is this a sampling error or quantization error?
15
Analog and Digital Information
Why do we use binary to represent digitized data?
• Price: transistors are (now) cheap to produce
–Remember Babbage!
• Reliability: transistors don’t get (easily) jammed
–Remember Babbage!
16
Electronic Signals
Important facts about electronic signals
• An analog signal continually fluctuates up and down
• A digital signal has only a high or low state, corresponding to the two binary digits
17
Figure 3.2
An analog and a digital signal
• All electronic signals (both analog and digital) degrade due to absorption in transmission lines
• The amplitude (voltage) of electronic signals (both analog and digital) fluctuates due to environmental effects, a.k.a. noise
18
Figure 3.3
Degradation of analog and digital signals
The difference is that digital signals can be easily
regenerated!
Binary Representations
One bit can be either 0 or 1
• One bit can represent two things
Two bits can represent four things (Why?)
How many things can three bits represent?
How many things can four bits represent?
19
20
Why does the number of combinations double with
every extra bit?
Conclusions onBinary Representations
How many things can n bits represent?
What happens every time you increase the number of bits by one?
21
QUIZ
A digital thermometer has a scale from 50 to 100 degrees (F). The temperature is represented on 7 bits. What is the smallest temperature difference that it can measure?
Is this a sampling error or quantization error?
22
Solution
A digital thermometer has a scale from 50 to 100 degrees (F). The temperature is represented on 7 bits. What is the smallest temperature difference that it can measure?
7 bits → 27 = 128 values → 127 intervals
(100-50)/127 = 0.394 deg/interval
Is this a sampling error or quantization error?
Quantization, since it’s in the vertical direction (amplitude)23
Beware of the “fencepost error”!
Image source: http://en.wikipedia.org/wiki/Fencepost_error
Similar quiz for individual work
A digital volt-meter has a scale from 0 to 30 volt (V).
The voltage is represented on 9 bits. What is the smallest voltage difference that it can represent?
Is this a sampling error or quantization error?
24
Reversing the problem of Binary Representations
How many things can n bits represent?
How many bits are needed to represent Nthings?
25
Say, all desktops in this lab?
How many bits are needed to represent all 45 desktops in this lab?
The inverse of the power (2n) is the logarithm:
26
What’s wrong with this answer?
Base is 2
How many bits are needed to represent all 45 desktops in this lab?
27
The “ceiling” function returns the next integer that is greater than or equal to its argument!
How many bits are needed to represent all 45 desktops in this lab?
28
Alternative solution:
What’s the smallest power of 2 that is ≥ N?
Computers are multimedia devices, dealing with a vast array of information categories.
Computers store, present, and help us modify many types of data:
• Numbers
• Text
• Audio
• Images and graphics
• Video
• Smell (machine olfaction!)
• Haptics (touch)
• Chess positions
• Etc. etc. etc.
29
Positive integers
Negative integers
Real (various precisions)
Complex
See Ch.2!
3.2 Representing Numeric Data
Negative integers
Signed-magnitude representation
The sign represents the ordering, and the digits represent the magnitude of the number
30
Negative Integers
There is a problem with the sign-magnitude representation: plus zero and minus zero.
• More complex hardware is required!
Solution: Let’s not represent the sign explicitly!
“Complement” representation
31
Ten’s complement
Using two decimal digits, represent 100 numbers
• If unsigned, the range would be 0…?
• Let 1 through 49 represent 1 … 49
• Let 50 through 99 represent -50 … -1
32
Ten’s complement
33
Top: representations (the “label on the jar”)
Bottom: the actual numbers that are being
represented (the “content of the jar”)
QUIZGiven the following representations, find in each case what actual number is being represented:
• 51
• 52
• 96
• 47
34
Top: representations
Bottom: numbers represented
QUIZGiven the following number is being represented, find in each case what is the tens’ complement representation:
• -48
• 47
• 0
• 96
35
Top: representations
Bottom: numbers represented
Quick work for next time:
• Read pp.55-63 of our text
• Solve the quiz on slide 24
• Solve end-of-chapter ex. 1-6, 21, 27-31 in notebook
36EOL1
EXTRA-CREDIT QUIZ
37
QUIZWhat is the representation (top) for each of these actual numbers (bottom)?
• -45
• -40
• -30
• -5
38
Why the “complement” in ten’s complement?
100 – 50 = 50
100 – 49 = 51
……………………..
100 – 1 = 99
In general:
100 – i is the representation of – i
39
Positive number
Negative number
We can use ten’s complement to calculate!
To perform addition, add the numbers and discard any carry
40
Now you try it
48 (signed-magnitude)
- 1
47
How does it work in
the new scheme?
Adding negative numbers:
41
Try these:
4 - 4 -4
- 3 +3 + -3
Important conclusions
In any complement representation:
• Positive and negative numbers are treated the same! We can add without knowing if they’re positive or negative!
• Subtraction is performed as addition, by changing signs: a – b = a + (-b). This greatly simplifies the hardware!
42
43
Two’s Complement
What do you notice
about the left-most bit
(MSB)?
Important: It’s not
sign-magnitude!!
44
QUIZ
John has encountered this two’s
complement number:
1000 0111
He says: The number is negative, b/c
the MSB is one.
The magnitude is just 111, which
means 7.
Therefore the number is -7 in decimal!
Is John correct?
Two’s complement on 4 bits (k = 4)
45
What is:
• The largest positive number?
• The largest negative number?
• -1?
Repeat the questions above for:
• 5 bits (k = 5)
• 6 bits
• 8 bits
• N bits (general N)
Not in text
46
http://xkcd.com/571/
Two’s complement on 16 bits
47
“Signposts” for two’s comp.
0000 0000 means ...
0111 1111 means ...
1000 0000 means ...
1111 1111 means ...
Formula to compute the negative of a number on k digits:
• for ten’s comp: Negative(I) → 10k - I
• for two’s comp: Negative(I) → 2k - I
Practice: find the 8-bit two’s comp. representations:
7
-7
-110
200 (trick question!)
-129 (trick question!)
048
“Fast” two’s complementEasier way to change the sign of a number:
Flip all bits, then add 1
Try it out! Find the negatives of the following
two’s complement numbers:
0000 0011
1000 0000
1000 0001
1000 0011
1001 0110
1111 111149
This is how subtraction is implemented in
computer hardware!A – B = A + (-B)
QUIZ
What is the 8-bit two’s complement representation of these numbers?
• -13
• 40
50
Two’s complement arithmetic
Addition and subtraction are the same as in unsigned:
-127 1000 0001
+ 1 0000 0001
-126 1000 0010
Ignore any Carry out of the MSB:
-1 1111 1111
+
-1 1111 1111
-2 1111 1110
51
QUIZ
Perform the following operation in 8-bit two’s complement:
40 – 13
52
Trick QUIZ
What decimal number does this binary number represent?
1001 1110
53
What happens if the computed value won't fit in the given number of bits k?
Overflow
If k = 8 bits, adding 127 to 3 overflows:1111 1111
+ 0000 0011
10000 0010
… but adding -1 to 3 doesn’t!
54
Conclusions:
Overflow is specific to the representation(unsigned, sign-mag., two’s comp., floating point etc.)
Overflow is something we should always expect (and make provisions for) when mapping an infinite world onto a finite machine!
55
SKIP Representing Real Numbers
56
3.3 Representing Text
Basic idea:There are finite number of characters to represent, so list them all and assign each a (binary) number, a.k.a. code.
Character setA list of characters and the codes used to represent each one
Computer manufacturers (eventually) agreed to standardize
– Read “Character Set Maze” on p.6757
The ASCII Character Set
ASCII = American Standard Code for Information Interchange
ASCII originally used seven bits to represent each character, allowing for 128 unique characters
Later extended ASCII evolved so that all eight bits were used
• How many characters can be represented?
58
7-bit ASCII Character Set
59
QUIZ
Encode “Hello, world!” in ASCII
Decode 67 79 83 67 32 49 51 48 50 from ASCII
The ASCII table is already built into Python!
61
The ASCII Character Set
62
The first 32 characters in the ASCII character chart do not have a simple character representation to print to the screen.
They are called control characters
8-bit (“extended”) ASCII Character Sets
63
By using 8 bits instead of 7, the number of codes extends from 128 to 256.
Extended ASCII is always a superset of 7-bit ASCII:
• The first 128 characters correspond exactly to 7-bit ASCII
Not in text
Problem: Computer vendors couldn’t agree on one set!
Extended ASCII: IBM code page 437
64
http://en.wikipedia.org/wiki/Code_page_437
Not in text
Extended ASCII: Latin-1
65http://en.wikipedia.org/wiki/ISO/IEC_8859-1
Not in text
QUIZ
What do these bits represent?
1101 1110
66
Solution
It depends on what is being represented!
1101 1110
67
Unsigned integer: …
Signed integer (2’s complement): …
IBM 437 character: …
Latin-1 character: …
QUIZ:
Your boss tells you to develop a webpage using the extended ASCII character set. What do you reply?
68
The Unicode Character Set
None of the Extended ASCII character sets were enough for international use (256!)
Unicode uses 16 bits per character
How many characters can UNICODE represent?
Unicode is a superset of Latin-1: The first 256 characters correspond exactly to Latin-1 characters (http://unicode.org/charts/PDF/U0080.pdf )
69
Simplified Chinese has
6500!
Unicode examples
70Figure 3.6 A few characters in the Unicode character set
Text Compression
Sometimes, assigning 8 or 16 bits to each character in a document uses too much memory
We need ways to store and transmit text efficiently
Text compression techniques:– keyword encoding– run-length encoding– Huffman encoding
71
Keyword Encoding
Replace frequently used words with a single character, for example here’s a substitution chart:
72
Keyword EncodingOriginal text:
We hold these truths to be self-evident, that all men are created equal, that they are endowed by their Creator with certain unalienable Rights, that among these are Life, Liberty and the pursuit of Happiness. That to secure these rights, Governments are instituted among Men, deriving their just powers from the consent of the governed, Thatwhenever any Form of Government becomes destructive of these ends, it is the Right of the People to alter or to abolish it, and to institute new Government, laying its foundation on such principles and organizing its powers in such form, as to them shall seem most likely to effect their Safety and Happiness.
73
Encoded text:
We hold # truths to be self-evident, $ all men are created equal, $ ~y are endowed by ~ir Creator with certain unalienable Rights, $ among # are Life, Liberty + ~ pursuit of Happiness. $ to secure # rights, Governments are instituted among Men, deriving ~ir just powers from ~ consent of ~ governed, $ whenever any Form of Government becomes destructive of # ends, it is ~ Right of ~ People to alter or to abolish it, + to institute new Government, laying its foundation on such principles + organizing its powers in such form, ^ to ~m shall seem most likely to effect ~ir Safety + Happiness.
74
Keyword Encoding
How much did we compress?
Original paragraph
656 characters
Encoded paragraph
596 characters
Characters saved
60 characters
Compression ratio
596/656 = 0.9085
75
Could we use this substitution chart for any arbitrary text?
76
QUIZ
A: No, we cannot use it for text that contains the symbols themselves!
Quick work for next time:
• Read pp.64-73 of our text
• Solve again all today’s quizzes
77End week 1
QUIZ
What decimal number does this binary number represent?
1011 0010
78
Perform this addition in 8-bit two’s complement:
8 – 11 =
QUIZ Select all that apply:
The Latin-1 character set:
• Is a 5-bit representation
• Is a 7-bit representation
• Is a 16-bit representation
• Is an extension of ASCII
• Is an extension of Unicode
• Contains letters used in European languages
79
QUIZ Select all that apply:
The Unicode representation:
• Uses 16 bits
• Is an extension of ASCII
• Is an extension of Latin-1
• Is an extension of IBM-437
• Contains letters used in all world languages
• Can accommodate over 65,000 characters
• Is used in the majority of web pages today
80
Run-Length Encoding
A single character may be repeated over and over in a long sequence.
Replace a repeated sequence with – a flag character, followed by
– the repeated character, followed by
– the number of repetitions.
Example:
81
• * is the flag character• b is the repeated character• 8 is the number of times b
is repeated
Run-Length EncodingEncoding example:
Original text is
bbbbbbbbjjjkLLqqqqqq+++++Encoded text is
*b8jjjkLL*q6*+5
Compression ratio: 15/25 = .6
Why isn't LL encoded? Why not jjj?
82
Run-Length Encoding
Decoding example:
Encoded text is
*x4*p4l*k7Original text is
xxxxpppplkkkkkkk
83
QUIZDecode using RLE:
*a4*A4HIJ*Z5
Encode using RLE:
Hummm, Burrrrr, OOOPS!
• In both problems, calculate the compression ratio!
84
Huffman CodesConclusion: each language and each topic have specific frequencies of characters and groups of characters (digraphs, trigraphs etc.)
Why should the characters “X" or "z" take up the same number of bits as "e" or "t"?
Huffman codes use variable-length bit strings to
represent each character. More frequently-used letters
have shorter strings to represent them, and vice-versa!
86
Huffman encoding example
“ballboard” would be1010001001001010110001111011
compression ratio
28/63 (7-bit ASCII)
QUIZ:
Encode “roadbed”
87
Huffman decoding
In Huffman encoding no character's bit string is the prefix of any other character's bit string. Codes with this property are called prefix codes.
To decode
look for match left to right, bit by bit
record letter when the first match is found
continue where you left off, going left to right
88
QUIZ Huffman decoding
89
Decode:
1011111001010
QUIZ Huffman decoding
90
Decode:
1001101111011
EOL3
QUIZ: Decipher the coded text using the Huffman table:
91
0010110101001110100110011011010011000111
01111001110100111
3.4 Representing Audio Data
92
We perceive sound when:
• a series of air waves cause to vibrate a membrane in
our ear (eardrum), which
• is connected to the malleus, incus, and stapes
(hammer, anvil, and stirrup), which
• are connected to the cochlea, which
• sends nerve signals to our brain.
The tricky evolution of the middle ear
93
Not in text
Source of figures: http://en.wikipedia.org/wiki/Evolution_of_mammalian_auditory_ossicles
Correspondence discovered in 1837 (!)
through embriology
The hammer, anvil, and stirrup,
of mammals used to be jaw
bones in reptiles!
… but how could this happen?
Surely an early mammal with an
unhinged jaw couldn’t survive!
The tricky evolution of the middle ear
94
Not in text
Source of figures: http://en.wikipedia.org/wiki/Evolution_of_mammalian_auditory_ossicles
Morganucodon, a.k.a. Morgie
discovered in the1950s
Correspondence discovered in 1837 (!)
through embriology
Analog Audio
Record players and stereos send analog signals to speakers to produce sound.
These signals are analog representations of the sound waves.
The voltage in the signal varies in direct proportion to the amplitude of the sound wave.
95
Remember: Sampling and Quantizing
96
Some information
is lost, but the sound is
reproduced with a
reasonable quality
Not in text
From Analog to Digital Audio
Digitize the signal by sampling and quantizing
– periodically measure the voltage
– record the numeric value in binary
How often should we sample?
Nyquist’s Theorem says that the nr. of samples per second needs to be at least double the highest frequency in the signal.
97
From Analog to Digital Audio
How often should we sample?
Nyquist’s Theorem says that the nr. of samples per second needs to be at least double the highest frequency in the signal.
The highest frequency the human ear can perceive is 20,000 Hz (20 KHz).
98
From Analog to Digital Audio
How often should we sample?
A sampling rate of about 40,000 times per second is enough to create a reasonable sound reproduction.
99
44,000 for audio CD, to be exact
QUIZ: Sampling
A telephone voice channel is designed to allow frequencies up to 4,000 Hz (4 kHz).
How many samples must be collected every second to digitize the signal?
100
Digital Audio on a CD
101
Figure 3.9
A CD player reading
binary information
“pit”
“land”
Digital Audio on a CD
On the surface of the CD are microscopic pits
and lands that represent binary digits
A low intensity laser is pointed as the disc. The
laser light reflects strongly if the surface is
smooth and poorly if the surface is pitted ???
(p.75 of text)
102
103
Pit height is about ¼ the
laser’s wavelength
“destructive
interference”
FYI: How the pits and lands are actually readNot in text
104
Both halves of the
laser beam reflect off
pit or both halves off
land.
The two halves are “in
phase”.
Half of the laser beam
reflects off pit and half
off land.
The 2 halves are “out
of phase”.
FYI: How the pits and lands are actually read
Not in text
Audio FormatsAudio Formats
– WAV, AU, AIFF, VQF, and MP3
MP3 (MPEG-2, audio layer 3 file) is dominant
– analyzes the frequency spread and discards information that can’t be heard by humans (>16 kHz)
– bit stream is compressed using a form of Huffman encoding to achieve additional compression
Is this a lossy or lossless compression?105
QUIZ: MP3MP3
– analyzes the frequency spread and discards information that can’t be heard by most humans (>16 kHz)
How many MP3 samples are there in a 3-minute song?
106
MP3
– analyzes the frequency spread and discards information that can’t be heard by most humans (>16 kHz)
How many MP3 samples are there in a 3-minute song?
If each sample is represented as one Byte, what is the total size of the file?
107
QUIZ: MP3
SolutionHow many MP3 samples are there in a 3-
minute song?
16,000 x 2 x 60 x 3 = 5,760,000 samples
If each sample is represented as one Byte, what is the total size of the file?
5,760,000 samples = 5,760,000 Bytes ≈ 5.76 MB
Note: MP3 then applies Huffman coding, which further reduces the size of the file.
108EOL 3
109
MP3 quiz reloaded!
3.5 Representing Images and Graphics
Color
Perception of the frequencies of light that reach
the retinas of our eyes
Human retinas have three types of color
photoreceptor cone cells that correspond to the
colors of red, green, and blue.
110
Color is expressed as an RGB (red-green-blue) value = three numbers that indicate the relative contribution of each of these three primary colors
An RGB value of (255, 255, 0) maximizes the contribution of red and green, and minimizes the contribution of blue, which results in a bright yellow.
111
112
Dark means low number, light
means high.
Look at the snow and the black
side of the barn!
Source: Wikipedia – RGB color model
Can you understand this HTML code?
<font color="#FF0000">
Blah blah …
</font>
113
RGB Color Chart in hex
QUIZ
114
Explain the similarities and differences between 00FF00 and 008800
The color cube
115
Figure 3.10 Three-dimensional color space
Depth of colorcolor depth
The amount of data that is used to represent a color
HiColor
A 16-bit color depth: five bits used for each number in an RGB value with the extra bit sometimes used to represent transparency
TrueColor
A 24-bit color depth: eight bits used for each number in an RGB value
116
QUIZ
117
Are these HiColor
or TrueColor?
EOL5
Extra-credit question
118
Tarleton Purple
119
The correct "Tarleton Purple" color codes:
• Hex: 4F 2D 7F
• RGB: 79 45 127 (decimal)
Source: http://www.tarleton.edu/webservices/guidelines.html
How to digitize a picture
• Sample it → Represent it as a collection of individual dots called pixels.
• Quantize it → Represent each pixel as one of 224 possible colors (TrueColor)
Resolution = The # of pixels used to represent a picture
120
Example of sampling into pixels
121
Figure 3.12 A digitized picture composed of many individual pixels
Whole
picture
122
Figure 3.12 A digitized picture composed of many individual pixels
Magnified portion
of the picture
See the pixels?
Hands-on: paste the
high-res image from
the previous slide in
Paint, then choose
ZOOM = 800
QUIZ: Images
A low-res image has 200 rows and 300 columns of pixels.
• What is the resolution?
• If the pixels are represented in True-Color, what is the size of the file?
• Same question in High-Color.
123
Two types of image formats
• Raster Graphics = Storage on a pixel-by-pixel
basis
• Vector Graphics = Storage in vector (i.e. mathematical) form
124
Raster Graphics
GIF format• Each image is made up of only 256 colors (indexed color –
similar to palette!)
• But they can be a different 256 for each image!
• Supports animation! Example
• Optimal for line art
PNG format (“ping” = Portable Network Graphics)
Like GIF but achieves greater compression with wider range of color depth
No animations
125
Bitmap formatContains the pixel color values of the image from left to right and from top to bottom
• Great candidate for run-length compression!
• Lossless, but files are large!
JPEG formatAverages color hues over short distances
• Lossy compression!
Optimal for color photographs
126
Vector GraphicsA format that describes an image in terms of lines and geometric shapes
A vector graphic is a series of commands that describe a line’s direction, thickness, and color.
The file sizes tend to be smaller because not every pixel is described.
Example: Flash
127
Vector Graphics
The good side:
Vector graphics can be resized mathematically and changes can be calculated dynamically as needed
The bad side:
Vector graphics are not good for representing real-world images
128
SKIP: 3.6 Representing Video
129
Read: Bio → Bob Bemer
Read: Ethical Issues →Snowden’s revelations
Source: AP CS Principles – Course and Exam Descriptions
Chapter QUIZ
Based on the many examples of data compression we covered, answer this:
Quick workTo do by next class, before starting to work
on homework:
• Read the entire Chapter 3
• SKIP …
• Answer end-of-chapter questions 8 – 19, 32, 33 in your notebook
131
This is not homework!Do not turn in for
grading!
Homework problems :
--36, 40, 41, 47, 49, 51, 52, 53, 61.
--Answer thought questions 4 and 5
together (200-word answer expected!):4. Where is Edward Snowden now?
5. What do you think history will call him?
Due Thursday, Sep.27 at beginning of class
132
Control Character: newline
134
Source: http://en.wikipedia.org/wiki/Newline#Unicode
FYI
Chapter Review Questions
• Distinguish between analog and digital information
• Explain data compression and calculate compression ratios
• Explain the binary formats for negative (two’s complement), fractional, and floating-point values
• Describe the characteristics of the ASCII and Unicodecharacter sets
• Perform various types of text compression with pencil and paper: Keyword, Run-length, Huffman
135
Chapter Review Questions
• Explain the nature of sound and its representation
• Explain how RGB values define a color
• Distinguish between raster and vector graphics
• Explain temporal and spatial video compression
136