hmwk_1_solutions

# hmwk_1_solutions - UNIVERSITY OF NOTRE DAME Department of...

This preview shows pages 1–5. Sign up to view the full content.

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

View Full Document

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

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: UNIVERSITY OF NOTRE DAME Department of Civil Engineering and Geological Sciences CE 30125 J.J. Westerink Homework Set #1 Solutions Problem 1 f ( x ) =- . 78 x 4- . 25 x 3- . 45 x 2- . 25 x + 1 . 2 For clarity we can begin by creating a table of derivatives of f ( x ). We will be developing the Taylor Polynomial about the point x = 0, or from our notes we understand this to be a = 0, thus: General x = a = 0 f ( x )- . 78 x 4- . 25 x 3- . 45 x 2- . 25 x + 1 . 2 1 . 2 df dx- 3 . 12 x 3- . 75 x 2- . 9 x- . 25- . 25 d 2 f dx 2- 9 . 36 x 2- 1 . 5 x- . 9- . 9 d 3 f dx 3- 18 . 72 x- 1 . 5- 1 . 5 d 4 f dx 4- 18 . 72- 18 . 72 d 5 f dx 5 a) Develop 2, 4 and 6 term Taylor expansions 1 2 2 Term: g TS ( x ) = f ( a ) + ( x- a ) f ( a ) Using the above table: g TS ( x ) = 1 . 2 + ( x- 0)(- . 25) g TS ( x ) = 1 . 2- . 25 x 4 Term: g TS ( x ) = f ( a ) + ( x- a ) f ( a ) + 1 2 ( x- a ) 2 f 00 ( a ) + 1 3! ( x- a ) 3 f 000 ( a ) Using the above table: g TS ( x ) = 1 . 2 + ( x- 0)(- . 25) + 1 2 ( x- 0) 2 (- . 9) + 1 6 ( x- 0) 3 (- 1 . 5) g TS ( x ) = 1 . 2- . 25 x- . 45 x 2- . 25 x 3 6 Term: g TS = f ( a )+( x- a ) f ( a )+ 1 2 ( x- a ) 2 f 00 ( a )+ 1 3! ( x- a ) 3 f 000 ( a )+ 1 4! ( x- a ) 4 f ( iv ) ( a )+ 1 5! ( x- a ) 5 f ( v ) ( a ) Using the table above: g TS ( x ) = 1 . 2 + ( x- 0)(- . 25) + 1 2 ( x- 0) 2 (- . 9) + 1 6 ( x- 0) 3 (- 1 . 5) + 1 24 ( x- 0) 4 (- 18 . 72) + 1 120 ( x- 0) 5 (0) g TS ( x ) = 1 . 2- . 25 x- . 45 x 2- . 25 x 3- . 78 x 4 3 b) Plot the exact function f ( x ) , as well as all three Taylor series on the interval [0 , 1] . 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1-0.6-0.4-0.2 0.2 0.4 0.6 0.8 1 1.2 x y g T S ( x ) 2-Term g T S ( x ) 4-Term f ( x ) g T S ( x ) 6-Term Figure 1 c) Plot the estimated error and actual error for all three Taylor se- ries on a log log plot, where x is the distance from 0. Note: There is no error between the 6-term expansion and the original function f ( x ), since we can only plot positive nonzero values in a log log plot only the errors for the 4-term and 2-term expansion are shown in the following figure. The estimated error is determined from the leading order error term in the Taylor expansion. 1 ( n + 1)! ( x- a ) n +1 d n +1 f dx n +1 | x = ξ where ξ ∈ [ a,x ]. There are many ways to estimate ξ , since it is difficult to determine which value for ξ is the most reasonable. The following 4 figure will use ξ = a = 0, however the midpoint ξ = 1 2 ( a + x ) is also a good choice. In this problem these estimates are: 1 2 ( x- a ) 2 f 00 ( a ) = 1 2 x 2 · (- . 9) =- . 45 x 2 for 2-term and 1 4! ( x- a ) 4 f ( iv ) ( a ) = 1 4! x 4 · (- 18 . 72) =- . 78 x 4 for 4-term d) How do the errors generally behave?...
View Full Document

## This note was uploaded on 03/02/2012 for the course CE 30125 taught by Professor Westerink,j during the Fall '08 term at Notre Dame.

### Page1 / 12

hmwk_1_solutions - UNIVERSITY OF NOTRE DAME Department of...

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

View Full Document
Ask a homework question - tutors are online