Get Your Copy of Calculus Power-up at Amazon Today - Click This Bar
Powered by MaxBlogPress  

Leibnitz’s Integral Rule tells us how to take the derivative with respect to x of the most general integral with variable limits.

\displaystyle \cfrac{\partial }{\partial x} \int _{\psi (x)}^{\phi (x)}f(t,x)dt=\phi ' (x)f(\phi (x),x)-\psi '(x)f(\psi (x),x)+\int _{\psi (x)}^{\phi (x)}\cfrac{\partial f(t,x)}{\partial x} dt

Memorize this formula, it is very useful. For the methods of integration we will demonstrate in this section, variable limits of integration are not involved. Leibniz’s formula reduces to a shorter form.

\displaystyle I'(x)=\cfrac{\partial }{\partial x} \int _{a}^{b}f(t,x)dt =\int _{a}^{b}\cfrac{\partial f(t,x)}{\partial x} dt

It is confusing to define differentiation of the integral in terms of \textit{x} because we use that letter so often for our independent variable and in antiderivatives so we will instead write.

\displaystyle \cfrac{d}{d\alpha } I(\alpha )=\cfrac{\partial }{\partial \alpha } \int _{a}^{b}f(t,\alpha )dt= \int _{a}^{b}\cfrac{\partial f(t,\alpha )}{\partial \alpha } dt

The symbol $latex \alpha &s=1$ represents a parameter which the integral depends on and the dummy index is t.

This formula allows an ingenious method to convert integrals we know how to evaluate into other integrals we don’t simply by differentiation. This works well because differentiation is almost always solvable.


Example 1. Evaluate the gamma function for integer n.

\displaystyle \Gamma (n+1)=n!=\int _{0}^{\infty }x^{n} e^{-x} dx

Solution 1. Integrating by parts n times is one method to solve this integral, but we will use a better method. Everything can be calculated from the following integral

\displaystyle \int _{0}^{\infty }e^{-\alpha x} dx=\cfrac{1}{-\alpha } \left. e^{-\alpha x} \right| _{0}^{\infty } =\cfrac{1}{\alpha }

Now differentiate with respect to $latex \alpha &s=1$ the result and the integral. We find that

\displaystyle \left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \int _{0}^{\infty }e^{-\alpha x} dx= \int _{0}^{\infty }x^{n} e^{-\alpha x} dx =\left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \alpha ^{-1} =n!\alpha ^{-(n+1)}

The final step is to put $latex \alpha &s=1$ equal to one in the results and we are left with.

\displaystyle \int _{0}^{\infty }x^{n}e^{-x}dx=n\text{!}


Example 2.  Consider the following integral that occurs when studying the quantum mechanical harmonic oscillator

\displaystyle I_{2n} =\int _{-\infty }^{\infty }x^{2n} e^{-x^{2} } dx .

Solution 2. Given an integral that we know how to calculate we can find the more complicated integrals with factors of $latex x^{2n} &s=1$ in the integrand. We have shown in the section on multiple integrals how we can evaluate the following integral by squaring the integral and a conversion to polar coordinates.

\displaystyle \int _{-\infty }^{\infty }e^{-x^{2} } dx=\sqrt{\pi }

We can use this integral to find the more complicated integral we are after. First we make this integral have a parameter to differentiate in the exponential by making a substitution

x^{2} =au^{2} \qquad 2xdx=2audu\quad dx=\cfrac{au}{x} dx=\sqrt{a} du

Wow that was weird. We should call that an unsubstitution.

\displaystyle {\int _{-\infty }^{\infty }e^{-x^{2} } dx=\sqrt{\alpha } \int e^{-\alpha u^{2} } du =\sqrt{\pi } } \\ {\int e^{-\alpha u^{2} } du =\sqrt{\cfrac{\pi }{\alpha } } }

Now we can get the integrals we want to solve by taking the derivatives with respect to $ \alpha $ and then setting $ \alpha $ equal to one later.

\displaystyle I_{2n} =\left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \int _{-\infty }^{\infty }e^{-\alpha x^{2} } dx =\int _{-\infty }^{\infty }x^{2n} e^{-\alpha x^{2} } dx =\left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \sqrt{\cfrac{\pi }{\alpha } }

