# assignment5.pdf - Spring 2020 Numerical Analysis Assignment...

• 2

This preview shows page 1 - 2 out of 2 pages.

Spring 2020: Numerical Analysis Assignment 5 (due May 14, 2020) 1. [Interpolation and optimal norm approximation, 2+1+1+1pt] For an interval ( a, b ) , n N and disjoint points x 0 , . . . , x n in [ a, b ] , we define for polynomials p, q h p, q i := n X i =0 p ( x i ) q ( x i ) . (a) Show that , ·i is an inner product for each P k with k n , where P k denotes the space of polynomials of degree k or less. (b) Why is , ·i not an inner product for k > n ? (c) Show that the Lagrange polynomials L i corresponding to the nodes x 0 , . . . , x n are orthonormal with respect to the inner product , ·i . (d) For a continuous function f : [ a, b ] R , compute its optimal approximation in P n with respect to the inner product , ·i and compare with the interpolation of f . 2. [Euler and trapezoidal methods, 2+2pt] Consider the following method for solving of y 0 = f ( y ) : y n +1 = y n + h [ θf ( y n +1 ) + (1 - θ ) f ( y n )] , 0 θ 1 , (1) (a) Compute the truncation error T n of ( ?? ). Assuming sufficient smoothness of y and f , for what value of θ is | T n | the smallest? What does this mean about the accuracy of the method?