CS 104 Introduction to Computer Science and Graphics Problems Data Representation(1) Number Systems 09/12 ~ 09/16 /2008 Yang Song (Prepared by Yang Song.

Slides:



Advertisements
Similar presentations
Base 10 Denary Decimal
Advertisements

2.2 General Positional-Number-System Conversion
Binary Expression Numbers & Text CS 105 Binary Representation At the fundamental hardware level, a modern computer can only distinguish between two values,
Binary Aim: Explain binary and binary units Objective 1: Convert positive denary whole numbers (0-255) into 8-bit binary numbers and vice versa Objective.
Computer Systems 1 Fundamentals of Computing
Binary Numbers.
Data Representation in Computers. Data Representation in Computers/Session 3 / 2 of 33 Number systems  The additive approach – Number earlier consisted.
Bits, Bytes, KiloBytes, MegaBytes, GigaBytes & TeraBytes.
Memory Terminology & Data Representation CSCI 1060 Fall 2006.
Numbering systems.
1 Machine Architecture and Number Systems Topics Major Computer Components Bits, Bytes, and Words The Decimal Number System The Binary Number System Converting.
Machine Architecture CMSC 104, Section 4 Richard Chang 1.
Number Systems. Today Decimal Hexadecimal Binary –Unsigned Binary –1’s Complement Binary –2’s Complement Binary.
NUMBER SYSTEM.
Lecture 2 Bits, Bytes & Number systems
Number systems, Operations, and Codes
The Hexadecimal Number System and Memory Addressing ISAT 121.
Number System. Number Systems Important Number systems – Decimal – Binary – Hexadecimal.
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.
Computer Systems Nat 4/5 Computing Science Data Representation Lesson 2: Floating Point Representation.
Chapter 2 Data Representation.
Working with 8-bit bytes and hexadecimal
Networking for Home and Small Businesses –.  Explain the binary representation of data.
NUMBER SYSTEM. Number System Number Base B => B symbols – Base 16(Hexa):0, 1,……9, A,…, E, F – Base 10 (Decimal): 0, 1, 2,……, 7, 8, 9 – Base 8(Octal):
2.1.4 Data Representation Units.
* Numeral Systems: A writing method for expressing numbers is called a “Numeral System". In the most common numeral system, we write numbers with combinations.
ASCII AND EBCDIC CODES By : madam aisha.
Binary Decimal Hexadecimal
ABFC... Home page Introduction Binary number system Hexadecimal number system Binary coded decimal Objectives Octal number system Click.
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.
Understanding Computers
Binary a. express numbers in binary, binary-coded decimal (BCD), octal and hexadecimal;
Base 16 (hexadecimal) Uses the decimal digits and the first letters of the alphabet to encode 4 binary bits (16=2 4 ) abcdef or ABCDEF.
Binary Numbers. Base 10 and Base 2  We normally work with numbers in base 10.  In base 10 we use the digits 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9.  Everything.
Understanding Binary Understanding Computers. Understanding Computers L3 – Understanding Binary Learning Objectives All will Understand why all data is.
Prepared By: Norakmar Binti Mohd Nadzari CHAPTER 2 ARITHMETIC AND LOGIC UNIT.
 Human language : commonly used to express feeling and understand what other people expression.  Computer language : are a languages by which a user.
© OCR 2016 Unit 2.6 Data Representation Lesson 1 ‒ Numbers.
Binary & Hex Review.
Decimal Numbers.
Unit 2.6 Data Representation Lesson 1 ‒ Numbers
Understanding binary Understanding Computers.
Computer basics.
© 2003, Cisco Systems, Inc. All rights reserved.
Consider this number: , Ones (7 ones) Tens (no tens)
Octal to Decimal Decimal Octal Binary Hexadecimal.
Discrete Mathematics Numbering System.
COMPUTER ORGANIZATION
Positional Notation A positional or place-value notation is a numeral system in which each position is related to the next by a constant multiplier, called.
Numerical Representation
What is Binary? Binary is a two-digit (Base-2) numerical system, which computers use to process and store data. The reason computers use the binary system.
Unit 2.6 Data Representation Lesson 1 ‒ Numbers
Writer:-Rashedul Hasan. Editor:- Jasim Uddin
CSE 102 Introduction to Computer Engineering
Chapter 3 Data Representation
इंट्रस्टिंग बनने के लिए आपको इंट्रस्टेड होना पड़ेगा।
Introduction to IT By: Muhammed s. anwar.
Computers & Programming Languages
Binary Lesson 3 Hexadecimal
Binary Lesson 3 Hexadecimal
Binary Lesson 3 Hexadecimal
Numerical Representation
Binary Lesson 3 Hexadecimal
Chapter Four Data Representation in Computers By Bezawit E.
Numeral systems (radix)
Binary System.
Binary Lesson 4 Hexadecimal and Binary Practice
Binary & Hex Review.
Presentation transcript:

CS 104 Introduction to Computer Science and Graphics Problems Data Representation(1) Number Systems 09/12 ~ 09/16 /2008 Yang Song (Prepared by Yang Song and Suresh Solaimuthu)

Did you see this T-shirt before? There are 10 types of people; those who understand binary and those who don't.

What is Data? In computer science, data is any information in a form suitable for use with a computer. In an alternate usage, binary files (which are not human-readable) are sometimes called “data”, as distinguished from human-readable “text”.

Numerals and Number Systems Arabic Numerals: 1, 2, 3, …. Roman Numerals: I, II, III, …. Others? 一, 二, 三, …. Decimal System Uses ten digits 0 ~ 9 Base =? 4x x x x10 0 Binary System Uses 2 digits 0, 1 Base 2

Some Units for Computer Bit: single Binary Digit - 1, 0. Nibble (Nybble): 4-bit aggregation Byte (Octet): 8-bit aggregation Bigger ones? - KiloByte (KB): 2 10 (1,024) bytes - MegaByte (MB): 2 20 (1,048,576) bytes - GigaByte (GB): 2 30 (1,073,741,824) bytes

Decimal and Binary Computer “reads” binary Simple Only two symbols How can we convert them?

Binary  Decimal The value of each position For Base 10, it is 10 0, 10 1, 10 2, 10 3 … etc. For Base 2, so, 2 0, 2 1, 2 2, 2 3 … etc. Convert binary into decimal: So it is: = 11 Position Value8421 Binary1011 Actual8x14x02x11x1

Decimal  Binary Division: Decimal number is the dividend, divisor is the “base”, so it’s 2 now, quotient becomes new dividend and save the remainder…until quotient < base, trace back from the last quotient to ALL the remainders. Decimal 11: so, it’s Dividend1152 Quotient521 Remainder110

Another example Convert 40 (decimal) into binary number: So it is: Can you convert decimal into base-7 number? Dividend Quotient Remainder00010

Octal Number Octal has 8 symbols: 0, 1, 2, 3….7 Base 8 Convert into decimal: 1x x x x8 0 = Convert back? Convert into octal: Group them into 3 bits (why?)  Can you confirm this? Dividend Quotient Remainder074

Hexadecimal Number Hexadecimal uses sixteen symbols: 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F Base 16 Range of a Byte: 00 ~ FF, why? Convert A2C into decimal 10x x x16 0 = Convert into Hexadecimal number? Convert into hexadecimal Group into 4 bits (why?)  51F 16 Confirm this one? Dividend Quotient162A(10) RemainderC(12)2