03.03.2014 Views

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

Numerical Methods Course Notes Version 0.1 (UCSD Math 174, Fall ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

2 CHAPTER 1. INTRODUCTION<br />

f(x) =<br />

n∑ f (k) (c) (x − c) k<br />

f(x) −<br />

k!<br />

k=0<br />

n∑<br />

∣ f(x) − f (k) (c) (x − c) k<br />

k! ∣<br />

k=0<br />

n∑ f (k) (c) (x − c) k<br />

k=0<br />

k!<br />

= f (n+1) (ξ) (x − c) n+1<br />

(n + 1)!<br />

∣ f (n+1) (ξ) ∣ |x − c|<br />

n+1<br />

=<br />

.<br />

(n + 1)!<br />

+ f (n+1) (ξ) (x − c) n+1<br />

(n + 1)!<br />

On the left hand side is the difference between f(x) and its approximation by Taylor’s series.<br />

We will then use our knowledge about f (n+1) (ξ) on the interval [a, b] to find some constant M such<br />

that<br />

n∑<br />

∣ f(x) − f (k) (c) (x − c) k<br />

k! ∣<br />

k=0<br />

=<br />

∣<br />

∣f (n+1) (ξ) ∣ ∣ |x − c| n+1<br />

(n + 1)!<br />

≤ M |x − c| n+1 .<br />

Example Problem 1.2. Find an approximation for f(x) = sin x, expanded about c = 0, using<br />

n = 3.<br />

Solution: Solving for f (k) is fairly easy for this function. We find that<br />

so<br />

f(x) = sin x = sin(0) + cos(0) x<br />

1!<br />

= x − x3<br />

6<br />

+<br />

sin(ξ) x4<br />

+ ,<br />

24<br />

( )∣ ∣ sin x − x − x3 ∣∣∣<br />

=<br />

6<br />

− sin(0) x2<br />

2!<br />

+<br />

− cos(0) x3<br />

3!<br />

sin(ξ) x 4<br />

∣ 24 ∣ ≤ x4<br />

24 ,<br />

+<br />

sin(ξ) x4<br />

4!<br />

because |sin(ξ)| ≤ 1.<br />

⊣<br />

Example Problem 1.3. Apply Taylor’s Theorem for the case n = 1.<br />

Solution: Taylor’s Theorem for n = 1 states: Given a function, f(x) with a continuous derivative<br />

on [a, b], then<br />

f(x) = f(c) + f ′ (ξ)(x − c)<br />

for some ξ between x, c when x, c are in [a, b].<br />

This is the Mean Value Theorem. As a one-liner, the MVT says that at some time during a trip,<br />

your velocity is the same as your average velocity for the trip.<br />

⊣<br />

Example Problem 1.4. Apply Taylor’s Theorem to expand f(x) = x 3 − 21x 2 + 17 around c = 1.<br />

Solution: Simple calculus gives us<br />

f (0) (x) = x 3 − 21x 2 + 17,<br />

f (1) (x) = 3x 2 − 42x,<br />

f (2) (x) = 6x − 42,<br />

f (3) (x) = 6,<br />

f (k) (x) = 0.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!