We can calculate $latex  I_{2n} &s=1$ for the first few cases.

\displaystyle \sqrt{\pi } \left(-\cfrac{\partial }{\partial \alpha } \right)^{1} \alpha ^{-1/2}=\sqrt{\cfrac{\pi }{\alpha } } \cfrac{1}{\alpha } \left(\cfrac{1}{2} \right) \\\sqrt{\pi } \left(-\cfrac{\partial }{\partial \alpha } \right)^{2} \alpha ^{-1/2} =\sqrt{\cfrac{\pi }{\alpha } } \cfrac{1}{\alpha ^{2} } \left(\cfrac{1}{2} \right)\left(\cfrac{3}{2} \right) \\\sqrt{\pi } \left(-\cfrac{\partial }{\partial \alpha } \right)^{3} \alpha ^{-1/2} =\sqrt{\cfrac{\pi }{\alpha } } \cfrac{1}{\alpha ^{3} } \left(\cfrac{1}{2} \right)\left(\cfrac{3}{2} \right)\left(\cfrac{5}{2} \right)

This implies a general solution of the form

\displaystyle I_{2n} =\sqrt{\cfrac{\pi }{\alpha } } \cfrac{1\cdot 3\cdots (2n-1)}{2^{n} } \cfrac{1}{\alpha ^{n} } =\sqrt{\cfrac{\pi }{\alpha } } \cfrac{(2n-1)!!}{(2\alpha )^{n} }

One has the integral without the parameter $latex \alpha &s=1$ by taking this result and setting $latex \alpha =1 &s=1$.


Example 3. Which integrals can we solve by taking derivatives of

\displaystyle \int e^{i\alpha x} dx

Solution 3. We have the nth derivative of the integral with respect to $latex \alpha &s=1$.

\displaystyle I_n=\left(\cfrac{\partial }{\partial \alpha } \right)^{n} \int e^{i\alpha x} dx=\int \left(\cfrac{\partial }{\partial \alpha } \right)^{n} e^{i\alpha x} dx

I_n=\int i^{n} x^{\alpha } e^{i\alpha x} dx =\int i^{n} x^{n} (\cos \alpha x+i\sin \alpha x)

\displaystyle \int e^{i\alpha x} dx= \cfrac{e^{i\alpha x} }{i\alpha }

\left(\cfrac{\partial }{\partial \alpha } \right)^{n} \int e^{i\alpha x} dx = \left(\cfrac{\partial }{\partial \alpha } \right)^{n} \cfrac{e^{i\alpha x} }{i\alpha }

 \int x^{n} \cos (\alpha x)dx = Re\cfrac{1}{i^{n} } \left(\cfrac{\partial }{\partial \alpha } \right)^{n} \cfrac{e^{i\alpha x} }{i\alpha }

 \int x^{n} \sin ( \alpha x)dx = Im\cfrac{1}{i^{n} } \left(\cfrac{\partial }{\partial \alpha } \right)^{n} \cfrac{e^{i\alpha x} }{i\alpha }

Here we see how integration can be written in terms of differentiations of a particular function. The usual method would be to integrate by parts \textit{n} times. This calculation involves only n differentiations and in principle gives the $latex x^{n} \sin x$ and $latex x^{n} \cos x$ integrals at the same time as the real and imaginary components.

Leibniz’s rule for the nth order product rule for differentiation becomes useful in this case.

\displaystyle {\cfrac{d^{n} }{dx^{n} } (u(x)v(x))=\sum _{k=0}^{n}\cfrac{n!}{(n-k)!k!} u^{(n-k)} v^{(k)} } \\ {\cfrac{d}{dx} u(x)v(x)=\cfrac{1!}{1!0!} u^{(1)} v^{(0)} +\cfrac{1!}{0!1!} u^{(0)} v^{(1)} =u'v+uv'} \\ {\cfrac{d^{2} }{dx^{2} } u(x)v(x)=u''v+2u'v'+uv''}

And so on for higher derivatives following the pattern of Pascal’s triangle for the coefficients.


Example 4. Differentiation under the integral sign can be used as a practical matter of calculation. For example,

\displaystyle \int \cfrac{dx}{(x-a)^{3} (x-b)^{3} }

