# Taylor series: criteria for maximum error attained at boundary?

In Calculus BC there's a frequent assumption that the error between an $n$-th degree Taylor series and its corresponding function is larger the further the functions are evaluated from the Taylor series' center.

It's not quite true. You can provide counterexamples using polynomials. However, I was wondering if there's a subtler set of criteria where it works. It seems to hold for $\sin x,\ \cos x,\ \text{and}\ e^x$.

On the complex plane, if our function is analytic, then the difference of the function and its Taylor series is also analytic, so the maximum modulus of the difference occurs on the boundary (of a reasonably defined domain). So I'm wondering if there are any similar criteria where we could say, over the domain of real numbers, for any ball whose center is the center of the Taylor series, the extrema of the difference between the Taylor series and its original function occurs at the boundary.

If the "boundary" is defined arbitrarily, then of course we can expect examples of both kinds: (a) the Taylor series has the largest error at a point of the "boundary"; (b) the Taylor series has a larger error in a certain point in the "interior" than at any point of the "boundary". Both examples might be the case if the domain of our function is $[a,b] \subset {\mathbb R}$ and the "boundary" consists of the two points $a$ and $b$.
• For any ball $B(x,\delta)$ and any polynomial $p$ there exists a non analytical function $f\in C^\infty$ such that $p$ is the Taylor polynomial of $f$ at $x$ and $f=p$ in $\partial B(x,\delta)$. – Veridian Dynamics Feb 8 '18 at 19:59
• That's an interesting result! However, this is sort of the exact opposite of what I'm looking for. I want to know what properties a real-valued function $f$ needs to have for us to claim that for a Taylor polynomial $T$ of the function $f$ whose center is $c$ we have that the maximum of $|f(x)-T(x)|$ for $x$ in $\bar{B}(c,\delta)$ occurs at $c-\delta$ or $c+\delta$. The analogous claim over $\mathbb{C}$ is for sure true due to the maximum modulus principle. – Charles0349 Feb 8 '18 at 22:04
• Thanks... It's kind of a weird question. When I first heard the statement that the error between a Taylor series and its original function is largest at the boundary, it was immediately clear to me that it was false. However, for functions like $e^x$ and $\sin x$ the statement does seem to be true, so I wanted to ask. – Charles0349 Feb 9 '18 at 5:34