[Math] Applying the Stone-Weierstrass Theorem to approximate even functions

real-analysis

Let $f:[-1,1] \rightarrow \mathbb{R}$ be any even continuous function on $[-1,1]$ (i.e. $f(-x)=f(x)$ $\forall x \in [-1,1]$). Let $\epsilon>0$. Prove that there exists an even polynomial $p$ such that $$|f(x)-p(x)|< \epsilon$$ $$\forall x \in [-1,1]$$

Here, "even polynomial" means that $p(-x)=p(x)$, not simply that it has even degree.

I think I should use the Stone-Weierstrass theorem to show that the subalgebra of even polynomials, call it $\mathcal{A}$, over this interval is dense, from which the result follows immediately.

For this to work I require that $\mathcal{A}$ contains the constants (obviously true) and separates points…which is not true, unfortunately. Anyone have any hints? I would prefer hints only, rather than solutions.

Oh yes, and I should mention that the version of the Stone-Weierstrass theorem that I can use says that if a subalgebra of $C(\mathbb{R})$ contains the constants and separates points, then it is dense in $C(\mathbb{R})$.

Best Answer

Hint: If $\sup_{x \in [-1,1]} |\,p(x) - f(x)|<\epsilon$ then $\sup_{x \in [-1,1]} |\,\frac{1}{2}(\,p(x)+ p(-x)\,)- f(x)\,|<\epsilon$

$\bf{Added:}$ Let $p(x)$ a polynomial so that for every $x \in [-1,1]$ we have $|\,p(x) - f(x)|<\epsilon$. Note that if $x \in [-1,1]$ then also $-x \in [-1,1]$. So we have $$|\,p(x) - f(x)|<\epsilon\\ |\,p(-x) - f(-x)|<\epsilon$$

Add up the inequality and divide by $2$:

$$\frac{1}{2} ( |\,p(x) - f(x)| + |\,p(-x) - f(-x)|) < \epsilon$$

Note that we have $|a+b| \le |a|+|b|$ for all numbers. Therefore we get

$$\frac{1}{2} \cdot |(p(x) + p(-x) ) - (f(x) + f(-x) ) | < \epsilon$$ or $$ |\frac{1}{2}\cdot (p(x) + p(-x) ) - \frac{1}{2}\cdot(f(x) + f(-x) ) | < \epsilon$$ $\tiny{\text{ the averages also satisfy the inequality }}$.

Now since $f$ is even we have $\frac{1}{2}\cdot(f(x) + f(-x) ) = f(x)$. Moreover, $\frac{1}{2}\cdot (p(x) + p(-x) )$ is an even polynomial already. We are done.

Related Question