# Surely You're Joking, Mr. Feynman! $\int_0^\infty\frac{\sin^2x}{x^2(1+x^2)}\,dx$ [duplicate]

Prove the following \begin{equation}\int_0^\infty\frac{\sin^2x}{x^2(1+x^2)}\,dx=\frac{\pi}{4}+\frac{\pi}{4e^2}\end{equation}

I would love to see how Mathematics SE users prove the integral preferably with the Feynman way (other methods are welcome). Thank you. (>‿◠)✌

Original question:

And of course, for the sadist with a background in differential equations, I invite you to try your luck with the last integral of the group.

\begin{equation}\int_0^\infty\frac{\sin^2x}{x^2(1+x^2)}\,dx\end{equation}

Source: Integration: The Feynman Way

## marked as duplicate by Shuchang, user88595, Davide Giraudo real-analysis StackExchange.ready(function() { if (StackExchange.options.isMobile) return; $('.dupe-hammer-message-hover:not(.hover-bound)').each(function() { var$hover = $(this).addClass('hover-bound'),$msg = $hover.siblings('.dupe-hammer-message');$hover.hover( function() { $hover.showInfoMessage('', { messageElement:$msg.clone().show(), transient: false, position: { my: 'bottom left', at: 'top center', offsetTop: -7 }, dismissable: false, relativeToBody: true }); }, function() { StackExchange.helpers.removeMessages(); } ); }); }); May 22 '14 at 14:46

• "The Feynman way" is just a fancy name for the good old differentiation under the integral? – Daniel Fischer May 21 '14 at 11:30
• @DanielFischer I know that Sir but I prefer naming "The Feynman Way" (ô‿ô) – Anastasiya-Romanova 秀 May 21 '14 at 11:33
• @DanielFischer: there seems to be a tendency on this site to label any differentiation of an artificially introduced parameter under the integral sign as "Feynman's <method, way, etc.>." I doubt Feynman invented it, but I see that loads of people read "Surely You're Joking...". – Ron Gordon May 21 '14 at 12:20
• @RonGordon Indeed. It's a good read, by the way. Now, will you have lemon or milk in your tea? – Daniel Fischer May 21 '14 at 12:23
• @V-Moy: Hey, I never said it was wrong; I just think it is a little funny. BTW it would not be the first time that a method or something else is named after its popularizer rather than its inventor. – Ron Gordon May 21 '14 at 12:38

This integral is readily evaluated using Parseval's theorem for Fourier transforms. (I am certain that Feynman had this theorem in his tool belt.) Recall that, for transform pairs $f(x)$ and $F(k)$, and $g(x)$ and $G(k)$, the theorem states that

$$\int_{-\infty}^{\infty} dx \, f(x) g^*(x) = \frac1{2 \pi} \int_{-\infty}^{\infty} dk \, F(k) G^*(k)$$

In this case, $f(x) = \frac{\sin^2{x}}{x^2}$ and $g(x) = 1/(1+x^2)$. Then $F(k) = \pi (1-|k|/2) \theta(2-|k|)$ and $G(k) = \pi \, e^{-|k|}$. ($\theta$ is the Heaviside function, $1$ when its argument is positive, $0$ when negative.) Using the symmetry of the integrand, we may conclude that

\begin{align}\int_0^{\infty} dx \frac{\sin^2{x}}{x^2 (1+x^2)} &= \frac{\pi}{2} \int_0^{2} dk \, \left ( 1-\frac{k}{2} \right ) e^{-k} \\ &= \frac{\pi}{2} \left (1-\frac1{e^2} \right ) - \frac{\pi}{4} \int_0^{2} dk \, k \, e^{-k} \\ &= \frac{\pi}{2} \left (1-\frac1{e^2} \right ) + \frac{\pi}{2 e^2} - \frac{\pi}{4} \left (1-\frac1{e^2} \right )\\ &= \frac{\pi}{4} \left (1+\frac1{e^2} \right )\end{align}

