14/02/2016 1 Floating Point Representation Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker Presented.

Slides:



Advertisements
Similar presentations
8/25/ Floating Point Representation Major: All Engineering Majors Authors: Autar Kaw, Matthew Emmons
Advertisements

5/1/ Finite Difference Method Civil Engineering Majors Authors: Autar Kaw, Charlie Barker
1 Direct Method of Interpolation Electrical Engineering Majors Authors: Autar Kaw, Jai Paul
Mechanical Engineering Majors Authors: Autar Kaw, Charlie Barker
5/19/ Runge 4 th Order Method Mechanical Engineering Majors Authors: Autar Kaw, Charlie Barker
7/2/ Backward Divided Difference Major: All Engineering Majors Authors: Autar Kaw, Sri Harsha Garapati
8/8/ Euler Method Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker
8/15/ Binary Representation Major: All Engineering Majors Authors: Autar Kaw, Matthew Emmons
8/30/ Secant Method Major: All Engineering Majors Authors: Autar Kaw, Jai Paul
9/14/ Trapezoidal Rule of Integration Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker
1 Spline Interpolation Method Computer Engineering Majors Authors: Autar Kaw, Jai Paul
9/20/ Secant Method Civil Engineering Majors Authors: Autar Kaw, Jai Paul
9/22/ Runge 2 nd Order Method Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker
10/8/ Propagation of Errors Major: All Engineering Majors Authors: Autar Kaw, Matthew Emmons
1 Lagrangian Interpolation Major: All Engineering Majors Authors: Autar Kaw, Jai Paul
1 Newton’s Divided Difference Polynomial Method of Interpolation Chemical Engineering Majors Authors: Autar Kaw, Jai.
10/20/ Runge 2 nd Order Method Chemical Engineering Majors Authors: Autar Kaw, Charlie Barker
1 Newton’s Divided Difference Polynomial Method of Interpolation Major: All Engineering Majors Authors: Autar Kaw,
5/30/ Runge 4 th Order Method Chemical Engineering Majors Authors: Autar Kaw, Charlie Barker
11/16/ Euler Method Electrical Engineering Majors Authors: Autar Kaw, Charlie Barker
11/17/ Shooting Method Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker
11/30/ Secant Method Industrial Engineering Majors Authors: Autar Kaw, Jai Paul
12/1/ Trapezoidal Rule of Integration Civil Engineering Majors Authors: Autar Kaw, Charlie Barker
1 Lagrangian Interpolation Computer Engineering Majors Authors: Autar Kaw, Jai Paul
1 Direct Method of Interpolation Major: All Engineering Majors Authors: Autar Kaw, Jai Paul
1/16/ Runge 4 th Order Method Civil Engineering Majors Authors: Autar Kaw, Charlie Barker
1/19/ Runge 4 th Order Method Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker
1 Direct Method of Interpolation Computer Engineering Majors Authors: Autar Kaw, Jai Paul
1 Direct Method of Interpolation Mechanical Engineering Majors Authors: Autar Kaw, Jai Paul
2/28/ Runge 4 th Order Method Computer Engineering Majors Authors: Autar Kaw, Charlie Barker
1 Newton’s Divided Difference Polynomial Method of Interpolation Mechanical Engineering Majors Authors: Autar Kaw,
1 Spline Interpolation Method Mechanical Engineering Majors Authors: Autar Kaw, Jai Paul
3/12/ Trapezoidal Rule of Integration Computer Engineering Majors Authors: Autar Kaw, Charlie Barker
Fixed-point and floating-point numbers Ellen Spertus MCS 111 October 4, 2001.
3/20/ Trapezoidal Rule of Integration Chemical Engineering Majors Authors: Autar Kaw, Charlie Barker
6/13/ Secant Method Computer Engineering Majors Authors: Autar Kaw, Jai Paul
Introduction to Numerical Analysis I
Trapezoidal Rule of Integration
Civil Engineering Majors Authors: Autar Kaw, Charlie Barker
Computer Engineering Majors Authors: Autar Kaw, Charlie Barker
Differentiation-Discrete Functions
Newton’s Divided Difference Polynomial Method of Interpolation
Civil Engineering Majors Authors: Autar Kaw, Charlie Barker
Spline Interpolation Method
Mechanical Engineering Majors Authors: Autar Kaw, Charlie Barker
Chemical Engineering Majors Authors: Autar Kaw, Charlie Barker
Floating Point Representation
Direct Method of Interpolation
Spline Interpolation Method
Lagrangian Interpolation
Civil Engineering Majors Authors: Autar Kaw, Charlie Barker
Newton’s Divided Difference Polynomial Method of Interpolation
Trapezoidal Rule of Integration
Lagrangian Interpolation
Binary Representation
Industrial Engineering Majors Authors: Autar Kaw, Charlie Barker
Binary Representation
Newton’s Divided Difference Polynomial Method of Interpolation
Binary Representation
Lagrangian Interpolation
Lagrangian Interpolation
Simpson’s 1/3rd Rule of Integration
Romberg Rule of Integration
Simpson’s 1/3rd Rule of Integration
Electrical Engineering Majors Authors: Autar Kaw, Charlie Barker
Romberg Rule of Integration
Spline Interpolation Method
Chemical Engineering Majors Authors: Autar Kaw, Charlie Barker
Newton’s Divided Difference Polynomial Method of Interpolation
Lagrangian Interpolation
Presentation transcript:

