Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes(32 bits), -2147483648<4-B integer<2147483647 o All fixed-pointed numbers have the same absolute error of 2-m-1 o Advantage:large number of significant digits. oDisadvantace:relative small range of numbers.small numbers have large relative errors. 1口“4元,4元↑重QC Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/201581103
Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes (32 bits), −2147483648 < 4-B integer < 2147483647 All fixed-pointed numbers have the same absolute error of 2 −m−1 . Advantage: large number of significant digits, Disadvantage: relative small range of numbers, small numbers have large relative errors. Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/2015 8 / 103
Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes(32 bits), -2147483648<4-B integer<2147483647 o All fixed-pointed numbers have the same absolute error of 2-m-1 o Advantage:large number of significant digits. o Disadvantage:relative small range of numbers.small numbers have large relative errors. 1口“4元,4元↑重QC Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/201581103
Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes (32 bits), −2147483648 < 4-B integer < 2147483647 All fixed-pointed numbers have the same absolute error of 2 −m−1 . Advantage: large number of significant digits, Disadvantage: relative small range of numbers, small numbers have large relative errors. Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/2015 8 / 103
Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes(32 bits), -2147483648<4-B integer<2147483647 o All fixed-pointed numbers have the same absolute error of 2-m-1. o Advantage:large number of significant digits, o Disadvantage:relative small range of numbers,small numbers have large relative errors. 1口“4元,4元↑重QC Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/201581103
Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes (32 bits), −2147483648 < 4-B integer < 2147483647 All fixed-pointed numbers have the same absolute error of 2 −m−1 . Advantage: large number of significant digits, Disadvantage: relative small range of numbers, small numbers have large relative errors. Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/2015 8 / 103
Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes(32 bits), -2147483648<4-B integer<2147483647 o All fixed-pointed numbers have the same absolute error of 2-m-1. o Advantage:large number of significant digits, o Disadvantage:relative small range of numbers,small numbers have large relative errors. 1口“4元,4元↑重QC Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/201581103
Computer Number Representation Fixed-Point Notation Integers are typically 4 bytes (32 bits), −2147483648 < 4-B integer < 2147483647 All fixed-pointed numbers have the same absolute error of 2 −m−1 . Advantage: large number of significant digits, Disadvantage: relative small range of numbers, small numbers have large relative errors. Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/2015 8 / 103
Computer Number Representation Scientific/Engineering Notation The speed of light c=+ 0.299792458×10t9m/s in engineering sign mantissa exponents notation or0.299795498E09m/s 1口“4元,4元↑重QC Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/20159/103
Computer Number Representation Scientific/Engineering Notation The speed of light c = + |{z} 0.299792458 | {z } ×10 +9 |{z}m/s sign mantissa exponents or 0.299795498 E09 m/s in engineering notation number of bits stored for exponents → the range of the number number of bits stored for mantissa → the number of significant bits Search for a compromise. Weihua Gu (Shanghai Jiao Tong University) Computational Physics Chapter 1 14/09/2015 9 / 103