Representation of Data (Part II) Computer Studies Notes: chapter 19 Ma King Man.

Slides:



Advertisements
Similar presentations
Computer Engineering FloatingPoint page 1 Floating Point Number system corresponding to the decimal notation 1,837 * 10 significand exponent A great number.
Advertisements

Floating Point (FLP) Representation A Floating Point value: f = m*r**e Where: m – mantissa or fractional r – base or radix, usually r = 2 e - exponent.
Faculty of Computer Science © 2006 CMPUT 229 Floating Point Representation Operating with Real Numbers.
Chapter 1.7 Storing Fractions. Excess Notation, continued… In this notation, "m" indicates the total number of bits. For us (working with 8 bits), it.
CS 447 – Computer Architecture Lecture 3 Computer Arithmetic (2)
Computer ArchitectureFall 2007 © September 5, 2007 Karem Sakallah CS 447 – Computer Architecture.
1 CSE1301 Computer Programming Lecture 30: Real Number Representation.
Booth’s Algorithm.
Lecture 3 Number Representation 2 This week – Recap Addition – Addition circuitry – Subtraction of integers in binary – Representing numbers with fractional.
Chapter 5 Floating Point Numbers. Real Numbers l Floating point representation is used whenever the number to be represented is outside the range of integer.
1 Lecture 3 Bit Operations Floating Point – 32 bits or 64 bits 1.
Floating Point Numbers
Floating Point Numbers
Computer ArchitectureFall 2008 © August 27, CS 447 – Computer Architecture Lecture 4 Computer Arithmetic (2)
Computer Science 210 Computer Organization Floating Point Representation.
Binary Number Systems.
Chapter 3 Data Representation part2 Dr. Bernard Chen Ph.D. University of Central Arkansas Spring 2010.
Chapter3 Fixed Point Representation Dr. Bernard Chen Ph.D. University of Central Arkansas Spring 2009.
The Binary Number System
Binary Real Numbers. Introduction Computers must be able to represent real numbers (numbers w/ fractions) Two different ways:  Fixed-point  Floating-point.
Computer Arithmetic Nizamettin AYDIN
2-1 Chapter 2 - Data Representation Principles of Computer Architecture by M. Murdocca and V. Heuring © 1999 M. Murdocca and V. Heuring Chapter Contents.
NUMBER REPRESENTATION CHAPTER 3 – part 3. ONE’S COMPLEMENT REPRESENTATION CHAPTER 3 – part 3.
Fixed-Point Arithmetics: Part II
Chapter 1 Data Storage(3) Yonsei University 1 st Semester, 2015 Sanghyun Park.
Number Systems So far we have studied the following integer number systems in computer Unsigned numbers Sign/magnitude numbers Two’s complement numbers.
Computer Architecture
Fundamental of Computer Architecture By Panyayot Chaikan November 01, 2003.
Topic 2 – Introduction to Computer Codes. Computer Codes A code is a systematic use of a given set of symbols for representing information. As an example,
Floating Point. Agenda  History  Basic Terms  General representation of floating point  Constructing a simple floating point representation  Floating.
Floating Point (a brief look) We need a way to represent –numbers with fractions, e.g., –very small numbers, e.g., –very large numbers,
9.4 FLOATING-POINT REPRESENTATION
Binary Fractions. Fractions A radix separates the integer part from the fraction part of a number Columns to the right of the radix have negative.
Floating Point Representations CDA 3101 Discussion Session 02.
Representation of Data Ma King Man. Reference Text Book: Volume 2 Notes: Chapter 19.
The Teacher CP4 Binary and all that… CP4 Revision.
Fixed and Floating Point Numbers Lesson 3 Ioan Despi.
Round-off Errors and Computer Arithmetic. The arithmetic performed by a calculator or computer is different from the arithmetic in algebra and calculus.
Negative Numbers An alternative way to find the 2's complement Starting at the right 1. Copy bits until you reach the first Flip all the remaining.
CSC 221 Computer Organization and Assembly Language
ITEC 1011 Introduction to Information Technologies 4. Floating Point Numbers Chapt. 5.
The Teacher CP4 Binary and all that… CP4 Revision.
1 Number Systems Lecture 10 Digital Design and Computer Architecture Harris & Harris Morgan Kaufmann / Elsevier, 2007.
Floating Point Arithmetic
Integer and Fixed Point P & H: Chapter 3
Computer Architecture Lecture 22 Fasih ur Rehman.
PHY 201 (Blum)1 Shift registers and Floating Point Numbers Chapter 11 in Tokheim.
IT11004: Data Representation and Organization Floating Point Representation.
CS 232: Computer Architecture II Prof. Laxmikant (Sanjay) Kale Floating point arithmetic.
©Brooks/Cole, 2003 Chapter 3 Number Representation.
COMPUTER SCIENCE Data Representation and Machine Concepts Section 1.7 Instructor: Lin Chen Sept 2013.
PHY 201 (Blum)1 Shift registers and Floating Point Numbers Chapter 11 in Tokheim.
Lecture 6: Floating Point Number Representation Information Representation: Floating Point Number Representation Lecture # 7.
Fixed-point and floating-point numbers Ellen Spertus MCS 111 October 4, 2001.
Floating Point (FLP) Representation
FLOATING-POINT NUMBER REPRESENTATION
Floating Point Numbers
Department of Computer Science Georgia State University
Fundamentals of Computer Science
Introduction To Computer Science
CS 232: Computer Architecture II
PRESENTED BY J.SARAVANAN. Introduction: Objective: To provide hardware support for floating point arithmetic. To understand how to represent floating.
Floating Point Numbers
IT11004: Data Representation and Organization
Numbers with fractions Could be done in pure binary
Presentation transcript:

Representation of Data (Part II) Computer Studies Notes: chapter 19 Ma King Man

Floating-point number representation E.g (2) can be written as x 2 1 or x 2 2 or x 2 3 (Normalized form)

Format The basic format is shown as follow: Sign bit Exponent Mantissa Sign bitExponentMantissa

Note… Excess 128 method That is, add 128 to the current value.

Eg 1 Assume 16-bit word and EXCESS 128 method is used: = (ii) = x 2 4 Fraction= Exponent= 4 x 128 = 132 = (ii) Since the number is positive, therefore the sign bit is 0. Therefore will be stored as

E.g = (ii) = x 2 5 (normalization) Fraction= Fraction= = 133 = (ii) Since the number is negative, therefore the sign bit is 1. Therefore –29.75 will be stored as

E.g = (ii) = -0.1 x 2 -3 (normalization) Fraction= Exponent= = 125 = (ii) Since the number is negative, therefore the sign bit is1. Therefore – will be stored as

Comparison between fixed-point representation and floating point representation Range Fixed-point numbers Largest positive number = = Smallest negative number= = Therefore, in 16-bit word storage: <= fixed point number <=

Floating-point representation AAssume excess-128 method and 16-bit word is used, a dloating point representation cab have the following values: Largest positive number=   Smallest positive number=  

More… Largest negative number=   Smallest negative number=  

More…thus… Therefore, the range of floating number:  , 0,  From the above, we can see that the range of the floating-point representation is wider than that of fixed-point representation.