1 / 25

TOPIC 2

TOPIC 2. NUMBERING SYSTEM. NUMBERING SYSTEM.

derrickson
Download Presentation

TOPIC 2

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. TOPIC 2 NUMBERING SYSTEM

  2. NUMBERING SYSTEM • Many number systems are in use in digital technology. The most common are the decimal, binary, octal, and hexadecimal systems. The decimal system is clearly the most familiar to us because it is a tool that we use every day. Examining some of its characteristics will help us to better understand the other systems.

  3. DECIMAL SYSTEM • Decimal System The decimal system is composed of 10 numerals or symbols. These 10 symbols are 0, 1, 2, 3, 4, 5, 6, 7, 8, 9; using these symbols as digits of a number, we can express any quantity. The decimal system, also called the base-10 system because it has 10 digits.

  4. BINARY SYSTEM • In the binary system, there are only two symbols or possible digit values, 0 and 1. This base-2 system can be used to represent any quantity that can be represented in decimal or other number system. • In digital systems the information that is being processed is usually presented in binary form. Binary quantities can be represented by any device that has only two operating states or possible conditions. Eg. a switch has only open or closed. We arbitrarily (as we define them) let an open switch represent binary 0 and a closed switch represent binary 1. Thus we can represent any binary number by using series of switches.

  5. BINARY COUNTING • The Binary counting sequence is shown in the table:

  6. BINARY TO DECIMAL CONVERTION • Any binary number can be converted to its decimal equivalent simply by summing together the weights of the various positions in the binary number which contain 1. • Example 1: convert 110112 to decimal value Solve: 1 1 0 1 1 = 16+8+2+1 =

  7. Example 2 : Convert 101101012 to decimal value Solve: 1 0 1 1 0 1 1 0 = 128 + 32 + 16 + 4 + 1 = You should noticed the method is find the weights (i.e., powers of 2) for each bit position that contains 1, and then to add them up.

  8. DECIMAL TO BINARY CONVERTION • There are two methods to convert it:- • Revese of Binary-To-Digital Method • Decimal number write as the sum of square • 0 & 1 is write on the byte Example 1: Convert 4510 to the binary value Solve = 32 + 8 + 4 + 1 = 0 0 = 0 1 1 0 = 1 1 2

  9. 3 1 25 12 6 2 2 2 2 2 • Repeat division method • The numbers is divide by 2. • Balance for the question is written until the last answer. Example : convert 2510 to binary 2510 = ?2 Solve = = 12 balance 1 LSB = 6 balance 0 = 3 balance 0 = 1 balance 1 = 0 balance 1 MSB . . . Answer = 110012

  10. The Flow chart for repeated-division method is as follow:

  11. OCTAL NUMBER SYSTEM • The octal number system has a base of eight, meaning that it has eight possible digits: 0,1,2,3,4,5,6,7. • Use to represent long binary numbers in computers and microprocessors.

  12. OCTAL TO DECIMAL CONVERTION • Convert from octal to decimal by multiplying each octal digit by its positional weight. Example 1: Convert 1638 to decimal value Solve = = 1 x 64 + 6 x 8 + 1 x 1 = 11510 Example 2: Convert 3338 to decimal value Solve = = 3 x 64 + 3 x 8 + 3 x 1 = 21910

  13. 5 359 44 8 8 8 DECIMAL TO OCTAL CONVERTION • Convert from decimal to octal by using the repeated division method used for decimal to binary conversion. • Divide the decimal number by 8 • The first remainder is the LSB and the last is the MSB. Example : convert 35910 to Decimal Value 35910 = ?8 Solve = = 44 balance 7 LSB = 5 balance 4 = 0 balance 5 MSB . . . Answer = 5478

  14. OCTAL TO BINARY CONVERTION • Convert from octal to binary by converting each octal digit to a three bit binary equivalent • Convert from binary to octal by grouping bits in threes starting with the LSB. • Each group is then converted to the octal equivalent • Leading zeros can be added to the left of the MSB to fill out the last group.

  15. BINARY TO OCTAL CONVERSION • Can be converted by grouping the binary bit in group of three starting from LSB • Octal is a base-8 system and equal to two the power of three, so a digit in Octal is equal to three digit in binary system.

  16. HEXADECIMAL NUMBER SYSTEM • The hexadecimal system uses base 16. Thus, it has 16 possible digit symbols. It uses the digits 0 through 9 plus the letters A, B, C, D, E, and F as the 16 digit symbols. • Use to represent long binary numbers in computers and microprocessors. • These digits can use to program machine language.

  17. BINARY TO OCTAL CONVERSION • Can be converted by grouping the binary bit in group of three starting from LSB • Octal is a base-8 system and equal to two the power of three, so a digit in Octal is equal to three digit in binary system.

  18. HEXADECIMAL TO OCTAL CONVERTION • There is two ways to convert it:- • Hexadecimal – Decimal – Octal • Hexadecimal – Binary – Octal • Hexadecimal – Decimal – Octal

  19. Hexadecimal – Decimal – Octal

  20. SISTEM PELENGKAP -1 • Pelengkap –1 digunakan dalam nombor binari dandiperolehi dengan cara menukarkan 0 ke 1 dan 1 ke 0 • Nombor yang ditukarkan hanyalah nombor negatif sahaja • Nombor yang diberi selain daripada binari perlu ditukar kepada bentuk binari terlebih dahulu. Contoh 1:Tukarkan 10011001 2 kepada bentuk pelengkap –1.Penyelesaian : 1 0 0 1 1 0 0 1 Jawapan : 01100110 Nombor asal 1 ditukar kepada 0 dan sebaliknya

  21. Contoh2 : Tukarkan 27 10 kepada pelengkap –1. Penyelesaian : a) Tukarkan 27 10 kepada bentuk binari. b) Nombor binari kemudian di tukar dari 0 ke 1 dan 1 ke 0. a) 2 2 Baki 1 2 Baki 1 2 Baki 0 = 11011 2 Baki 1 Baki 1 b) Tukarkan 11011 kepada pelengkap -1 = 00100

  22. SISTEM PELENGKAP -2 • Pelengkap –2 = pelengkap-1 +1 • nombor negatif yang diberi diperolehi dengan menukar nombor negatif tersebut kepada pelengkap –1 dan dicampur dengan 1 Contoh 1: Tukarkan 10011001 2 kepada bentuk pelengkap –2. a) Tukarkan ke pelengkap-1 1 0 0 1 1 0 0 1 dalam bentuk pelengkap –1 ialah 0 1 1 0 0 1 1 0 dimana 0 → 1 dan 1 → 0. b) Tukarkan ke pelengkap-2 01100110 ditambah dengan 1 dibahagian LSB menjadi 011001112.

  23. Contoh2 : Tukarkan 27 10 kepada pelengkap –2. Penyelesaian : a) Tukarkan 2710 dalam bentuk binary 2 2 Baki 1 2 Baki 1 2 Baki 0 = 110112 2 Baki 1 Baki 1 b) Tukarkan 11011 kepada pelengkap -1 001002 c) 00100 ditambah dengan 1 dibahagian LSB menjadi 001012.

More Related