You are on page 1of 3

Mock Quiz #2

1. What are underflow and overflow?

2. For the following, find the smallest number, x, such that


(Double Precision)
a. 1 + 𝑥 = 1. Find the absolute error and relative error.
5051 552
1.585...0000 20
1
x
1 =

x 0.000...0001X2
=


bit does not
53
exist and
-

x 1
gettruncated.
=
b. 260 + 𝑥 = 260

I
60
21,000...000 = x26
60

x 0.000...0001X2
=

-> x
(53.2627
= =

2.1(264x) 24)
- 27
=

xx) 70x) / -
(8/ - 25
Evel =

(260 x) +


260

c. 0.25 + 𝑥 = 0.25.
very small
compared to.20

55
559 2
-
- 2 -

x 2
=
=

((2
+
x) -
2-)
Ex =
3. Suppose 𝑥1 = −𝑏 + √𝑏 2 + 1 and 𝑥2 = −𝑏 − √𝑏 2 + 1 . Prove that 𝑥1 𝑥2 = −1

-
4. Assuming the square root operation does not cause any rounding errors, at what value of 𝑏 does the solution to one of the above equations
become inexact.
root does not cause
thatsquare
Assuming
rounding error, T =b
when
concellation happens
1
b
1
5
=

1 b
+

+
= =>
=>

(b vi3.)
- 53

tz
2
=>
=

=> =

You might also like