Chapter ONE
IEEE Single Precision has ,
,
,
,
and subnormals are allowed.
In class we have shown that if is a real number, and
is its
floating point representation, then the maximum possible relative error
in representing this number is given by
where is machine precision,
How the equation (1) changes for the subnormals?
To answer this question,
Consider a floating-point arithmetic with base
, precision
and exponent range
. In other words, each number in this system
can be represented as
(a) Find the largest open interval around so that all
real numbers from the interval are rounded to
. That is, find
the smallest value of
and the largest vlue of
with
so
that any number from the interval
is rounded to the floating
point number
. Assume double precision is used (53 binary digits).
(b)
Redo the part (a) for the , that is, find the interval
that rounds to the floating point number
IEEE SP has ,
,
,
.
Calculate ,
and
for this system.
Assume rounding by chopping.
How many floating point numbers are there between any successive
powers of ? For example, how many floating point numbers are there
between 2 and 4?
Consider the floating point system with
(a)
What is the distance from number to
the next largest floating point number in this floating point
system?
(b)
What is the distance from number to the next smallest floating point number in this floating point system?
(c) What distance is larger, (a) or (b)? Why? What is the relation between
these distances and machine precision
?
a) Approximate using third degree Taylor polynomial
expanded about
. Use this expansion to show that
b) Explain why MATLAB would compute the limit of to be 0.
|
|
|
|
|
|
|
|
|
|
|
Please explain in details the values in the right column of this table.
Consider IEEE SP that has binary numbers , with
digits, and lower and upper values of the exponents of
,
. As we discussed in class, the number
is not
representable in IEEE SP. What is the Floating Point Number that
precedes
? In other words, find the largest Floating
Point Number that is less then
.
Hint: your answer should contain 24 binary digits of the mantissa and the value of the exponent.
— addition
— subtraction
— multiplication
— division
If you answered “yes” to any of the questions, please give one example of two Single Precision numbers that produce overflow by given operation.
(b) Which of the following operations of two positive floating point numbers can produce underflow?
— addition
— subtraction
— multiplication
— division
If you answered “yes” to any of the questions, please give one example of two Single Precision numbers that produce underflow by given operation.
Hint: your answer should contain 24 binary digits of the mantissa and the value of the exponent.
— addition
— subtraction
— multiplication
— division
If you answered “yes” to any of the questions, please give one example of two Single Precision numbers that produce overflow by given operation.
(b) Which of the following operations of two positive floating point numbers can produce underflow?
— addition
— subtraction
— multiplication
— division
If you answered “yes” to any of the questions, please give one example of two Single Precision numbers that produce underflow by given operation.
Consider the following expression:
(a) for what values of it is difficult to calculate this
expresion accurately in floating point arithmetic?
(b)Give a rearrangement of the terms such that, for the range of in part
a, the computation is more accurate in floating point system
— For what numbers will the computer claim that inequality
is true?
— For what real numbers will a computer claim that
?
— Suppose it is claimed that the solution of
is
exactly representable in this system. Why it is not possible? What
is the distance between two floating point numbers that is right
above and right below solution of
in this system?
Consider the following claim: If the two positive binary floating
point numbers and
in this toy floating point systems are
such that
Is this claim true or false? If it is true, explain why, if it is false, find counter example.
Please explain why this graph looks the way it does.
In particular, answer the following questions:
IEEE SP has ,
,
,
. In single precision
floating point system write down the floating point number that
follows the number
. (In other words, find minimal value of
, that is exactly representable in this floating point system.
IEEE SP has ,
,
,
. What is the
smallest possible positive integer that is not a single precision
number?
Suppose one calculates using computer arithmetic the following number:
Determine whether the following examples may be used to determine machine precision:
You may find it helpful to use calculator to gain intuition for this problem.
Consider a floating-point number system with base
, precision
and exponent range
I.e., in this system
any number can be written as
(a) Write down two adjacent normalized numbers and
such
that
is minimal.
(b) In this floating-point system, what is the maximal possible
error of representing by a machine number? What is the possible
relative error in representing
by a machine number?
(c) In this floating-point system, how many numbers are there
between number and number
.
The following statments are either true or false. If true, provide
an explanation why it is true, and if it is false provide an example
demonstrating this along with an explanation why it shows the
statement is incorrect. In this problem is a real number and
is its floating-point representation in Single Precision
with subnormals allowed. Furthermore,
is machine
precision (unit round off).
Find whether the following numbers can be exactly represented in the Single Precision IEEE system. If the number is exactly representable, please write down the exact Floating Point Presentation of a number. If not, please explain why this number can not be represented.
What is the largest value of for which the number
Please calculate by hand what a computer with single -precision arithmetic with subnormal allowed would produce in these examples.
Note that the terms must be evaluated in the order indicated by the parenthesis. Make sure to explain your steps.
Assume a decimal (base 10) floating point system having machine
precision
and an exponent range of
. What is the result of each of the following floating point
arithmetic operations?
Chapter TWO
What is the Single Precision Floating Point Number that follows 256 and the Single Precision Floating Point Number that preceeds 256? Write the answer in both binaries and decimals.