= Solution
Consider the <flat function>
$$
f(x)=\begin{cases}e^{-1/x^2},&x\ne0,\\0,&x=0.\end{cases}
$$
Away from zero every <derivative> has the form $P_n(1/x)e^{-1/x^2}$ for a <polynomial> $P_n$: differentiating preserves this form. For every $m\geq0$,
$$
\lim_{x\to0}|x|^{-m}e^{-1/x^2}=0,
$$
because an <exponential function> decays faster than any power. Inductively, extend each displayed <derivative> by zero at zero. It is continuous there, and its difference quotient at zero also tends to zero by the same estimate with one extra power of $|x|^{-1}$. Thus each extension is the <derivative> of the preceding extension. This proves $f\in C^\infty(\mathbb R)$ and $f^{(n)}(0)=0$ for all $n$.
Its <Taylor series> at zero is identically zero, whereas $f(x)>0$ for every $x\ne0$. \b[It is <smooth> everywhere but not <real analytic> at zero.]
Back to article page