Question 1 3D graphics programs utilize surface normals to calculate lighting and shading effects. Each vector must be of unit length. The normal vectors are constructed by first creating vectors that are orthogonal to the surface and then scaling them by their length. This calculation requires calculation of the Euclidian length of the vector and the multiplication of each component by the reciprocal of this length. A graphics program may require millions of such calculations per second. Write a simplified expression for one iteration of Newton’s method to calculate the reciprocal of the square root of a floating point number. Write a simplified expression for one iteration of the Secant method to calculate the reciprocalof the square root of a floating point number. Use one iteration of both methods to calculate 1/sqrt(2.0). Use x0 = 1.0 for newton’s iteration and x0=1.0, x1=2.0 for the secant method. Compare your approximations to the “exact” value. Question 2 Calculate the newton and lagrange interpolation functions for the following data: x 0 0.5 1.0 1.5 2.0 2.5 3.0 F(x) -6.0 -1.875 0.0 .375 0.0 -.375 0.0 What is the order of the resulting polynomial? What is the approximate value of F(1.75)? Using the data from the table above, calculate ∫ ( ) using Simpson’s basic formula. Calculate the same integral by integrating the newton form of the interpolating polynomial found in the first part of the problem. How do the two results compare. Question 3 Derive an approximation for the derivative of F(x) using values of F at 3 points x, x+h, and x+2h. What is the error term for this approximation? Question 4 Use Gaussian quadrature with 3 points to calculate the integral of ( ) on the interval [1,2]. Use the tabulated values of weights and points below. Remember to make a change of interval in order to calculate the integral. Question 5 Write the iteration matrix for the Jacobi method for solving a linear system with coefficient matrix A. [ Determine if jacobi’s method will converge. ]
© Copyright 2026 Paperzz