M371 - Alexiades
Problem Set 1 - For practice - To learn
Turn in on paper (will record and return to you). It won't be graded.
- For each expression below, describe the operations ( + − * / )
that could cause negligible addition, error magnification,
or subtractive cancelation, and for what sort of x values
(e.g. x near 2 , x >> 1 , etc) such errors might occur:
a. SQRT( x2 + 1 ) − x
b. 1 + cos x
c. x / ( x + 1 ) − 1
- A real number x is represented approximately by 0.6032,
and we are told that the (absolute) relative error is 0.1% . What is x ?
Note: There are two answers.
- What is the relative error involved in rounding 4.9997 to 5.0 ?
- Consider the numbers a=123.45 and b=0.06543 on a 4-digit decimal machine that rounds. Do BY HAND:
a. Write down their normalized floating point representations fl(a), fl(b) on this machine.
b. Find the exact d = a − b (at full precision) and D = fl(a) − fl(b). Do fl(d) and fl(D) match?
c. What value will the machine produce for the difference d ?
d. Find the error |d − fl(D)|. To how many digits is fl(D) accurate?
- Count the number of operations involved in evaluating a 5th degree polynomial
as commonly written and by using nested multiplication.
- How can these polynomials be evaluated efficiently ?
a. p(x) = x12
b. p(x) = 6(x+2)3 + 9(x+2)7 + 3(x+2)15 − (x+2)31
- The value of π (pi) can be generated to near machine precision by pi = 4.0 atan(1.e0).
Suggest at least one other way to compute pi using basic functions on your computer system.
- Determine the first two nonzero terms of the series expansion about zero of the function ecos x
- How many terms are needed in the series expansion of ex
to compute ex for |x|<1/2 accurate to 12 decimals ?
- Find an upper bound for the quantity |cos(x) − 1 + x2/2| when |x|<1/2.
This is the remainder of the 2-term Taylor expansion of cos(x).