Review of Chapters 0, 1, and 2
The questions below are meant to stimulate the preparation
of the final exam, concerning chapters 0, 1, and 2.
They cover some of the most important but not all topics.
You must review all course materials: textbook, homework exercises,
lecture notes (also consult the course web site), and quizzes.
Also please review the computer projects.
- Consider the representation of floating-point numbers with base 2
and 3 digits in the fraction part.
The values for the exponents are between -16 and +16.
- What is the machine precision is this number system?
- Represent the numbers 7 and 6 as floating point numbers
and illustrate the calculation of 7+6 and 7-6.
-
Let f(x) = x/(x-1). Consider the following values for x:
a random number, a point close to the origin (i.e.: |x| < delta),
and a point close to 1 (i.e.: |x - 1| < delta).
Answer the following:
- What is the difference in relative and absolute error in
the evaluation of f(x) for these three points?
- Assuming there is a small error of delta on the three points,
what is effect of this error on the function value?
- Discuss the difference in numerical conditioning between the
root finding and the evaluation problem.
- Find an approximation for the square root of 4.12.
- Apply three steps of the bisection method, starting with
the interval [2,2.1]. Complete the following table,
using four decimal places:
---------------------------------------------------------------------------
k a(k) b(k) (a(k)+b(k))/2 f(a(k)) f(b(k)) f((a(k)+b(k)/2)
===========================================================================
0 2.000 2.100
1
2
---------------------------------------------------------------------------
- Apply three steps of the secant method, starting with
x_0 = 1 and x_1 = 2. Complete the following table,
using four decimal places:
-------------------------------------------------------------------
k x(k) x(k+1) x(k+2) f(x(k)) f(x(k+1)) f((x(k+2))
===================================================================
0 1.000 2.000
1
2
-------------------------------------------------------------------
- Use Newton's method, starting at 2, until you are sure
you have eight decimal places correct.
Make a table with four columns, containing the respective
values for k, x(k), f(x(k)), and f(x(k))/f'(x(k)).
Write x(k) with as many decimal places as your calculator
shows. Give the values for f(x(k)) and f(x(k))/f'(x(k)) in
scientific format, using four decimal places.
- Apply three steps of the golden section search method to find
then minimum of f(x) = x^3 - x in the interval [0,1].
Write the values for a, b, x1, x2, f(x1), and f(x2)
in the table (4 decimal places):
---------------------------------------------------------------------------
k a b x1 x2 f(x1) f(x2)
===========================================================================
0 0.000 1.000
1
2
---------------------------------------------------------------------------
- What is error propagation? Illustrate the propagation of
errors with a method we have seen during the course.
- The following fixed-point iterations all have the same
fixed point, i.e.: 1.
- x(k+1) = 3 - 2 x(k)^3, k=0,1,...
- x(k+1) = 3/(2 x(k)^2 + x(k)), k=0,1,...
- x(k+1) = (4 x(k)^3 + 3)/(6 x(k)^2+1), k=0,1,...
For each of the three fixed-point iterations, make a cobweb picture
illustrating the convergence (or divergence), starting at x(0) = 0.9.
Compute the convergence (or divergence) rate for each iteration.
Which iteration is best?
-
Consider the linear system
-1.000 x_1 - 1.000 x_2 + 1.000 x_3 = -1.000
1.000 x_1 - 1.000 x_2 + 0.000 x_3 = 0.000
2.000 x_1 + 0.000 x_2 + 1.000 x_3 = 3.000
- Use Gaussian elimination to compute an LU decomposition
in the following two ways:
- without partial pivoting;
- with partial pivoting;
- Solve the system two times, using the two LU
decompositions obtained from above.
- Compute the determinant using the two LU decompositions
obtained from above.
- Use the second LU decomposition you obtained to compute A^(-1)
and cond(A) with ||.||_1.
FINAL EXAM is in BH 0309 on Monday 29 April 2002, from 1 till 3PM.