Solution 4. This is a straight forward partial fractions expansion problem. The form of the partial fractions is

\cfrac{1}{(x-a)^{3} (x-b)^{3} } =\cfrac{A}{x-a} +\cfrac{B}{(x-a)^{2} } +\cfrac{C}{(x-a)^{3} } +\cfrac{D}{x-b} +\cfrac{E}{(x-b)^{2} } +\cfrac{F}{(x-b)^{3} }

To continue requires multiplying all that out and then solving six equations and six unknowns. The plug in value trick at x=a and x=b is not so useful because that only gives two equations to solve for the six unknowns. This is a full blown linear algebra operation. With differentiation under the integral sign all this will be replaced with differentiation.

Consider the simpler integral

\displaystyle \int \cfrac{dx}{(x-a)(x-b)}

Now take the second derivative with respect to \textit{a} followed by the second derivative with respect to b

\displaystyle {\left(\cfrac{\partial ^{2} }{\partial b^{2} } \right)\left(\cfrac{\partial ^{2} }{\partial a^{2} } \right)\int \cfrac{dx}{(x-a)(x-b)} =4\int \cfrac{dx}{(x-a)^{3} (x-b)^{3} } =4I_{3,3} } \\ {I_{3,3} =\cfrac{1}{4} \left(\cfrac{\partial ^{2} }{\partial b^{2} } \right)\left(\cfrac{\partial ^{2} }{\partial a^{2} } \right)\int \cfrac{dx}{(x-a)(x-b)} }

The integral that is about to get differentiated is much simpler to handle by partial fractions.

\displaystyle \int \cfrac{dx}{(x-a)(x-b)} =\cfrac{1}{b-a} \int \cfrac{dx}{x-a} -\cfrac{1}{b-a} \int \cfrac{dx}{x-b} =\cfrac{1}{b-a} \ln \left|\cfrac{x-a}{x-b} \right| +C

\displaystyle I_{3,3} (a,b)=\cfrac{1}{4} \left(\cfrac{\partial ^{2} }{\partial b^{2} } \right)\left(\cfrac{\partial ^{2} }{\partial a^{2} } \right)\left[\cfrac{1}{b-a} \ln \left|\cfrac{x-a}{x-b} \right|\right]

The problem is reduced to taking derivatives by the product rule. I would say differentiation would win in a race with partial fractions by hand at least at some point. Imagine taking 100 derivatives of a function versus solving a system of 100 equations then integrating all the parts. Actually don’t imagine that. The goal is not to promote differentiation under the integral sign but recognize that it can be a useful technique. It is quite common to build up forms from a simple expression, and pumping up the different factor powers by differentiation. The new thing here demonstrated with this equation is that we can have several different parameters to differentiate with to build more complicated integrals. Mixed partial derivatives commute so we can compute the partial derivatives in any order we choose.


Example 5. Take the result of a difficult integral and calculate even harder integrals by differentiation under the integral sign.

\displaystyle \int _{0}^{2\pi }\cfrac{dx}{\alpha -\cos x} =\cfrac{2\pi }{\sqrt{\alpha ^{2} -1} } \quad \quad \alpha >1

Solution 5. We showed how to evaluate integrals like the one indicated using the universal substitution in the previous section. We can generate a more difficult integrals by differentiation with respect to the parameter $latex \alpha &s=1$.

\displaystyle {\left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \int _{0}^{2\pi }\cfrac{dx}{\alpha -\cos x} =\left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \cfrac{2\pi }{\sqrt{\alpha ^{2} -1} } } \\ {\left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \int _{0}^{2\pi }\cfrac{dx}{\alpha -\cos x} =\int _{0}^{2\pi }\cfrac{n!dx}{(\alpha -\cos x)^{n+1} } } \\ {\int _{0}^{2\pi }\cfrac{dx}{(\alpha -\cos x)^{n+1} } =\cfrac{1}{n!} \left(-\cfrac{\partial }{\partial \alpha } \right)^{n} \cfrac{\pi }{\sqrt{\alpha ^{2} -1} } }

The first such example is

\displaystyle \int _{0}^{2\pi }\cfrac{dx}{(\alpha -\cos x)^{2} } =\cfrac{2\pi \alpha }{(\alpha ^{2} -1)^{3/2} }