14/02/ Floating Point Representation Major: All Engineering Majors Authors: Autar Kaw, Charlie Barker Presented by: دکتر ابوالفضل رنجبر نوعی Transforming Numerical Methods Education for STEM Undergraduates

Floating Point Representation /02/20162http://numericalmethods.eng.usf.e du

3 Floating Decimal Point : Scientific Form 14/02/2016

Example The form is or Example: For 14/02/2016

Floating Point Format for Binary Numbers 1 is not stored as it is always given to be 1. 14/02/2016

Example 9 bit-hypothetical word  the first bit is used for the sign of the number,  the second bit for the sign of the exponent,  the next four bits for the mantissa, and  the next three bits for the exponent We have the representation as Sign of the number mantissa Sign of the exponent exponent 14/02/2016

Machine Epsilon Defined as the measure of accuracy and found by difference between 1 and the next number that can be represented 14/02/2016

Example Ten bit word  Sign of number  Sign of exponent  Next four bits for exponent  Next four bits for mantissa Next number 14/02/2016

Relative Error and Machine Epsilon The absolute relative true error in representing a number will be less then the machine epsilon Example 10 bit word (sign, sign of exponent, 4 for exponent, 4 for mantissa) Sign of the number mantissa Sign of the exponent exponent 14/02/2016

IEEE 754 Standards for Single Precision Representation 14/02/201610http://numericalmethods.eng.usf.e du

IEEE-754 Floating Point Standard Standardizes representation of floating point numbers on different computers in single and double precision. Standardizes representation of floating point operations on different computers. 14/02/201611http://numericalmethods.eng.usf.e du

One Great Reference What every computer scientist (and even if you are not) should know about floating point arithmetic! 14/02/201612http://numericalmethods.eng.usf.e du

13 IEEE-754 Format Single Precision 32 bits for single precision Sign (s) Biased Exponent (e’) Mantissa (m) 14/02/201613http://numericalmethods.eng.usf.e du

14 Example# Sign (s) Biased Exponent (e’) Mantissa (m) 14/02/201614http://numericalmethods.eng.usf.e du

15 Example#2 ???????????????????????????????? Sign (s) Biased Exponent (e’) Mantissa (m) Represent x10 10 as a single precision floating point number. 14/02/201615http://numericalmethods.eng.usf.e du

16 Exponent for 32 Bit IEEE bits would represent Bias is 127; so subtract 127 from representation 14/02/201616http://numericalmethods.eng.usf.e du

Exponent for Special Cases Actual range of andare reserved for special numbers Actual range of 14/02/201617http://numericalmethods.eng.usf.e du

Special Exponents and Numbers all zeros all ones smRepresents 0all zeros all onesall zeros 1all onesall zeros 0 or 1all onesnon-zeroNaN 14/02/201618http://numericalmethods.eng.usf.e du

19 IEEE-754 Format The largest number by magnitude The smallest number by magnitude Machine epsilon 14/02/201619http://numericalmethods.eng.usf.e du

Additional Resources For all resources on this topic such as digital audiovisual lectures, primers, textbook chapters, multiple-choice tests, worksheets in MATLAB, MATHEMATICA, MathCad and MAPLE, blogs, related physical problems, please visit presentation.html 14/02/201620http://numericalmethods.eng.usf.e du

THE END 14/02/201621http://numericalmethods.eng.usf.e du