انت هنا الان : شبكة جامعة بابل > موقع الكلية > نظام التعليم الالكتروني > مشاهدة المحاضرة
الكلية كلية تكنولوجيا المعلومات
القسم قسم البرامجيات
المرحلة 1
أستاذ المادة شيماء عبد الحمزة محمد الكرعاوي
08/12/2012 16:35:02
cimal digit to a 4-bit equivalent binary representation
Decimal to Octal • Technique – Divide by 8 – Keep track of the remainder
Decimal to Hexadecimal Technique – Divide by 16 – Keep track of the remainder • Binary to Octal • Technique – Group bits in threes, starting on right – Convert to octal digits
Binary to Hexadecimal • Technique – Group bits in fours, starting on right – Convert to hexadecimal digits
Octal to Hexadecimal • Technique – Use binary as an intermediary Hexadecimal to Octal • Technique – Use binary as an intermediary
End of the lecture Introduction
A digital logic system may well have a numerical computation capability as well as its inherent logical capability and consequently it must be able to implement the four basic arithmetic processes of addition, subtraction, multiplication and division. Human beings normally perform arithmetic operations using the decimal number system, but, by comparison, a digital machine is inherently binary in nature and its numerical calculations are executed using a binary number system. Since the decimal system has ten digits, a ten-state device is required to represent the decimal digits, one state being allocated to each of the decimal digits. Ten-state devices are not readily available in the electrical world, however two-state devices such as a transistor operating in a switching mode are, and it is forth is reason that the binary number system is of great importance to the digital engineer. In addition to the binary system, a number of other systems such as the hexadecimal system are used in.
Number Systems
A number system defines how a number can be represented using distinct symbols. A number can be represented differently in different systems. For example, the two numbers (2A)¬16 and (52)8 both refer to the same quantity, (42)10 , but their representations are different.
The decimal system (base 10)
The word decimal is derived from the Latin root decem (ten). In this system the base b = 10 and we use ten symbols
S = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9} The symbols in this system are often referred to as decimal digits or just digits.
Integers
Figure 2.1 Place values for an integer in the decimal system
EX.1
The following shows the place values for the integer +224 in the decimal system.
Note that the digit 2 in position 1 has the value 20, but the same digit in position 2 has the value 200. Also note that we normally drop the plus sign, but it is implicit
EX.2
The following shows the place values for the decimal number ?7508. We have used 1, 10, 100, and 1000 instead of powers of 10.
Note that the digit 2 in position 1 has the value 20, but the same digit in position 2 has the value 200. Also note that we normally drop the plus sign, but it is implicit.
Reals
The following shows the place values for the real number +24.13.
EX.3
The binary system (base 2)
The word binary is derived from the Latin root bini (or two by two). In this system the base b = 2 and we use only two symbols,
The symbols in this system are often referred to as binary digits or bits (binary digit).
Figure 2.2 Place values for an integer in the binary system
EX.4
The following shows that the number (11001)2 in binary is the same as 25 in decimal. The subscript 2 shows that the base is 2.
The equivalent decimal number is N = 16 + 8 + 0 + 0 + 1 = 25.
Reals
EX.5
The following shows that the number (101.11)2 in binary is equal to the number 5.75 in decimal.
The octal system (base 8)
The word octal is derived from the Latin root octo (eight). In this system the base b = 8 and we use eight symbols to represent a number. The set of symbols is
Integers
Figure 2.3 Place values for an integer in the octal system
EX.6
The following shows that the number (1256)8 in octal is the same as 686 in decimal.
Note that the decimal number is N = 512 + 128 + 40 + 6 = 686.
The hexadecimal system (base 16)
The word hexadecimal is derived from the Greek root hex (six) and the Latin root decem (ten). In this system the base b = 16 and we use sixteen symbols to represent a number. The set of symbols is
Note that the symbols A, B, C, D, E, F are equivalent to 10, 11, 12, 13, 14, and 15 respectively. The symbols in this system are often referred to as hexadecimal digits.
Integers
Figure 2.3 Place values for an integer in the hexadecimal system EX.6
The following shows that the number (2AE)16 in hexadecimal is equivalent to 686 in decimal.
The equivalent decimal number is N = 512 + 160 + 14 = 686.
End of the lecture
المادة المعروضة اعلاه هي مدخل الى المحاضرة المرفوعة بواسطة استاذ(ة) المادة . وقد تبدو لك غير متكاملة . حيث يضع استاذ المادة في بعض الاحيان فقط الجزء الاول من المحاضرة من اجل الاطلاع على ما ستقوم بتحميله لاحقا . في نظام التعليم الالكتروني نوفر هذه الخدمة لكي نبقيك على اطلاع حول محتوى الملف الذي ستقوم بتحميله .
|