• @V-Moy: Yeah, I'm fast like that. – Ron Gordon May 21 '14 at 12:38
• Surely You're Joking, Mr. Gordon! （‐＾▽＾‐） – Anastasiya-Romanova 秀 May 21 '14 at 12:41
• @RonGordon Why did you answer the same question again since you knew it was a duplicate? You have already answered this question for me : math.stackexchange.com/questions/691798/…. – Jeff Faraci May 22 '14 at 14:15
• @Integrals: because I answered it three months ago and at my age, dementia sets in. I admit that sometimes I just answer the question without looking back through my vast database of answers. So, no, I did not know it was a duplicate. – Ron Gordon May 22 '14 at 14:21
• @Integrals: I would have if I had known. But so what - the worst thing in the world is that duplicate correct (and consistent) answers exist in the site? Vote to close as a duplicate if this bothers you. – Ron Gordon May 22 '14 at 14:27

Here is my attempt: \begin{align} \int_0^\infty\frac{\sin^2x}{x^2(1+x^2)}dx&=\int_0^\infty\left[\frac{\sin^2x}{x^2}-\frac{\sin^2x}{1+x^2}\right]dx\\ &=\int_0^\infty\frac{\sin^2x}{x^2}dx-\frac{1}{2}\int_0^\infty\frac{1-\cos2x}{1+x^2}dx\\ &=\frac{\pi}{2}-\frac{1}{2}\int_0^\infty\frac{1}{1+x^2}dx+\frac{1}{2}\int_0^\infty\frac{\cos2x}{1+x^2}dx\\ &=\frac{\pi}{2}-\frac{1}{2}\frac{\pi}{2}+\frac{1}{2}\frac{\pi}{2e^2}\\ &=\frac{\pi}{4}+\frac{\pi}{4e^2} \end{align} where I use these links: $\displaystyle\int_0^\infty\frac{\sin^2x}{x^2}dx$ and $\displaystyle\int_0^\infty\frac{\cos2x}{1+x^2}dx$ to help me out.

Unfortunately, this is not the Feynman way but I still love this method.

• Thanks for fixing my answer @MycrofD. I'm too excited so I forgot about my English grammar. ≥Ö‿Ö≤ – Anastasiya-Romanova 秀 May 21 '14 at 11:30
• Next time put your attempt in the question. Besides, you got it right (>‿◠)✌. – Shahar May 21 '14 at 11:53
• @Shahar Thanks, +1 for your emo. ≧◠◡◠≦✌ – Anastasiya-Romanova 秀 May 21 '14 at 12:09
• @V-Moy You seem to be an expert in emo's and integrals. ✌ – Sawarnik May 21 '14 at 17:43
• @Sawarnik You might say I'm expert in emo but not in integral, not yet (✿◠‿◠) – Anastasiya-Romanova 秀 May 22 '14 at 8:17

Consider $$I(a)=\int_0^\infty\frac{\sin^2(ax)}{x^2(x^2+1)}dx$$ Differentiate it twice. Since $$\int_0^\infty\frac{\cos(kx)}{x^2+1}dx=\frac{\pi}{2e^k}$$ for $k>0$ we get $I''(a)=\pi e^{-2a}$. Note that $I'(0)=I(0)=0$, so after solving respective IVP we get $$I(a)=\frac{\pi}{4}(-1+2a+e^{-2a})$$ Now it only remains to substitute for $a=1$.

• Wait a second! Why never cross to mind to use Feynman method twice?? +1 Sir! ≥►.◄≤ – Anastasiya-Romanova 秀 May 21 '14 at 12:47
• @V-Moy Because you're not thinking like Feynman! Suppose the Feynman method just transforms your complicated integral into another complicated integral. Well, what tricks do you know for handling complicated integrals? That's right, the Feynman method! :) – David H May 21 '14 at 13:59
• Thanks for your advice Mr. @DavidH. I'll try to think like Feynman. I have a lot of time though. ᕙ(^▽^)ᕗ – Anastasiya-Romanova 秀 May 21 '14 at 16:17
• Why did you post this solution again? You knew this was a duplicate, this is a great solution but still. -1. math.stackexchange.com/questions/691798/… – Jeff Faraci May 22 '14 at 14:14
• @Integrals because it is not forbidden, and this answer perfectly fits to the question even more than the in the link you gave above. – Norbert May 22 '14 at 15:47