All the examples up until now have been direct calculation to find new integrals. There is a second mode of operation for differentiation under the integral sign where differentiation produces a differential equation in terms of the original integral. Differentiation under the integral sign can be used to compute new integrals from tables of integrals. Differentiation can be done with respect to multiple parameters when possible to build up forms with different components. Since differentiation is in general always solvable compared to integration, differentiation under the integral sign can be a useful method.


Example 6. Sometime differentiation under the integral sign can be useful for cancelling factors that make the integral more difficult. Prove the following integral

\displaystyle \int _{0}^{1}\cfrac{x^{n} -1}{\ln x} dx=\ln (1+n)

Solution 6. We can slip a factor of $x^\alpha $ onto the $x^{n} $ and use it to differentiate away the logarithm.

\displaystyle f(\alpha )=\int _{0}^{1}\cfrac{x^{n+\alpha } -1}{\ln x} dx \\f'(\alpha )=\int _{0}^{1}x^{n} x^{\alpha } dx=\cfrac{1}{1+n+\alpha } \\ f(\alpha )=\ln (1+n+\alpha )+C

We need to find the integration constant. Note that when $\alpha =-n$ the numerator in the integrand is zero for the first integral. From this we can conclude that $latex C=0 &s=1$.

\displaystyle f(0)=\int _{0}^{1}\cfrac{x^{n} -1}{\ln x} dx=\ln (1+n)


Example 7. A related example is to find the following integral

\displaystyle \int _{0}^{\infty }\cfrac{e^{-\mu x} -e^{-\nu x} }{x} dx

Solution 7. This integral is really hard, but now we have all the tools to evaluate it. Differentiating with respect to $latex \mu $ or $latex \nu $, doesn’t really give much progress. The next possible thing to try is to make a substitution to get rid of infinity.

u=e^{-x} \quad du=-e^{-x} dx=-udx

Under this substitution the integral transforms into

\displaystyle \int _{1}^{0}\cfrac{u^{\mu } -u^{\nu } }{u\ln u} du=\int _{0}^{1}\cfrac{u^{\nu -1} -u^{\mu -1} }{\ln u} du

It is not obvious that this integral is simpler than the one we started with, but we can continue none the less. Now we do one of our ingenious techniques again. We add and subtract one in the numerator.

\displaystyle \int _{0}^{1}\cfrac{u^{\nu -1} -u^{\mu -1} }{\ln u} du =\int _{0}^{1}\cfrac{u^{\nu -1} -1}{\ln u} du -\int _{0}^{1}\cfrac{u^{\mu -1} -1}{\ln u} du

From the previous example we have done these integrals! So we have that

\displaystyle \int _{0}^{\infty }\cfrac{e^{-\mu x} -e^{-\nu x} }{x} dx=\ln \left(\nu /\mu \right)


Example 8. Here is another case when we use differentiation to cancel a factor. Find the integral of

\displaystyle \int _{0}^{\infty }\cfrac{\sin x}{x} dx

Solution 8. Since we know how to solve

\displaystyle \int \sin xe^{-\alpha x} dx

We can aim to take this integral.

\displaystyle I(\alpha )=\int _{0}^{\infty }\cfrac{\sin x}{x} e^{-\alpha x} dx

Taking the derivative with respect to $latex \alpha$ we have

\begin{array}{l} {I(b)=\displaystyle\int _{0}^{\infty }\cfrac{\sin x}{x} e^{-\alpha x} dx\, \qquad, I(\infty )=0} \\ \\ {I'(\alpha )=-\displaystyle\int _{0}^{\infty }(\sin x) e^{-\alpha x} dx=-Im\int _{0}^{\infty }e^{(i-\alpha )x} dx } \\ \\ {I'(\alpha )=-Im\left. \cfrac{e^{(i-\alpha )x} }{i-\alpha } \right|_{0}^{\infty } =-Im\cfrac{e^{-\infty } -1}{i-\alpha } =Im\cfrac{1}{i-\alpha}}=\cfrac{-1}{1+\alpha ^2}\\ {I(\alpha )=-\arctan (\alpha )+C} \\{I(\infty )=-\pi /2+C=0} \\ {C=\pi /2} \\ {I(\alpha )=\frac{\pi }{2} -\arctan (\alpha )} \\ \\{I(0)=\displaystyle\int _{0}^{\infty }\frac{\sin x}{x} dx=\frac{\pi }{2} } \end{array}


