|
Unit 5: Number Systems and Codes
"There are 10 kinds of people in the world,
those who understand binary numbers, and those who don't."
No computational science class is complete without a discussion of number systems with a focus on binary numbers and binary arithmetic. For pretty much your whole elementary and high school career, you learned to do all your math using the numbers from 0 to 9, the symbols used as digits to represent the decimal (base ten) numeral system. The base of any number system is determined by the number of digits in the system. Binary is base two as the prefix, bi- ,indicates. You probably learned in Computer Science 20 that computers do not "Do" math the same way as real people do.
The whole of computer technology is built around a very simple circuit which has exactly two states; on or off. Whatever the computer does must be able to be resolved into complex patterns of on or off switches. Factory computers at the time of this writing are shipping with 512 megabytes of random access memory. If we limited the size of data to a 32 bit processor, that translates into approximately 5.12 x 10^8 bytes times 32 bits = 1.6384 x 10^10 (16,384,000,000) on/off switches. Data is typically 32 to 64 bits wide on personal computers. We use groupings of 32 or 64 bits to represent symbols, colors, sound and commands to instruct the computer to accomplish tasks for us. Even a single bit out of place can spell disaster for a program. Hey, can you remember what you had for lunch last week or a year ago today. Computers have to remember hugh amounts of data, represented as these on and off switches, to the exact bit for years and years. To read more about how binary works, read the article called, "Binary numeral system" at Wikipedia.
 
|