[Math] Solving the second taylor polynomial

calculuspolynomialstaylor expansion

So I've found myself in a predicament when trying to implement the second Taylor polynomial. Here is my question:

Let $f(x) = \sqrt{x}$, find the second Taylor polynomial $P_2(x)$ for this function about $x_0 = 1$.

So here are my steps:

  1. the derivative of $\sqrt{x} = \frac{1}{2\sqrt{x}}=\frac{1}{2}(x^{-1/2})$

  2. the second derivative of $\sqrt{x}$ is $-\frac{1}{4}x^{-3/2}$

Continuing along, my implementation of the Taylor polynomial is as follows. I assume $x =1$ since $x_0 = 1$ in the question (correct me if I'm wrong).

Therefore the second taylor polynomial is:
$$1 + (\frac{1}{2}(1-1)^1)\cdot \frac{1}{1!} + ((-\frac{1}{4}x^{-3/2})(1-1)^2)\cdot \frac{1}{2!} = 1$$
Can someone guide me in the right direction?

Best Answer

When you need to develop Taylor series around $x_0\neq 0$, it is generally simpler to make a change of variable $x=y+x_0$ and consider the development around $y=0$ using more standard formulae.

In your case, for $f=\sqrt x$ around $x=1$, this gives $f=\sqrt{1+y}$ around $y=0$.

Using Taylor series or the generalized binomial theorem, this will give $$f=1+\frac{y}{2}-\frac{y^2}{8}+\frac{y^3}{16}+O\left(y^4\right)$$ and, back to $x$ $$f=1+\frac{1}{2}(x-1)-\frac{1}{8} (x-1)^2+\frac{1}{16} (x-1)^3+O\left((x-1)^4\right)$$

Otherwise, as you did, $$F(x)=\sqrt x\implies F(1)=1$$ $$F'(x)=\frac{1}{2 \sqrt{x}}\implies F'(1)=\frac12$$ $$F''(x)=-\frac{1}{4 x^{3/2}}\implies F''(1)=-\frac14$$ $$F'''(x)=\frac{3}{8 x^{5/2}}\implies F'''(1)=\frac 38$$ So, now the series $$F(1)+\frac{F'(1)}{1!}(x-1)+\frac{F''(1)}{2!}(x-1)^2+\frac{F'''(1)}{3!}(x-1)^3+O\left((x-1)^4\right)$$ The mistake was to write $(1-1)$ instead of $(x-1)$ and reciprocally to not compute the values of the derivatives for $x=1$.

Related Question