# Taylor Series

• May 8th 2006, 10:41 PM
AfterShock
Taylor Series
Hello,

I have this problem, that requires us to derive the taylor series based at x = -1 for f(x) from scratch, then find an interval of converge for the series, including endpoint behavior, and finally approximating:
ln((-1 + 2*Pi)/(Pi)) accurate to within 10^-25.

f(x) = ln(x + 2)

Okay, so this is what I have done.

I first found the first 6 derivatives to find a pattern. So they are as follows:

f'(x) = 1/(x+2)
f''(x) = -1/(x+2)^2
f^3(x) = 2/(x+2)^3
f^4(x) = -6(x+2)^4
f^5(x) = 24/(x+2)^5
f^6(x) = -120/(x+2)^6

And so forth.

So then I expanded it to:

1*(x+2)^(-1)
1*(-1)*(x+2)^(-2)
1*(-1)*(-2)*(x+2)^(-3)
1*(-1)*(-2)*(-3)*(x+3)^(-4)

And so forth.

Okay, so the coefficients are factorials. The coefficient for the nth derivative is just:

(+ or -)(n-1)!

Now, the nth derivative can be written as follows:

(+ or -)(n-1)!(x+2)^(-n)

The signs alternate, so I need a factor of (-1)^n or (-1)^(n+1), whichever matches up correctly

For n = 1,2,3,..., the signs are +,-,+,..., therefore I need to use the (-1)^(n+1)

So I have (-1)^(n+1)(n-1)!(x+2)^(-n)

What I really wanted was the nth derivative evaluated at x=-1, so substituted -1 in for x to get:

(-1)^(n+1)(n-1)!(1)^(-n)= (-1)^(n+1)(n-1)!

Now I have to use the Taylor series expansion formula:

S(x) = sum(a_n(x-x_0)^n, where a_n = [S^n(x_0)]/n!

So now I have sum((A_n/n!)(x+1)^n, x, 0, infinity).

A_n is the nth deriv. evaluated at x = -1.

Now what. How do I evaluate the other parts and further expand this if its not done so already. How do I get an approximation accurate to within such a small error bound.

Book has the following result: Sum from n=1 to infinity of [(-1)^(n+1) / n] * (x+1)^n ... I was close just don't really see it. How would I do the remaining parts for accuracy and approximating the function above?

Thanks for your help.
• May 9th 2006, 02:34 PM
ThePerfectHacker
Definition:
A function which is infinitely diffrenciable its "Taylor Series centered at c" is defined as the power series:
$\displaystyle g(x)=\sum^{\infty}_{k=0}\frac{f^{(k)}(c)(x-c)^k}{k!}$

You have,
$\displaystyle y=\ln (x+2)$
It is centered at $\displaystyle c=-1$
Then, (infinitely diffrenciable for x=2)
$\displaystyle y'(x)=\frac{1}{x+2}$
$\displaystyle y''(x)=-\frac{1}{(x+2)^2}$
$\displaystyle y'''(x)=\frac{2}{(x+2)^3}$
$\displaystyle y^{(4)}(x)=-\frac{6}{(x+2)^4}$
In general, $\displaystyle n\geq 1$
$\displaystyle y^{(n)}(x)=(-1)^{n-1}\frac{(n-1)!}{(x+2)^n}$
When evaluated at $\displaystyle x=-1$ we have,
$\displaystyle y^{(n)}(-1)=(-1)^{n-1}\frac{(n-1)!}{(-1+2)^n}=(-1)^{n-1}(n-1)!$

Thus, its Taylor Series is,
$\displaystyle g(x)=f(0)+\sum^{\infty}_{k=1}\frac{(-1)^{k-1}(k-1)!(x+1)^k}{k!}$
Which simplifies to,
$\displaystyle g(x)=f(0)+\sum^{\infty}_{k=1}\frac{(-1)^k(x+1)^k}{k}$
Thus,
$\displaystyle g(x)=\ln(2)-\frac{x+1}{1}+\frac{(x+1)^2}{2}-\frac{(x+1)^3}{3}+...$

Further we can prove that the Lagrange remainder is convergent to 0, thus this power series is a representation for $\displaystyle \ln(x+2)$
• May 9th 2006, 11:07 PM
CaptainBlack
Quote:

Originally Posted by ThePerfectHacker
Definition:

Thus,
$\displaystyle g(x)=\ln(2)-\frac{x+1}{1}+\frac{(x+1)^2}{2}-\frac{(x+1)^3}{3}+...$

Further we can prove that the Lagrange remainder is convergent to 0, thus this power series is a representation for $\displaystyle \ln(x+2)$

When $\displaystyle |x+1|<1$

RonL
• May 10th 2006, 02:14 PM
ThePerfectHacker
Quote:

Originally Posted by CaptainBlack
When $\displaystyle |x+1|<1$

RonL

If that did that in front of Cauchy I would be dead.
• May 11th 2006, 12:14 PM
AfterShock
I continued to derive the Taylor's Series for it using my way...when I last was on here, I was at this point:

So now I have sum((A_n/n!)(x+1)^n, x, 0, infinity).

I substituted what A_n was and simplified.

I ended up with summation(([(-1)^(n+1)]/n)*(x+1)^n, n = 1...infinity) since n = 0 is zero, therefore does not appear.

I think that's the right derivation (or hope, since everything will be messed up).

For part b, it asks to find the interval of convergence for this series, including endpoint behavior.

I decided to use the RATIO TEST to determine this.

So: [[(x+1)^(n+1)]/(n+1)]/[(x+1)^n]/n...which simplifies to:

[n*(x+1)]/(n+1)...now the ratio test says to take the limit of that as
n -> infinity. If the limit is < 1, it converges. If it is > 1, it diverges. If it = 1, it is inconclusive.

I found the limit is x + 1. Oh, I forgot to mention that its the absolute value of that. So, if |x+1| < 1, it converges. If |x+1| > 1, it diverges.

So: will not converge when |-x - 1| > 1 or |x + 1| > 1 or (x < -2 OR x > 0)

Therefore, x needs to be between -2 and 0 for it to converge.

For endpoints, to check convergencejust plug those two points into the original taylor series? And then what?

Now, part c, I have no idea how to approach this part:

"Use your results, along with other ideas, to approximate
ln((-1 + 2*Pi)/(Pi)) accurate to within 10^(-25).

THANKS!