Docsity

Numerical Analysis Sample Test Solutions for Math 527/CSCE 561, Exams of Mathematical Methods for Numerical Analysis and Optimization

Toggle sidebar
bg1
Math 527/CSCE 561 - Numerical Analysis
Tuesday February 14, 2006
Sample Test # 1
1. For small x, consider the function f(x) = cos(3x)−sin(x).
a) Compute the first four terms of the Taylor polynomial approximation of fabout a= 0.
b) Compute the error term.
c) For which values of xis this Taylor approximant good to within an error of at most .0001?
d) What is a good upper bound for the relative error of the approximation for the interval
|x|< .1?
2. Compute the following base conversions.
a) (1001101.101101)2= ()8= ()10
b) (124.33)10 = ()2[Note: Carry out to at most 9 places]
3. Consider evaluating the function
f(x) = 2(1 −cos(x)) −x2
in finite precision arithmetic.
a) At what values x0will there be a loss of significant bits when the library function for cos is
used? Explain in 1-2 sentences.
b) Use Taylor series at these points to repair the approximate evaluation for f. What is the
approximation?
c) Using this repair, is the maximal error if |x| ≤ .1?
d) Write the pseudo-code that avoids loss of significance and returns accurate values of f.
4. Consider all positive solutions to the equation
e−x=x(1)
a) How many positive solutions are there?
b) Perform three iterations of the bisection method to approximate the smallest solution of
this equation.
c) Provide the error estimate guaranteed by the theory.
5. Consider again all solutions to equation (??).
a) With a starting value of x0= 0, compute the first three iterations {x1, x2, x3}of Newton’s
method.
b) Provide the error estimate guaranteed by the theory.
c) Determine the number of significant digits accuracy the next iterate x4will provide.

Partial preview of the text

Download Numerical Analysis Sample Test Solutions for Math 527/CSCE 561 and more Exams Mathematical Methods for Numerical Analysis and Optimization in PDF only on Docsity!

Math 527/CSCE 561 - Numerical Analysis Tuesday February 14, 2006 Sample Test # 1

  1. For small x, consider the function f (x) = cos(3x) − sin(x). a) Compute the first four terms of the Taylor polynomial approximation of f about a = 0. b) Compute the error term. c) For which values of x is this Taylor approximant good to within an error of at most .0001? d) What is a good upper bound for the relative error of the approximation for the interval |x| < .1?
  2. Compute the following base conversions. a) (1001101.101101) 2 = () 8 = () 10 b) (124.33) 10 = () 2 [Note: Carry out to at most 9 places]
  3. Consider evaluating the function

f (x) = 2(1 − cos(x)) − x^2 in finite precision arithmetic. a) At what values x 0 will there be a loss of significant bits when the library function for cos is used? Explain in 1-2 sentences. b) Use Taylor series at these points to repair the approximate evaluation for f. What is the approximation? c) Using this repair, is the maximal error if |x| ≤ .1? d) Write the pseudo-code that avoids loss of significance and returns accurate values of f.

  1. Consider all positive solutions to the equation

e−x^ = x (1) a) How many positive solutions are there? b) Perform three iterations of the bisection method to approximate the smallest solution of this equation. c) Provide the error estimate guaranteed by the theory.

  1. Consider again all solutions to equation (??). a) With a starting value of x 0 = 0, compute the first three iterations {x 1 , x 2 , x 3 }of Newton’s method. b) Provide the error estimate guaranteed by the theory. c) Determine the number of significant digits accuracy the next iterate x 4 will provide.