Title: Comairs Glitch, Moores Law, and Morse Code
1Comairs Glitch, Moores Law, and Morse Code
2From last time
3(No Transcript)
4Binary counting1110, or 110 and carry 1
5Positive and Negative Numbers
- Signed and unsigned numbers
- Unsigned 28256 bit patterns represent 0 255
- Signed 28 bit patterns represent -128 127
- Leftmost bit sign bit 0 gt 0 or pos, 1 gt neg
- Largest 8-bit positive number 01111111 127
- 0 00000000
- Most negative negative number 10000000 -128
6Negative numbers
-1 11111111so addition works the same for
positive and negative numbers
7Biggest Numbers
- Biggest positive number 01111111 (like 999999
on a car odometer) - Most negative negative number 10000000
8Biggest Positive Number 1 Most Negative
Negative Number
9The Comair Christmas Glitch
- 16 bits for monthly count of crew changes
- Biggest positive 16-bit number 32,767
- December was a bad month, lots of snowstorms,
lots of flights rescheduled - As Christmas approached the count went from
32,767 to -32,768 by adding 1
10How many Bytes?
- 1 byte 8 bits 2 hex digits 1 character
- 210 1024 bytes 1 kilobyte 1KB
- 220 1,048,576 bytes 1 megabyte 1MB
- 230 bytes 1 gigabyte 1GB a billion
- 240 bytes 1 terabyte 1TB a trillion
- 250 bytes 1 petabyte 1PB a quadrillion
- 260 bytes 1 exabyte 1EB a quintillion
- 270 zetta
- 280 yotta
11K
- All this terminology based on the accident that
- Which is 1K?
- There are new standard names
- 1 kibibyte 1000 bytes
- vs. 1 kilobyte 1024 bytes
- But almost no one uses kibi-, mebi-, etc.
12(No Transcript)
13(No Transcript)
14Moores Law (1965)
- The number of transistors on a silicon chip
doubles every 18 or 12, or 24 months - 1965 64 26
- 2006 1 billion
- Since 1965 there has been one doubling every 20
months
15Example of linear increase
16Example of exponential increase
- Now for the y axis use instead lg(y) the
exponent e such that 2ey
17Same plot, using lg(y) instead of y
18One of the Greatest Engineering Achievements
- An increase of a factor of 224 is about 16
millionfold - Increase in disk capacity and processor speed
have also been exponential - If human speed had increased that much since
Moores paper, we would now be traveling faster
than the speed of light
19The Incomprehensibly Fast Rate of Exponential
Growth
- A 27-decimal-digit counter is enough to have
counted in nanoseconds since the origin of the
universe - 17 letters are enough to name all the stars in
the universe
20The 40-bit Key Key
-
- "If you were to tell a cryptographer that this
system uses 40-bit keys, you'd immediately
conclude that the system is weak and that you'd
be able to break it," said Ari Juels, a scientist
with the research arm of RSA Security - 240 about a trillion
21Probabilities
- Fair coin P(heads) 1/2
- Fair die P(rolling 3) 1/6
- Fair card deck P(hearts) 1/4
- P(ace) 1/13
22Probabilities of Independent Events Multiply
- P(heads and then heads) 1/2 1/2 1/4
- P(3 and then 4) 1/6 1/6 1/36
- P(ace and ace) 1/131/13 1/169 .0059 but
only if the first card drawn is replaced and the
deck is completely reshuffled, otherwise the
events are not independent - P(ace and ace without reshuffling)
- 1/13 3/51 .0045
23Unlikely Events
- How likely are 100 heads in a row?
- (1/2)100 10-32 .000000000000000000000000000000
01
24How Small is 2-100 10-32?
- Age of universe 1018 sec 1027 nanoseconds
- (1 nanosecond 1 ns 1 billionth of a
second 10-9 sec) - If you flip a coin 100 times every billionth of
a second, you will get 100 heads in a row about
once every hundred thousand lifetimes of the
universe - 1032 105 1027
- This is never for all practical purposes
25Morses telegraph1844 1848
26(No Transcript)
27Morse Code (1838)
28Morse Code (1838)
29How Long are Morse Codes on Average?
- Not the average of the lengths of the letters
(2443)/26 82/26 3.2 - We want the average a to be such that in a
typical real sequence of say 1,000,000 letters,
the number of dots and dashes should be about
a1,000,000 - The weighted average
- (freq of A)(length of code for A)
- (freq of B)(length of code for B)
-
- .082 .014 .034 .043 2.4
30Data vs. Information
- Message sequence
- yea, nay, yea, yea, nay, nay
- In ASCII, 38 24 bits of data per message
- But if the only possible answers are yea and
nay, there is only 1 bit of information per
message - Entropy is a measure of the information content
of a message, as opposed to its size - Entropy 1 bit/message
- 1, 0, 1, 1, 0, 0 same information content but
24 times more efficient
31Squeezing out the Air
- Suppose you want to ship pillows in boxes and are
charged by the size of the box - To use as few boxes as possible, squeeze out all
the air, pack into boxes, fluff them up at the
other end - Lossless data compression
- Entropy lower limit of compressibility