Presentation is loading. Please wait.

Presentation is loading. Please wait.

Lecture 2 Numbers and number systems. Some material from the last lecture Electronic computers represent information as voltage levels. To make the computer.

Similar presentations


Presentation on theme: "Lecture 2 Numbers and number systems. Some material from the last lecture Electronic computers represent information as voltage levels. To make the computer."— Presentation transcript:

1 Lecture 2 Numbers and number systems

2 Some material from the last lecture Electronic computers represent information as voltage levels. To make the computer hardware simple and reliable, computers represent information in binary form. –example: voltages greater than 3V are interpreted as representing one value (called “1”), voltages less than 2V are interpreted as representing another value (called “0”). In principle, could use more voltage levels. –example: 0 to.75V represents “0”, 1 to 1.75V represents “1”, 2 to 2.75V represents “2”, and so forth. In practice, this is rarely done. –requires more complex circuits –circuits are more susceptible to noise, hence less reliable

3 Some material from the last lecture Computers, like all electronic systems, are affected by noise. –noise has various sources (nearby signal changes, thermal vibrations of molecules in semiconductor materials,... ) –in computers, noise can cause binary signals to be misinterpreted The noise margin is the amount of noise that a system can tolerate and still correctly identify a logic high or low. Undefined High Low Undefined High Low 5v 4v 3v 2v 1v 0v noise margin 1 V noise margin 3 V

4 Radix number systems Some number of positions and some number of symbols The number of positions varies by context The number of symbols is a property of the number system –Decimal -- 10 symbols –Binary -- 2 symbols –Octal -- 8 symbols –Hexadecimal -- 16 symbols

5 Start with whole numbers Each position has a value Each symbol has a value Multiply the value of the symbol by the value of the position, then add –In decimal, 3874 means 3 times 1,000 plus 8 time 100 plus 7 times 10 plus 4 times 1

6 Decimal, binary, octal, hex In decimal there are 10 symbols (0..9) and the value of each position is a power of 10. –10 0 = 1 = value of the units position –10 1 = 10 = value of next position to the left –etc. In binary, there are 2 symbols, 0 and 1, and the value of each position is a power of 2. In octal, 8 symbols, and powers of 8 In hexadecimal, 16 symbols, and powers of 16

7 Weight 3784 Decimal Number: 378.4 Least Significant digit Most Significant digit. is called the radix point 3 is the MSD 4 is the LSD

8 weight2727 2626 2525 2424 23232 2121 2020 11001001 11001001 2 = 1  2 7 + 1  2 6 + 1  2 3 + 1  2 0 = 201 Least Significant bit Most Significant bit weight2525 2424 23232 2121 2020 2 -1 2 -2 11001001 110010.01 2 = 1  2 5 + 1  2 4 + 1  2 1 + 1  2 -2 = 50.25 Least Significant bit Most Significant bit

9 K, M and G 2 10 is referred as K (kilo) 2 20 is referred as M (mega) 2 30 is referred as G (giga)

10 Trinary Numbers weight3737 3636 3535 34343 3232 3131 3030 11001002 11001001 3 = 1  3 7 + 1  3 6 + 1  3 3 + 2  3 0 = 2945 Trinary number : 11001002 3

11 Octal Numbers weight 821821 812812 807807 8 -1 4 11001001 3 = 1  8 2 + 2  8 1 + 7  8 0 + 4  8 -1 = 87.5 Octal number : 127.4 8

12 Hexadecimal Numbers weight16 2 16 1 16 0 FA9 FA9 H = 15  16 2 + 10  16 1 + 9  16 0 = 4009 Hexadecimal number : FA9 H HexDec 00 11 22 33 44 55 66 77 88 99 A10 B11 C12 D13 E14 F15

13 Things to do Review from your class notes what we discussed today. Conversions between Number Systems –Binary, octal and hexadecimal Solve 1-6 before coming to the class


Download ppt "Lecture 2 Numbers and number systems. Some material from the last lecture Electronic computers represent information as voltage levels. To make the computer."

Similar presentations


Ads by Google