# Proof of the correctness of Taylor series

I am looking at the proof provided on the wiki page for taylor series

http://en.wikipedia.org/wiki/Taylor%27s_theorem#Proof_for_Taylor.27s_theorem_in_one_real_variable

One of the proof provided is the following

let

$$h_k(x) = \begin{cases} \frac{f(x)-P(x)}{(x-a)^k}, & \text{if } x\neq a \\ 0, & \text{if } x =a \end{cases}$$

$$P(x) = f(a)+f'(a)(x-a)+\frac{f''(a)}{2!}(x-a)^2........$$

it is sufficient to show that

$$\lim_{x \to a}h_k(x)=0$$

I don't see why is it sufficient, shouldn't the limit be

$$\lim_{x \to b}h_k(x)=0$$

$$b\neq a$$

otherwise the limit is trivial as $f(x)-P(x)$ is trivially $0$. I don't see why adding the division of $(x-a)^k$ would help?

You might be confusing Taylor series and degree $k$ Taylor polynomial. The proof you mention concerns the latter. If $P_k(x)$ is a degree $k$ Taylor polynomial to $f$ at $a$ then its derivatives at $a$ agree with those of $f$ to the $k$th order. Therefore $f(x) - P(x)$ is much smaller than $(x-a)^k$ a fact expressed neatly by $\lim_{x \to a} h_k(x) = 0$.
It certainly isn't the case that $P(x) - f(x)$ is trivially $0$. That can happen only when $f(x)$ coincides with a polynomial on some neighborhood of $a$. Even if by $P(x)$ you mean Taylor series (and not just a Taylor polynomial), there are functions whose Taylor series doesn't converge to the original function. For example $f(x) = e^{-1/x^2}$ whose Taylor series around $0$ converges to the zero function since all derivatives vanish. We say that such a function is not analytic at $0$.