# What can we say about $f$ if $\int_0^1 f(x)p(x)dx=0$ for all polynomials $p$?

This question was motivated by another question in this site.

As explained in that problem (and its answers), if $\displaystyle f$ is continuous on $\displaystyle [0,1]$ and $\displaystyle \int_0^1 f(x)p(x)dx=0$ for all polynomials $\displaystyle p$, then $\displaystyle f$ is zero everywhere.

Suppose we remove the restriction that $\displaystyle f$ is continuous.

Can we conclude from $\displaystyle f\in L^1([0,1])$ that $\displaystyle f$ is zero almost everywhere?

(This should be terribly standard. My apologies, I am rusty of late.)

#### Solutions Collecting From Web of "What can we say about $f$ if $\int_0^1 f(x)p(x)dx=0$ for all polynomials $p$?"

Assuming you’re using Lebesgue integrals, to even make the statement that ${\mathbb \int_0^1 f(x)p(x) = 0}$ for all polynomials $p(x)$, you are forcing $f(x)$ to be in $L^1$. This can be seen by setting $p(x) = 1$; in order for the statement ${\mathbb \int_0^1 f(x) = 0}$ to be well-defined the positive and negative parts $f^+(x)$ and $f^-(x)$ have to integrate to the same finite value.

So suppose $f(x)$ is some $L^1$ function with ${\mathbb \int_0^1 f(x)p(x) = 0}$ for all polynomials $p(x)$. By the Stone-Weierstrass theorem you can uniformly approximate any continuous function by polynomials, so taking limits you also have ${\mathbb \int_0^1 f(x)g(x) = 0}$ for every continuous $g(x)$. In particular it is true for $g(x) = \cos(2\pi nx)$ and $g(x) = \sin(2\pi nx)$ for any $n$. This means each Fourier coefficient of $f(x)$ is zero. By the uniqueness theorem for Fourier coefficients, this means $f(x) = 0$ a.e.

1. Yes. This follows from the fact that polynomials are dense in $L^1$, which follows from (say) Stone-Weierstrass together with the fact that continuous functions are dense in $L^1$.