# Thread: Lagrange Error and Approximating Value Help

1. ## Lagrange Error and Approximating Value Help

Hi, I was wondering if anyone could help me understand this concept. I need urgent but specific help. What I mean is that if possible, I would like "baby steps". Step-by-step explanations if you will. I'd really appreciate it. Anyways, here are some of the problems:

"Find the Taylor polynomial of order four for the function at x=0, and use it to approximate the value of the function at x=0.2."

1. ) 5 sin ( - x )

2. ) ( 1 - x )^-2

As for Lagrange error,

" 1. ) The approximation Sqrt ( 1 + x ) ≈ 1 + ( x / 2 ) is used when x is small. Estimate the maximum error when |x| < 0.01"

I hope I am not abusing of your help, though I have a feeling I am. I know it's a lot of questions but I wouldn't feel confident with just one example. Thank you if you read this, or choose to respond.

2. Originally Posted by BoombaWoomba
...Step-by-step explanations if you will. I'd really appreciate it. Anyways, here are some of the problems:

"Find the Taylor polynomial of order four for the function at x=0, and use it to approximate the value of the function at x=0.2."

1. ) 5 sin ( - x )

...
You know the general form of the Taylor polynomial:

$f(x) = f(a)+\frac{x-a}{1!}f'(a) + \ldots + \frac{(x-a)^{n-1}}{(n-1)!}f^{(n-1)} + R_n$ ......... $f^{(n-1)}$ is the (n-1)th derivative of f.

With your question a = 0.
Calculate the derivatives:
Code:
f(x)     = 5sin(-x) --> f(0)     = 0
f'(x)    = -5cos(x) --> f'(0)    = -5
f''(x)   = 5sin(x)  --> f''(0)   = 0
f'''(x)  = 5cos(x)  --> f'''(0)  = 5
f''''(x) = -5sin(x) --> f''''(0) = 0
Now plug in all values:

$f(x) = 0 + (-5)x + 0 + \frac{x^3}{3!} \cdot 5 = -5x + \frac56 x^3$

Calculate $f(0.2) = -5 \cdot 0.2 + \frac56 (0.2)^3 = -1 + \frac1{150} = -\frac{149}{150} \approx -0.9933333..$

Check this result by calculating $5 \sin(-0.2) \approx -0.993346...$

3. Originally Posted by BoombaWoomba

" 1. ) The approximation Sqrt ( 1 + x ) ≈ 1 + ( x / 2 ) is used when x is small. Estimate the maximum error when |x| < 0.01"
Let $f(x) = \sqrt{x+1}$ then the first older Taylor polynomial is $f(0) + f'(0)x = 1 + \frac{x}{2}$. Let $R_2(1)$ be the remainder for this at $1$. Then, $R_2(1) = \frac{f''(y)}{2!}y^2$ for some $0 now $f''(y) = -1/4(y+1)^{-3/2}$.

This means, $\left| R_2(1)\right| = \frac{1}{8} \cdot (y+1)^{-3/2} y^2 \leq \frac{1}{8} y^2 \leq \frac{1}{8} (.01)^2 = 0.0000125$.

Thus, it means that if we are within $.01$ of the function we have an accuracy to 4 decimal places.