CIS 234: Numbering Systems Dr. Ralph D. Westfall April, 2010.

Slides:



Advertisements
Similar presentations
Base Conversion COP Practice Problem  Print a String in reverse order:  For example, if we want to print “HELLO” backwards,  we first print:
Advertisements

Candidates should be able to:
NUMBER SYSTEM. How to convert hexadecimal numbers to decimal numbers? 230 Working from right to left, MULTIPLY each position with 8 raised to the power.
ICS312 Set 2 Representation of Numbers and Characters.
Binary Representation Introduction to Computer Science and Programming I Chris Schmidt.
CS 151 Digital Systems Design Lecture 3 More Number Systems.
Agenda Shortcuts converting among numbering systems –Binary to Hex / Hex to Binary –Binary to Octal / Octal to Binary Signed and unsigned binary numbers.
Chapter Chapter Goals Know the different types of numbers Describe positional notation.
Chapter 02 Binary Values and Number Systems Nell Dale & John Lewis.
ENGIN112 L3: More Number Systems September 8, 2003 ENGIN 112 Intro to Electrical and Computer Engineering Lecture 3 More Number Systems.
Binary numbers. 1 Humans count using decimal numbers (base 10) We use 10 units: 0, 1, 2, 3, 4, 5, 6, 7, 8 and (5.
Lesson 2 0x Coding ASCII Code.
COMP201 Computer Systems Number Representation. Number Representation Introduction Number Systems Integer Representations Examples  Englander Chapter.
CIS 234: Character Codes Dr. Ralph D. Westfall April, 2011.
Data Storage Introduction to computer, 2nd semester, 2010/2011 Mr.Nael Aburas Faculty of Information Technology Islamic.
Digital Logic Chapter 2 Number Conversions Digital Systems by Tocci.
Real Numbers and the Decimal Number System
Number Systems.
CS105 INTRODUCTION TO COMPUTER CONCEPTS BINARY VALUES & NUMBER SYSTEMS Instructor: Cuong (Charlie) Pham.
How Computers Work Dr. John P. Abraham Professor UTPA.
ECEN2102 Digital Logic Design Lecture 1 Numbers Systems Abdullah Said Alkalbani University of Buraimi.
ICS312 Set 1 Representation of Numbers and Characters.
Supplemental Chapter Number Bases
Number Systems. Today Decimal Hexadecimal Binary –Unsigned Binary –1’s Complement Binary –2’s Complement Binary.
CONVERSION OF NUMBER SYSTEMS FAHEEM ANWAR MANAGER NETWORKS ACADEMY PTCL ACADEMY.
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,
Number Systems Ron Christensen CIS 121.
Number systems, Operations, and Codes
ECE2030 Introduction to Computer Engineering Lecture 2: Number System Prof. Hsien-Hsin Sean Lee School of Electrical and Computer Engineering Georgia Tech.
CPS120: Introduction to Computer Science Computer Math: Converting to Decimal.
Positional Notation 642 in base 10 positional notation is:
Converting From decimal to Binary & Hexadecimal to Binary
Number Systems Binary to Decimal Octal to Decimal Hexadecimal to Decimal Binary to Octal Binary to Hexadecimal Two’s Complement.
1 Press Ctrl-A ©G Dear 2010 – Not to be sold/Free to use Converting Bits and Bytes Stage 6 - Year 11 Applied Mathematic (Preliminary General 1)
1 Data Representation Characters, Integers and Real Numbers Binary Number System Octal Number System Hexadecimal Number System Powered by DeSiaMore.
Number Systems and Logic Prepared by Dr P Marais (Modified by D Burford)
1 COMS 161 Introduction to Computing Title: The Digital Domain Date: September 6, 2004 Lecture Number: 6.
Chapter 2 Number Systems: Decimal, Binary, and Hex.
EEL 3801C EEL 3801 Part I Computing Basics. EEL 3801C Data Representation Digital computers are binary in nature. They operate only on 0’s and 1’s. Everything.
CS 101 – Aug. 31 Interpreting binary  decimal √ Decimal  binary Shorthand ways of expressing binary –Octal –“Hex” Negative numbers.
Hexadecimal Data Representation. Objectives  Know how the Hexadecimal counting system works  Be able to convert between denary, binary & hexadecimal.
THE BINARY NUMBER SYSTEM “There are only 10 types of people in this world: Those who understand BINARY and those who do not.”
DECIMALBINARY a) b) c) d) e) f) Revision Exercise DECIMALBINARY a) b) c)
Binary01.ppt Decimal Decimal: Base 10 means 10 Unique numerical digits ,00010,000 Weight Positions 3,
Springfield Technical Community College Center for Business and Technology.
Octal & Hexadecimal Number Systems
Chapter 2 Binary Values and Number Systems Chapter Goals Distinguish among categories of numbers Describe positional notation Convert numbers in.
1 Digital Logic Design Lecture 2 More Number Systems/Complements.
Arithmetic Chapter 4 Subject: Digital System Year: 2009.
Number Systems. Topics  The Decimal Number System  The Binary Number System  Converting from Binary to Decimal  Converting from Decimal to Binary.
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.
Binary Values. Numbers Natural Numbers Zero and any number obtained by repeatedly adding one to it. Examples: 100, 0, 45645, 32 Negative Numbers.
COMPUTER FUNDAMENTALS David Samuel bhatti
Lecturer: Santokh Singh
Unit 18: Computational Thinking
Binary numbers: Week 7 Lesson 1
Using the Windows Calculator for quick decimal to binary conversions
Number System conversions
Coding Schemes and Number Systems
Data Storage Introduction to computer, 2nd semester, 2010/2011
Binary Quiz UIN: ____________________
Binary Lesson 3 Hexadecimal
Binary Lesson 3 Hexadecimal
Chapter Four Data Representation in Computers By Bezawit E.
Chapter 2 Number Systems.
Chapter 2 Number Systems.
Chapter 2 Number Systems.
COMS 161 Introduction to Computing
Chapter 2 Number Systems.
Presentation transcript:

