hw4_solutions - CS 257/MATH 257 Numerical Methods Homework...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Numerical Methods - Homework 6 September 28, 2007 1. [1pt] Section 4.1 #1 Solution: p ( x ) = 7 ( x - 2)( x - 3)( x - 4) (0 - 2)(0 - 3)(0 - 4) +11 ( x - 0)( x - 3)( x - 4) (2 - 0)(2 - 3)(2 - 4) +28 ( x - 0)( x - 2)( x - 4) (3 - 0)(3 - 2)(3 - 4) +63 ( x - 0)( x - 2)( x - 3) (4 - 0)(4 - 2)(4 - 3) 2. [2pt] Section 4.1 #3 Solution: Let { x 0 , x 1 , x 2 , x 3 } = {- 1 , 1 , 3 , 4 } . We find the four corresponding Lagrange polynomials to be ` 0 = ( x - 1)( x - 3)( x - 4) ( - 1 - 1)( - 1 - 3)( - 1 - 4) ` 1 = ( x + 1)( x - 3)( x - 4) (1 + 1)(1 - 3)(1 - 4) ` 2 = ( x + 1)( x - 1)( x - 4) (3 + 1)(3 - 1)(3 - 4) ` 3 = ( x + 1)( x - 1)( x - 3) (4 + 1)(4 - 1)(4 - 3) -2 -1 0 1 2 3 4 5 -3 -2 -1 0 1 2 3 4 Lagrange Polynomials The key property your graph should show is that ` i ( x j ) = ± 1 i = j 0 i 6 = j 3. [1pt] Section 4.1 #12 Solution: q ( x ) = p ( x ) + c ( x + 2)( x + 1)( x )( x - 1)( x - 2) . When x = 3, 30 = 61 + c (5)(4)(3)(2)(1) and c = -31/120. Thus q ( x ) = x 4 - x 3 + x 2 - x + 1 - 31 120 ( x + 2)( x + 1)( x )( x - 1)( x - 2) . 4.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

Page1 / 4

hw4_solutions - CS 257/MATH 257 Numerical Methods Homework...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online