## You are here

Homeproof of Weierstrass approximation theorem in R^n

## Primary tabs

# proof of Weierstrass approximation theorem in R^n

To show that the Weierstrass Approximaton Theorem holds in $\mathbb{R}^{n}$, we will use induction on $n$.

For the sake of simplicity, consider first the case of the cubical region $0\leq x_{i}\leq 1$, $1\leq i\leq n$. Suppose that $f$ is a continuous, real valued function on this region. Let $\epsilon$ be an arbitrary positive constant.

Since a continuous functions on compact regions are uniformly continuous, $f$ is uniformly continuous. Hence, there exists an integer $N>0$ such that $|f(a)-f(b)|<\epsilon/2$ whenever $|a-b|\leq 1/N$ and both $a$ and $b$ lie in the cubical region.

Define $\phi\colon\mathbb{R}\to\mathbb{R}$ as follows:

$\phi(x)=\left\{\begin{matrix}0&x<-1\cr 1+x&-1\leq x\leq 0\cr 1-x&0\leq x\leq 1% \cr 0&x>1\end{matrix}\right.$ |

Consider the function ${\tilde{f}}$ defined as follows:

${\tilde{f}}(x_{1},\ldots x_{n})=\sum_{{m=0}}^{N}\phi(Nx_{1}+m)f(m/N,x_{2},% \ldots x_{n})$ |

We shall now show that $|f(x_{1},\ldots,x_{n})-{\tilde{f}}(x_{1},\ldots,x_{n})|\leq\epsilon/2$ whenever $(x_{1},\ldots,x_{n})$ lies in the cubical region. By way that $\phi$ was defined, only two of the terms in the sum defining ${\tilde{f}}$ will differ from zero for any particular value of $x_{1}$, and hence

${\tilde{f}}(x_{1},\ldots,x_{n})=(Nx-\lfloor Nx\rfloor)f\left({\lfloor Nx_{1}% \rfloor\over N},x_{2},\ldots,x_{n}\right)+(\lfloor Nx\rfloor+1-x)f\left({% \lfloor Nx_{1}\rfloor+1\over N},x_{2},\ldots,x_{n}\right),$ |

so

$\displaystyle|{\tilde{f}}(x_{1},\ldots,x_{n})-f(x_{1},\ldots,x_{n})|$ | $\displaystyle=$ | $\displaystyle|{\tilde{f}}(x_{1},\ldots,x_{n})-\{(Nx-\lfloor Nx\rfloor)+(% \lfloor Nx\rfloor+1-x)\}f(x_{1},\ldots,x_{n})|$ | ||

$\displaystyle\leq$ | $\displaystyle(Nx-\lfloor Nx\rfloor)|f\left({\lfloor Nx_{1}\rfloor\over N},x_{2% },\ldots,x_{n}\right)-f(x_{1},X_{2}\ldots,x_{n})|+(\lfloor Nx\rfloor+1-x)|% \left({\lfloor Nx_{1}\rfloor+1\over N},x_{2},\ldots,x_{n}\right)-f(x_{1},x_{2}% \ldots,x_{n})|$ | |||

$\displaystyle\leq$ | $\displaystyle(Nx-\lfloor Nx\rfloor){\epsilon\over 2}+(\lfloor Nx\rfloor+1-x){% \epsilon\over 2}={\epsilon\over 2}.$ |

Next, we will use the Weierstrass approximation theorem in $n-1$ dimensions and in one dimesnsion to approximate $\tilde{f}$ by a polynomial. Since $f$ is continuous and the cubical region is compact, $f$ must be bounded on this region. Let $M$ be an upper bound for the absolute value of $f$ on the cubical region. Using the Weierstrass approximation theorem in one dimension, we conclude that there exists a polynoial $\breve{\phi}$ such that $|\breve{\phi}(a)-\phi(a)|<\epsilon/(4MN)$ for all $a$ in the region. Using the Weierstrass approximation theorem in $n-1$ dimensions, we conclude that there exist polynomials $p_{m}$, $0\leq m\leq N$ such that $|p_{m}(x_{2},\ldots,x_{n})-f(m/N,x_{2},\ldots x_{n})|\leq{\epsilon\over 4N}$. Then one has the following inequality:

$\displaystyle|{\breve{\phi}}(Nx_{1}+m)p_{m}(x_{2},\ldots x_{n})-\phi(Nx_{1}+m)% f(m/N,x_{2},\ldots x_{n})|$ | $\displaystyle=|{\breve{\phi}}(Nx_{1}+m)p_{m}(x_{2},\ldots x_{n})-{\breve{\phi}% }(Nx_{1}+m)f(m/N,x_{2},\ldots x_{n})$ | |||

$\displaystyle+$ | $\displaystyle{\breve{\phi}}(Nx_{1}+m)f(m/N,x_{2},\ldots x_{n})-\phi(Nx_{1}+m)f% (m/N,x_{2},\ldots x_{n})|$ | |||

$\displaystyle\leq$ | $\displaystyle|{\breve{\phi}}(Nx_{1}+m)||p_{m}(x_{2},\ldots x_{n})-f(m/N,x_{2},% \ldots x_{n})|$ | |||

$\displaystyle+$ | $\displaystyle|f(m/N,x_{2},\ldots x_{n})||{\breve{\phi}}(Nx_{1}+m)-\phi(Nx_{1}+% m)|$ | |||

$\displaystyle\leq$ | $\displaystyle{\epsilon\over 4N}+M{\epsilon\over 4MN}={\epsilon\over 2N}$ |

Define

${\breve{f}}(x_{1},\ldots x_{n})=\sum_{{m=0}}^{N}{\breve{\phi}}(Nx_{1}+m)p_{m}(% x_{2},\ldots x_{n}).$ |

As a finite sum of products of polynomials, this is a polynomial. From the above inequality, we conclude that $|{\breve{f}}(a)-{\tilde{f}}(a)|\leq\epsilon/2$, hence $|f(a)-{\breve{f}}(a)|\leq\epsilon$.

It is a simple matter of rescaling variables to conclude the Weirestrass approximation theorem for arbitrary parallelopipeds. Any compact subset of $\mathbb{R}^{n}$ can be embedded in some paralleloped and any continuous function on the compact subset can be extended to a continuous function on the parallelopiped. By approximating this extended function, we conclude the Weierstrass approximation theorem for arbitrary compact subsets of $\mathbb{R}^{n}$.

## Mathematics Subject Classification

41A10*no label found*

- Forums
- Planetary Bugs
- HS/Secondary
- University/Tertiary
- Graduate/Advanced
- Industry/Practice
- Research Topics
- LaTeX help
- Math Comptetitions
- Math History
- Math Humor
- PlanetMath Comments
- PlanetMath System Updates and News
- PlanetMath help
- PlanetMath.ORG
- Strategic Communications Development
- The Math Pub
- Testing messages (ignore)

- Other useful stuff
- Corrections