<<

Differentiating under the , an alternative to

Calvin W. Johnson May 9, 2020

1 The basic idea

When we learn definite , one of the tools is integration by parts. Here I introduce an alternative which can be applied to many of the integrals encoun- tered in physics. Called ”differentiating under the integral sign,” this approach can be problematic in terms of formal integration theory, which is why math departments do not teach it, but for most smooth integrands it works just fine. It was a favorite technique of Richard Feynman. With this tool in hand, you won’t have to use integrating by parts at all in this course. Differentiating under the integral sign is best explained through an example: Z ∞ I = dx x exp(−ax). (1) 0 This is the kind of definite integral for which one often appeals to integration by parts. However, let’s look at it carefully. We all (I hope) know

Z ∞ 1 dx exp(−ax) = (2) 0 a or at least you know you can compute it easily enough. But notice: ∂ x exp(−ax) = − exp(−ax) (3) ∂a so that Z ∞ Z ∞  ∂  I = dx x exp(−ax) = dx − exp(−ax) (4) 0 0 ∂a Now because the limits of integration do not include a, we switch the order of the integral sign and the derivative. (Because both are limit processes, this is the part that is technically iffy, from a rigorous point of view, and mathematicians are correct to view it suspiciously. It does, however, yield correct results.)

 ∂  Z ∞  ∂  1 1 I = − dx exp(−ax) = − = 2 . (5) ∂a 0 ∂a a a

1 Huh. A lot easier than integrating by parts, isn’t it? You can also do this multiple times, for example,

Z ∞ Z ∞  ∂ 2 dx x2 exp(−ax) = dx − exp(−ax) 0 0 ∂a  ∂ 2 Z ∞  ∂ 2 1 2 = − dx exp(−ax) = − = 3 (6) ∂a 0 ∂a a a

R ∞ 4 You try (1) what is 0 dx x exp(−ax)? Answer at end.

This also works for Gaussians, e.g., Z ∞  ∂  Z ∞ dx x2 exp(−bx2) == − dx exp(−bx2) −∞ ∂b −∞  ∂  rπ 1r π = − = . (7) ∂b b 2 b3 It applies to a variety of integrals, mostly those for which you would be tempted to integrate by parts. It is critical that you make sure that the variable you are taking the derivative of does not appear in the limits of integration. You can apply it to, for example, integrals of trigonometric functions, or integrals of exponentials over finite ranges, although they are somewhat more involved.

R ∞ 4 2 You try (2) What is −∞ dx x exp(−bx )? Answer to be given in class.

R ∞ 2 2 You try (3) What is 0 dx x exp(−bx )? Answer at end.

R 1 You try (4) Set up the derivative, but do not evaluate, needed for 0 dx x exp(−ax). Answer at end.

R 1 You try (5) Set up the derivative, but do not evaluate, needed for 0 dx x cos(kx). Answer to be given in class.

Some final notes. Be aware that this method is not a panacea (a ‘cure for everything’). For example, it doesn’t really help for a Gaussian integral with finite limits, e.g., not for Z π  ∂  Z π dx x2 exp(−bx2) = − dx exp(−bx2) 1 ∂b 1 because the latter integral has to be represented as an (actually a difference of error functions) which are not easily differentiated. Also be aware you cannot get Z ∞ dx x exp(−bx2) 0

2 from this method because there is no derivative of exp(−bx2) with respect to b which will bring down just one power of x. Instead you have to do a substitution.

R ∞ 3 2 You try (6) What is 0 dx x exp(−bx )? Answer to be given in class.

2 Answers to selected problems

(1) 24/a5

(3) 1r π 4 b3

(4) ∂  1  − 1 − e−a ∂a a

3