Binary Values and Number Systems

Slides:



Advertisements
Similar presentations
Binary Values and Number Systems
Advertisements

Chapter 2 Binary Values and Number Systems Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in.
09/11/06 Hofstra University – Overview of Computer Science, CSC005 1 Chapter 2 Binary Values and Number Systems.
Number Systems. 2 The total number of allowable symbols in a number system is called the radix or base of the system. Decimal Numbers: radix = 10 (symbols:
CS 151 Digital Systems Design Lecture 2 Number Systems Prof. Ahmed Sameh Room 239A.
Chapter Chapter Goals Know the different types of numbers Describe positional notation.
Data Representation in Computers
ENGIN112 L2: Number Systems September 5, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 2 Number Systems Russell Tessier KEB 309 G.
Chapter 02 Binary Values and Number Systems Nell Dale & John Lewis.
The Binary Number System
© Copyright 2000 Indiana University Board of Trustees Proficiency Quiz Study Guide Note: The following slides are provided courtesy of Dr. Bob Orr (Computer.
Numbering Systems Decimal (Denary) base 10. Clumsy when dealing with computers. Other systems –Binary –Octal –Hexadecimal Convenient when dealing with.
© GCSE Computing Candidates should be able to:  convert positive denary whole numbers (0-255) into 8-bit binary numbers and vice versa  add two 8-bit.
Binary and Hexadecimal Numbers
Number Systems.
CS105 INTRODUCTION TO COMPUTER CONCEPTS BINARY VALUES & NUMBER SYSTEMS Instructor: Cuong (Charlie) Pham.
Numeral Systems Subjects: Numeral System Positional systems Decimal
How Computers Work Dr. John P. Abraham Professor UTPA.
1 Problem Solving using computers Data.. Representation & storage Representation of Numeric data The Binary System.
Chapter 2 Binary Values and Number Systems Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in.
Chapter 2 Binary Values and Number Systems. 2 2 Natural Numbers Zero and any number obtained by repeatedly adding one to it. Examples: 100, 0, 45645,
1 Week 2: Binary, Octal and Hexadecimal Numbers READING: Chapter 2.
Chapter 2 Binary Values and Number Systems Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in.
Binary Values and Number Systems Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in other bases.
Number systems, Operations, and Codes
Representing Information Digitally (Number systems) Nell Dale & John Lewis (adapted by Erin Chambers, Michael Goldwasser, Andrew Harrington)
CPS120: Introduction to Computer Science Computer Math: Converting to Decimal.
Positional Notation 642 in base 10 positional notation is:
Lecture 2 Binary Values and Number Systems. The number 943 is an example of a number written in positional notation. The relative positions of the digits.
CISC1100: Binary Numbers Fall 2014, Dr. Zhang 1. Numeral System 2  A way for expressing numbers, using symbols in a consistent manner.  " 11 " can be.
1 Data Representation Characters, Integers and Real Numbers Binary Number System Octal Number System Hexadecimal Number System Powered by DeSiaMore.
Chapter 2 Number Systems: Decimal, Binary, and Hex.
Introduction To Number Systems Binary System M. AL-Towaileb1.
Chapter 2 Binary Values and Number Systems Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in.
ECE 362 Microprocessor Systems and Interfacing ©5-1 Lecture 1 Hexadecimal Computation Outline n Decimal n Binary n Octal n Hexadecimal.
EEE342 Digital Electronics Ian McCrumRoom 5B18, Lecture 2: Codes & Arithmetic.
©2010 Cengage Learning SLIDES FOR CHAPTER 1 INTRODUCTION NUMBER SYSTEMS AND CONVERSION Click the mouse to move to the next page. Use the ESC key to exit.
Chapter 2 Binary Values and Number Systems in base 10 positional notation is: 6 x 10 2 = 6 x 100 = x 10 1 = 4 x 10 = x 10º = 2.
The Hexadecimal System is base 16. It is a shorthand method for representing the 8-bit bytes that are stored in the computer system. This system was chosen.
Number Systems and Binary Arithmetic Quantitative Analysis II Professor Bob Orr.
Binary Values. Numbers Natural Numbers Zero and any number obtained by repeatedly adding one to it. Examples: 100, 0, 45645, 32 Negative Numbers.
Week 1(Number System) Muhammad Ammad uddin Logic Design Lab I (CEN211)
Prepared By: Norakmar Binti Mohd Nadzari CHAPTER 2 ARITHMETIC AND LOGIC UNIT.
3.1 Denary, Binary and Hexadecimal Number Systems We use the denary (base 10) number system in our daily life for counting and calculation. Computers use.
Binary Values and Number Systems
Lecturer: Santokh Singh
Introduction To Number Systems
Computer Maintenance Numbering Systems Trade & Industrial Education
Digital Design Chapter One Digital Systems and Binary Numbers
Chapter 02 Nell Dale & John Lewis.
3.1 Denary, Binary and Hexadecimal Number Systems
Integer Real Numbers Character Boolean Memory Address CPU Data Types
Lecture 3: Binary values and number systems
COMPUTING FUNDAMENTALS
Chapter 3 Data Representation
Number System conversions
Number Systems.
Chapter 1 Number Systems & Conversions
Number Systems and Binary Arithmetic
Textbook Computer Science Illuminated 4th Edition  By Nell Dale, John Lewis - Jones and Bartlett Publishers 11/20/2018.
MMNSS COLLEGE,KOTTIYAM DEPARTMENT OF PHYSICS
Binary Values and Number Systems
Chapter Four Data Representation in Computers By Bezawit E.
Chapter 2 Number Systems.
Binary Values and Number Systems
Chapter 2 Number Systems.
Chapter 2 Number System.
Introduction To Number Systems
Binary Values and Number Systems
Chapter 2 Number Systems.
Presentation transcript:

Binary Values and Number Systems Chapter 2 Binary Values and Number Systems - Eswari Manickam Materials are from text book with additions and adaptations by Eswari Manickam

Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in other bases to base 10 Convert base-10 numbers to numbers in other bases Describe the relationship between bases 2 and 16 Explain the importance to computing of bases that are powers of 2 24 6

Binary Decimal is base 10 and has 10 digits: 0,1,2,3,4,5,6,7,8,9 Binary is base 2 and has 2 digits: 0,1 For a number to exist in a given base, it can only contain the digits in that base, which range from 0 up to (but not including) the base. What bases can these numbers be in? 122, 198, 178, G1A4 9

Positional Notation 642 is 600 + 40 + 2 in BASE 10 Continuing with our example… 642 in base 10 positional notation is: 6 x 102 = 6 x 100 = 600 + 4 x 101 = 4 x 10 = 40 + 2 x 10º = 2 x 1 = 2 = 642 in base 10

Converting Binary to Decimal What is the decimal equivalent of the binary number 1101110? 1 x 26 = 1 x 64 = 64 + 1 x 25 = 1 x 32 = 32 + 0 x 24 = 0 x 16 = 0 + 1 x 23 = 1 x 8 = 8 + 1 x 22 = 1 x 4 = 4 + 1 x 21 = 1 x 2 = 2 + 0 x 2º = 0 x 1 = 0 = 110 in base 10 13

Converting Binary to Decimal What is the decimal equivalent of the following binary numbers? a) 11101 b) 1011010 c) 10011100

