2

Is it "legal" to differentiate under the integral twice? Are there problems where there this is actually useful? If I were to differentiate under the integral sign twice, I would need to integrate the function with respect to the inserted variable twice too to get the original function, but in the process, I would need to find two different constants of integrations too. Does this make sense? Are there problems that actually simplify better by differentiating under the integral twice? Or is this completely not allowed by some definition or theorem that I'm unaware of?

Hopefully, this was not too incoherent to understand, thanks in advance.

Tom Himler
  • 2,294
  • 1
    Is this the sort of thing you mean? – Misha Lavrov Dec 07 '17 at 06:06
  • @mishalavrov That does work, but if possible, I would want to see an integral that requires differentiating under the integral sign twice. – Tom Himler Dec 08 '17 at 14:13
  • What do you mean by "requires"? An integral that would otherwise be impossible to integrate? – actinidia Dec 10 '17 at 14:44
  • @tiwaaina1 There are a good amount of examples that require differentiating under the integral sign to obtain a closed form. I'm just looking for something that would require differentiating twice. Hopefully, that clears things up? – Tom Himler Dec 10 '17 at 16:27

2 Answers2

4

Here's an integral (actually two) I did with double-differentiation: $$\int_0^\infty \frac{sin(x)^2}{x^2(x^2+1)}dx$$ $$f(a)=\int_0^\infty \frac{sin(ax)^2}{x^2(x^2+1)}dx$$ $$f'(a)=\int_0^\infty \frac{2cos(ax)sin(ax)}{x(x^2+1)}dx$$ $$f'(a)=\int_0^\infty \frac{sin(2ax)}{x(x^2+1)}dx$$ $$f''(a)=\int_0^\infty \frac{2cos(2ax)}{(x^2+1)}dx$$ using $cos(2x)=1-2sin(x)^2$ we can make it look more like our original integral by rewriting this as $$f''(a)=\int_0^\infty \frac{2(1-2sin(ax)^2)}{(x^2+1)}dx$$ $$f''(a)=\int_0^\infty \frac{2}{(x^2+1)}dx - \int_0^\infty \frac{4sin(ax)^2}{(x^2+1)}dx$$ $$f''(a)=\pi - 4\int_0^\infty \frac{sin(ax)^2}{(x^2+1)}dx$$ notice that $\frac{sin(ax)^2}{(x^2+1)}$ is the original integrand multiplied by $x^2$. If we add the original integrand, for a factor of $x^2+1$, it will cancel the $\frac{1}{1+x^2}$: $$f''(a)-4f(a)=\pi - 4\int_0^\infty \frac{sin(ax)^2}{(x^2+1)}dx - 4\int_0^\infty \frac{sin(ax)^2}{x^2(x^2+1)}dx$$ $$f''(a)-4f(a)=\pi - 4\int_0^\infty \frac{x^2sin(ax)^2+sin(ax)^2}{x^2(x^2+1)}dx$$ $$f''(a)-4f(a)=\pi - 4\int_0^\infty \frac{sin(ax)^2}{x^2}dx$$ if we can calculate that integral to the right, we can (hopefully) solve this differential equation for $f(a)$. We can't differentiate it two times with respect to $a$ because then we'd get a divergent integral. Instead, we introduce another parameter: $$g(t) = \int_0^\infty e^{-tx}\frac{4sin(ax)^2}{x^2}dx$$ differentiating twice yields $$g''(t) = \int_0^\infty e^{-tx}4sin(ax)^2dx$$ which can be solved easily (albeit tediously) with an antiderivative to yield: $$g''(t)=\frac 2t - \frac{2t}{t^2+4a^2}$$ Because of the $e^{-tx}$, $g(\infty)=0$ and $g'(\infty)=0$. Thus we can integrate to obtain $$g'(t) - g'(\infty) = \int_\infty^t \frac 2t - \frac{2t}{t^2+4a^2} dt$$ $$g'(t) = 2ln(t) - ln(t^2+4a^2)$$ We can obtain the desired $g(0)$ by integrating again (with integration by parts, which I'll leave as an exercise to the reader): $$g(0) - g(\infty) = \int_\infty^0 2ln(t) - ln(t^2+4a^2)dt$$ $$g(0) = 2\pi |a|$$ Now we can put this into the differential equation: $$f''(a)-4f(a)=\pi - 2\pi |a|$$ $$f''(a) = 4f(a) + \pi - 2\pi |a|$$ which is straightforward (but tedious) to solve, using the facts that $f(0) = 0$ and $f'(0) = 0$ to solve for the constants. This can be done more easily by solving for $ a >= 0$ with $a$ instead of $|a|$. Then the absolute value can be substituted again since $f(-a) = f(a)$ according to the integral. Once this is done, you get: $$f(a) = -\frac{\pi}{4} + \frac{\pi}{2} |a| + \frac{\pi}{4} e^{-|2a|}$$ $$f(1) = \frac{\pi}{4} (1+e^{-2})$$

2

One nice application of multiple differentiations through the integral sign: Suppose $f\in C^\infty(\mathbb R)$ and $f(0)= 0.$ Then there exists $g\in C^\infty(\mathbb R)$ such that $f(x) = xg(x)$ for all $x\in \mathbb R.$

Proof:

$$f(x) = f(x)-f(0) = \int_0^x f'(t)\, dt = x\int_0^1 f'(xu)\, du.$$

Setting $g(x) = \int_0^1 f'(xu)\, du,$ we are done if we can show $g$ is $C^\infty.$ Since $f'$ is itself $C^\infty,$ we get $g'(x) = \int_0^1 uf''(xu)\, du$ by differentiating through the integral sign (which here is easy to justify). This can be repeated indefinitely. So we get $g''(x) = \int_0^1 u^2f'''(xu)\, du$ etc., giving the desired result.

zhw.
  • 105,693