CIS 234: Numbering Systems Dr. Ralph D. Westfall April, 2010

Problem 1 computers only understand binary coded data (zeros and ones) , , people like to count in decimals =0, =255, =85 1 st problem: it is extremely hard for people to work with binary data

Problem 2 (other Powerpoint)Powerpoint since computers only work with numbers, they need to use numbers to identify letters to print or show on screen e.g., =65=A people who don't read English also use computers 2 nd problem: what kind of numbering should be used for different languages?

Problem 1 Solution making binary easier to work with create numbering systems that are: compatible with binary numbers easier to read than binary

Numbering Systems all numbering systems have a "base" digit position = base raised to a power any number raised to power of zero = 1 decimal system is "base 10" 123 = 1 * 10^2 + 2 * 10^1 + 3 * 10^0 = 1 * * * 1 binary system is "base 2" 1010 = 1 * 2^3 + 0 * 2^2 + 1 * 2^1 + 0 * 2^0 = 1 * * * * 1

Can Convert Between Bases converting binary to decimal 1111 = 1 * 2^3 + 1 * 2^2 + 1 * 2^1 + 1 * 2^0 15 = 1 * * * * 1 binary/decimal conversion is awkward binary & decimal numbers don't match up well (sizes are inconsistent when convert between them) 7=111 (3 bits), 8=1000 (4 bits) 1001=9 (1 digit), 1010=10 (2 digits)

Hexadecimal Numbers (error)error hex means 6, decimal means 10 hexadecimal means base 16 first 9 digits of "hex" same as in decimal 0 is 0, 1 is 1 … 9 is 9 in either system 10 in decimal is a in hex 11=b, 12=c, 13=d, 14=e, 15=f in hex 16=10 in hex example: color codes in HTMLcolor codes in HTML

Conversions hex to decimal is easier than binary 2f = 2 * 16^ * 16^0 = 47 3a = 3 * 16^ * 16^0= 58 hex to binary is even easier one hex digit for every 4 bits f=1111, a=1010, 8= hex digits = 1 byte ff= =255 (Start>All Programs>Accessories>Calculator)Calculator (or Start>Run>calc>OK)

Octal Numbers octal means 8 octopus has 8 legs octal system uses base 8 has not caught on as much as hex 2 octal digits = 6 bits 3 octal digits = 9 bits 1 byte = 8 bits

Data Storage why is the range of the byte data type from –128 to + 127? 8 bits = 1 byte = = =-128binary arithmeticbinary arithmetic =-1 ( = ) sign is in left bit (0=plus, 1=minus)

Numbering System Calculations 01 binary +01 =10 in binary = hexadecimal +9 = a in hex a +1 = b

Microsoft Calculator Does Hex Start>All Programs>Accessories> Calculator View>Scientific (or Start>Run>calc>OK) click Hex radio button and try calculating with hex #s (including A through F keys) click Bin and do binary calculations using only ones and zeros

Review Questions What two digits are used in computer hardware? What does binary mean? Give an example of a binary number What does hexadecimal mean? Give an example of a hexadecimal number Name some advantages of hex numbers over binary ones

Review Questions - 2 Convert 1010 into a decimal number Into a hexadecimal number Convert binary 11 to a decimal number What are the decimal values of the following hexadecimal numbers? 5 a f

Review Questions - 3 Add 10 plus 11 in binary Is a positive or negative number in binary (on a PC)? What is the hexadecimal result of: adding 2 to a? adding ? worksheet