Example 9. Here is another example of a move to cancel a pesky factor in the denominator. Calculate

\displaystyle I(1)=\int _{0}^{\pi /2}\cfrac{x}{\tan x} dx

Solution 9. Use a substitution of

x\to \arctan (\alpha \tan (x))

when $latex\alpha =1$

it returns x back in the numerator of the integrand.

\displaystyle {I(\alpha )} = {\int _{0}^{\pi /2}\cfrac{\arctan (\alpha \tan x)}{\tan x} dx }

 I'(\alpha)=\int_0^{\pi/2}\cfrac{dx}{1+\alpha^2\tan^2x}

I’m not quite sure how to evaluate this integral yet with our known techniques. The universal substitution doesn’t really work because there is too high of a power in the denominator to factor. Let us try a further substitution which stretches out the integral over the real line.

\displaystyle {u=\tan x\quad \quad \, du=\sec ^{2} xdx=(1+u^{2} )dx\quad \quad u(0)=0\quad \, u(\pi /2)=\infty } \\ {I'(\alpha )=\int _{0}^{\infty }\cfrac{du}{1+u^{2} } \cfrac{1}{1+\alpha ^{2} u^{2} } } \\ {I'(\alpha )=\cfrac{1}{2\alpha ^{2} } \int _{-\infty }^{\infty }\cfrac{du}{(1+u^{2} )(\alpha ^{-2} +u^{2} )} }

This integral is now actually very easy, but we have to wait until a later sectionto learn how to do it by the method of contour integration. I will just quote the result so we can continue.

\displaystyle {I'(\alpha )=\cfrac{\pi }{2+2\alpha } } \\ {I(\alpha )=\cfrac{\pi }{2} \ln (1+\alpha )+C} \\ {I(0)=0\quad \Leftrightarrow C=0} \\ {I(1)=\int _{0}^{\pi /2}\cfrac{x}{\tan x} dx =\cfrac{\pi }{2} \ln 2}


Example 10. Show that

\displaystyle I=\int _{0}^{\pi }\arctan (\cos x)dx=0

Solution 10. We will use differentiation under the integral to derive a differential equation like before. We make the integral into

\displaystyle I(\alpha )=\int _{0}^{\pi }\arctan (\alpha \cos x)dx \quad \quad \, I(1)=I

Now we differentiate with respect to $\alpha $ and we easily get

\displaystyle I'(\alpha )=\int _{0}^{\pi }\cfrac{\cos x}{1+\alpha ^{2} \cos ^{2} x} dx

Now we notice that the denominator is even over the domain of integration and the numerator is odd over the domain of integration. All together the integral equals zero.

\displaystyle {I'(\alpha )=0} \\ {I(\alpha )=C}

But we know from the original integral that when $latex \alpha =0$ then $latex \arctan (0)=0$

\displaystyle {I(0)=0\Leftrightarrow C=0} \\ {I(\alpha )=0} \\ {I=I(1)=0}

Back to Home:

Back to Index:

Previous Topic: Universal Substitution

Next Topic: Integration under the Integral Sign


  • Share/Bookmark
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading ... Loading ...

One Response to “Differentiating Under the Integral Sign”

  • Trav says:

    Hi Merrin,

    Thanks for explaining differentiation under the integral sign in such a elegant and efficent way. I now want to purchase your book to learn more.

    One question – I can’t see any of the mathematical terms in the written passages, as it looks like the fonts are not being picked up. Is there any I can see this? Would you have a copy of the content in this webpage you could kindly send me?

    Thanks very much,

    Travolta

Leave a Reply

Hits Since 4/1/09
Visitor Map
Get Free Bonus

G-Lock opt-in manager for bulk email software.

Ratings
  • Home 2 votes, average: 5.00 out of 52 votes, average: 5.00 out of 52 votes, average: 5.00 out of 52 votes, average: 5.00 out of 52 votes, average: 5.00 out of 5 (5.00 out of 5)