Bases Higher than 10 How are digits in bases higher than 10 represented? With distinct symbols for 10 and above. Hexadecimal is base 16 and has 16 digits: 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E, and F 10

Converting Hexadecimal to Decimal What is the decimal equivalent of the hexadecimal number 32A? 3 x 162 = 3 x 256 = 768 + 2 x 161 = 3 x 16 = 48 + A x 16º = 10 x 1 = 10 = 826 in base 10 Remember, the digits in base 16 are 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F

Converting Hexadecimal to Decimal What is the decimal equivalent of the following hexadecimal numbers? 87A b) 34E c) F000

Counting in Binary/Hexadecimal/Decimal 0000 1 0001 2 0010 3 0011 4 0100 5 0101 6 0110 7 0111 8 1000 9 1001 10 A 1010 11 B 1011 12 C 1100 13 D 1101 14 E 1110 15 F 1111

Converting Binary to Hexadecimal Mark groups of four (from right) Convert each group 10101011 1010 1011 A B 10101011 is AB in base 16 18

Converting Binary to Hexadecimal What is the hexadecimal equivalent of the following binary numbers? 00001001 10101001 010111011110

Converting Decimal to Other Bases Algorithm for converting number in base 10 to other bases While (the quotient is not zero) Divide the decimal number by the new base Make the remainder the next digit to the left in the answer Replace the original decimal number with the quotient 19

Converting Decimal to Hexadecimal What is the hexadecimal equivalent of (3567)10 ? 222 13 0 16 3567 16 222 16 13 32 16 0 36 62 13 32 48 47 14 32 15 D E F 21

Converting Decimal to Hexadecimal What is 356 (base 10) in base 16? What is 1135 (base 10) in base 16? What is 4759 (base 10) in base 16? Try it! 20

Converting Decimal to Binary Example of converting decimal to binary What is the binary equivalent of the decimal number 35? 17 8 4 2 1 0 2 35 2 17 2 8 4 2 1 34 16 8 4 2 0 1 1 0 0 0 1 Adding digits to the left as we calculate: 100011

Converting Decimal to Binary Easy method for converting decimal to binary What is the binary equivalent of the decimal number 35? 2 35 - 1 2 17 - 1 2 8 - 0 2 4 - 0 2 2 - 0 2 1 - 1 So reading from the bottom – The answer would be 100011

Converting Decimal to Binary What is the binary equivalent of the following decimal integers? A) 64 B) 1066 C) 213 D) 1790

Arithmetic in Binary Remember that there are only 2 digits in binary, 0 and 1 1 + 1 is 0 with a carry Carry Values 1 1 1 1 1 1 1 0 1 0 1 1 1 +1 0 0 1 0 1 1 1 0 1 0 0 0 1 0 14

Arithmetic in Binary Calculate: 10001 + 11101 1110 + 1111 1011001 + 111010

Subtracting Binary Numbers Remember borrowing? Apply that concept here: 1 2 2 0 2 1 0 1 0 1 1 1 - 1 1 1 0 1 1 0 0 1 1 1 0 0 15

Subtracting Binary Numbers Calculate: 1011011 - 10010 1010110 - 101010 1000101 - 101100

Binary Numbers and Computers Computers have storage units called binary digits or bits Low Voltage = 0 High Voltage = 1 all bits have 0 or 1 22

Binary and Computers Byte 8 bits The number of bits in a word determines the word length of the computer, but it is usually a multiple of 8 32-bit machines 64-bit machines etc. 23