This preview has intentionally blurred sections. Sign up to view the full version.View Full Document
Unformatted text preview: AMSC/CMSC 460 Dr. Wolfe FINAL EXAM July 25, 2008 1. (10 points) Recall that in any computation the relative error is deﬁned as Ierrorl
rel. error = [true valuel ' We are concerned with the evaluation of a function f (as)
(a) Show that if the error in a; is small The quantity K, 2 la: 1“ (ac) / f (93)l can be considered the condition number of f at :13. If H, is large we say f is ill—conditioned at x. If H is small we say that f is well—conditioned at x. _ (b) Show that for any x > 0, f (as) = ﬂ is well—conditioned while for a: near 77/ 2,
f (as) = cosx is ill—conditioned. What about f (at) = sinx near a: = 0 ? -rel. error in ac. 2. (5 points) The following statements pertain to the solution of Ax = b in ﬂoating point
arithmetic. Complete them so they are meaningful and true.
(a) Gauss elimination with partial pivoting almost always gives good results if A (b) For any A, Guass elimination with partial pivoting is virtually guaranteed to produce
MC 5) 3. (17 points) Let (a) Compute the Choleski factorization of A (A = LLT with L lower triangular) and
use it to solve Ax 2 b with b = (9, 9)T. (b) Find an approximate solution to Ax = b by doing two Jacobi iterations starting
at 2:03) = (1, 2)T. (c) Find an approximate solution to AX = b by doing two Gauss—Seidel iterations
starting at x(0) = (1, 2)T. (d) Which method gives a better approximation to the exact solution ? ‘ 4.“(14 points) Given the data points (0,2) , (0.5, 5), (1, 4)
(a) Find the quadratic polynomial 102(33) interpolating the data.
(b) Find the function P(x) = a + bcos(7r:1:) + csin(7rcc), which interpolates the data. 5. (12 points) Given the data points (—2, 2) , (*1, 1) , (0, 2) , (1, 2), ﬁnd the function g(:c)
of the form g(x) = cllxl + 02062 which best ﬁts this data in the sense of least squares. ,\.. 6. (15 points) Let 1
I = / dz; = 5108256238
_1 a: + 4 Compute approximations to I using (a) The 4 panel trapezoid rule. (b) The 4 panel Simpson’s rule. (0) The two point Gauss—Legendre rule. (Recall that the nodes for this are if) Which method gives the best result ? 7. (12 points)
(a) What are the solutions a, if any, of the equation :1: = 3x — 2 ?
(b) Does the iteration mn+1 = x/3xn — 2 converge to any of these solutions (assuming
x0 is chosen suﬁiciently close to 0:)? Explain. (We need some analysis, not just
numerical evidence.) 8. (15 points) Consider the initial value problem fig_ —t2 122.
dt y, y() (a) Verify that the solution is Y(t) = 23%-
Find approximations to Y(1.2) by using (b) two steps of the Euler method with h = .1. (0) one step of the Improved Euler method with h = .2. In (b) and (0) compare your answers with the exact solution. ...
View Full Document
- Spring '08