Last time I left off with a group of integrals involving delta functions, and today I'm going to show you how they work. The basic idea is that the dot product of the delta function with any other function simply evaluates that function at the origin. Because the area under the delta function is just one.
What about the dot product of the derivative of the delta function with a target function? It turns out that this operation simply evaluates the derivative of the target function. You can "prove" this using traditional integration by parts and the properties of the delta function, but you can actually see it pretty convincingly from the picture I left off yesterday:
With this we can evaluate our original integral, which was of course
It's not hard to see that this function is zero at the origin, so the middle term of our "dot products" goes away. And the first derivative is also zero (you can see this if you sketch the graph...it's a local minimum) so the first term also goes away. All that's left is the third term, which you know evaluates to 2. So the definite integral is 2.
You might think all that business with the delta functions was a waste of time because the terms ended up disappearing. But they don't always. The easiest way to see this is if you try to take this integral from one to infinity instead of zero to infinity. That means you have to move the delta functions over to the right by one unit, and now you're evaluating the function and its derivative for x=1. I'm getting -1/e + 4/e + 2/e = 5/e for an answer (don't forget you've got to reverse the sign on the first derivative!). You can check me on that but I think it's right.