Dirac delta function and its property

I am trying to find a formal proof for the following property of Dirac delta function:

for any function $f$ : $$\int_{-\infty}^{+\infty} \delta(x)f(x)dx=f(0),$$ where $\delta$ is Dirac delta generalized function.

Sorry if the above $f$ must have some properties but I think it shouldn't. That is what I want the whole text and the proof.

Is there anyone who knows?

• This is more or less the definition of $\delta$ ($f$ should be continuous on a neighborhood of $0$ for it to make sense). – mrf Jan 22 '16 at 13:41
• You need the theory of distributions to understand why that property holds. You cannot use real calculus, because $\delta(x)$ is not a function. – Von Neumann Jan 22 '16 at 15:38

Consider a sequence of function $$\delta_\epsilon(x)=\begin{cases}\frac{1}{2\epsilon},&-\epsilon<x<\epsilon,\\ 0,&\mbox{otherwise}. \end{cases}$$
It is reasonable to expect that $$\delta(x)=\lim_{\epsilon\to 0}\delta_\epsilon(x).$$
Now consider the integral and assume that we are free to change the order of operations: $$\int_{\mathbb R}\delta(x)f(x)dx=\lim_{\epsilon\to 0}\int_{\mathbb R}\delta_{\epsilon}(x)f(x)dx=\lim_{\epsilon\to 0}\int_{-\epsilon}^{\epsilon}\frac{1}{2\epsilon} f(x)dx=\lim_{\epsilon\to0}2\epsilon\cdot \frac{1}{2\epsilon} f(\xi),$$ where due to the mean value theorem $\xi\in(-\epsilon,\epsilon)$.
Hence we can conclude that $$\lim_{\epsilon\to 0}f(\xi)=f(0),$$ which gives you a "proof" of the original formula.