MHB Solve the following integral without complex analysis:

Click For Summary
The integral \(\int^{\infty}_{0} \frac{\cos(x)}{1+x^2}\,dx\) can be evaluated without complex analysis by using integration by parts, although this method may not simplify the process significantly. An alternative approach involves differentiating under the integral sign, leading to a solution of \(\frac{\pi}{2e}\). The discussion also touches on methods involving Fourier transforms and residues, which yield the same result. Ultimately, the integral evaluates to \(\frac{\pi}{2e}\), demonstrating the effectiveness of various mathematical techniques.
alyafey22
Gold Member
MHB
Messages
1,556
Reaction score
2
\[\int^{\infty}_{0} \frac{\cos(x) }{1+x^2}\,dx\]

I know it can be solved by Fourier transform and also by residues , but my teacher
asked me to solve it by not using transformation or complex analysis (Happy)
 
Last edited by a moderator:
Physics news on Phys.org
ZaidAlyafey said:
$\int^{\infty}_{0} \frac{\cos(x) }{1+x^2}$

I know it can be solved by Fourier transform and also by residues , but my teacher
asked me to solve it by not using transformation or complex analysis (Happy)
Try integration by parts twice.

Warning: There are some limits that come up which I think can be removed. But I didn't check that in detail.

-Dan
 
topsquark said:
Try integration by parts twice.

-Dan

Is this just a suggestion , or does it really work because it doesn't get any simper ?

topsquark said:
Warning: There are some limits that come up which I think can be removed. But I didn't check that in detail.

-Dan

I don't get what you mean ?
 
ZaidAlyafey said:
$\displaystyle \int^{\infty}_{0} \frac{\cos(x) }{1+x^2}\;{dx}$

Let $\displaystyle I(\lambda) = \int_{0}^{\infty}\frac{\sin(\lambda x)}{x(1+x^2)}\;{dx} ~~ (\lambda > 0). $ Differentiating this w.r.t. $\lambda$ we have $\displaystyle I'(\lambda) = \int^{\infty}_{0} \frac{\cos(\lambda x) }{1+x^2}\;{dx}.$

Also $\displaystyle I''(\lambda) = -\int_{0}^{\infty}\frac{x\sin(\lambda x)}{1+x^2}\;{dx}$ thus $\displaystyle I(\lambda)-I''(\lambda) =\int_{0}^{\infty}\frac{(1+x^2) \sin( \lambda x)}{x(1+x^2)}\;{dx} = \int_{0}^{\infty} \frac{\sin(\lambda x)}{x}\;{dx}.$

Letting $\displaystyle t = \lambda x$ we have $\displaystyle \int_{0}^{\infty} \frac{\sin(\lambda x)}{x}\;{dx} = \int_{0}^{\infty} \frac{\sin{t}}{t}\;{dt} = \frac{\pi}{2}$ (well-known). Hence $\displaystyle I(\lambda)-I''(\lambda) = \frac{\pi}{2}$.
Solving $ I''(\lambda)-I(\lambda)+\frac{\pi}{2} =0$ we get $ I(\lambda) = \mathcal{C}_{1}e^x+\mathcal{C}_{2}e^{-x}+\frac{\pi}{2}$. From the integral we observe that $I(0) = 0$, thus we have $ 0 = \mathcal{C}_{1}+\mathcal{C}_{2}+\frac{\pi}{2}$ so $\mathcal{C}_{1}+\mathcal{C}_{2} = -\frac{\pi}{2}$ (1). But also by differentiating we get $I'(\lambda) = \mathcal{C}_{1}e^x-\mathcal{C}_{2}e^{-x}$. From our integral we observe that $I'(0) = \frac{\pi}{2}$, and thus we have $ \mathcal{C}_{1}-\mathcal{C}_{2} = \frac{\pi}{2}$ (2). Adding (1) and (2) we have $\mathcal{C}_{1} = 0$ and/so $\mathcal{C}_{2} = -\frac{\pi}{2}$. Hence $\displaystyle I'(\lambda) = \frac{\pi}{2e^{\lambda}}$, thus:

$$\displaystyle \int^{\infty}_{0} \frac{\cos(x) }{1+x^2} = \frac{\pi}{2e}. $$
 
Last edited:
Sherlock said:
Let $\displaystyle I(\lambda) = \int_{0}^{\infty}\frac{\sin(\lambda x)}{x(1+x^2)}\;{dx} ~~ (\lambda > 0). $. Differentiating this w.r.t. $\lambda$ we have $\displaystyle I'(\lambda) = \int^{\infty}_{0} \frac{\cos(\lambda x) }{1+x^2}\;{dx}.$

Also $\displaystyle I''(\lambda) = -\int_{0}^{\infty}\frac{x\sin(\lambda x)}{1+x^2}\;{dx}$ thus $\displaystyle I(\lambda)-I''(\lambda) =\int_{0}^{\infty}\frac{(1+x^2) \sin( \lambda x)}{x(1+x^2)}\;{dx} = \int_{0}^{\infty} \frac{\sin(\lambda x)}{x}\;{dx}.$

Letting $\displaystyle t = \lambda x$ we have $\displaystyle \int_{0}^{\infty} \frac{\sin(\lambda x)}{x}\;{dx} = \int_{0}^{\infty} \frac{\sin{t}}{t}\;{dt} = \frac{\pi}{2}$ (well-known). Hence $\displaystyle I(\lambda)-I''(\lambda) = \frac{\pi}{2}$.
Solving $ I''(\lambda)-I(\lambda)+\frac{\pi}{2} =0$ we get $ I(\lambda) = \mathcal{C}_{1}e^x+\mathcal{C}_{2}e^{-x}+\frac{\pi}{2}$. From the integral we observe that $I(0) = 0$, thus we have $ 0 = \mathcal{C}_{1}+\mathcal{C}_{2}+\frac{\pi}{2}$ so $\mathcal{C}_{1}+\mathcal{C}_{2} = -\frac{\pi}{2}$ (1). But also by differentiating we get $I'(\lambda) = \mathcal{C}_{1}e^x-\mathcal{C}_{2}e^{-x}$. From our integral we observe that $I'(0) = \frac{\pi}{2}$, and thus we have $ \mathcal{C}_{1}-\mathcal{C}_{2} = \frac{\pi}{2}$ (2). Adding (1) and (2) we have $\mathcal{C}_{1} = 0$ and/so $\mathcal{C}_{2} = -\frac{\pi}{2}$. Hence $\displaystyle I'(\lambda) = \frac{\pi}{2e^{\lambda}}$, thus:

$$\displaystyle \int^{\infty}_{0} \frac{\cos(x) }{1+x^2} = \frac{\pi}{2e}. $$


Feynman would be proud - differentiating under the integral sign!
 
ZaidAlyafey said:
I don't get what you mean ?
Well, I like Sherlock's method better, but here's a bit more on the integration by parts.

Obviously
\int_a^b p~dq = pq |_a^b - \int_a^b q~dp

There will be two limits cos(x)atan(x)|_0^{\infty} and sin(x)atan(x)|_0^{\infty}

I didn't check these limits to see if they actually cancel out. (I still didn't. Lazy again.)

-Dan

Ach-choo: You say that like it's a bad thing...
 
Ok , I will show the other two methods .

First : By residues :

\int^{\infty}_0 \frac{\cos(x) }{x^2+1}=\frac{1}{2}\int^{\infty}_{-\infty} \frac{\cos(x) }{x^2+1}=\mathcal{Re}( \frac{1}{2}\int^{\infty}_{-\infty} \frac{e^{iz} }{z^2+1})

By drawing a sermi-circle in the upper half plane we get the following :

\frac{1}{2}\int^{\infty}_{-\infty} \frac{e^{ix} }{x^2+1}= \pi i \mathcal{Rez}(f(z) ,i )

\pi i (\frac{e^{iz}}{2z}|_{z=i})= \pi i \frac{e^{-1}}{2i}= \frac{\pi}{2e}
 
I'm looking forward to the Fourier transform method (unless you meant Laplace (Giggle)).
 
Second by the Fourier integral :

f(x)= \int^{\infty}_0 A(\lambda) \cos(\lambda x)d\lambda +\int^{\infty}_0 B(\lambda) \sin(\lambda x)d\lambda -----(1)

f(x) = \begin{cases}e^{-x} &; \mbox{if } x > 0 \\e^{x} &; \mbox{if } x<0 \\1 &; \mbox{if } x=0\end{cases}

A(\lambda)= \frac{1}{\pi}\int^{\infty}_{-\infty}\, f(x)\, \cos(\lambda x)dx

Now since f(x) is an even function :

A(\lambda)= \frac{2}{\pi}\int^{\infty}_{0}\, e^{-x}\, \cos(\lambda x)dx =\frac{ 2\mathcal{L}(\cos(\lambda x))}{\pi}= \frac{2}{\pi(x^2+\lambda^2)}

B(\lambda)=\int^{\infty}_{-\infty} f(x) \sin(\lambda x)dx=0

By evenness the upper integral is zero .

substituting in ---(1) we get the following : e^{-x}= \int^{\infty}_0 \frac{2\cos(\lambda x)}{\pi(x^2+\lambda^2)}d\lambda \,\, \, x>0

Now putting x =1 we get the following :

e^{-1}= \frac{2}{\pi}\int^{\infty}_0 \frac{\cos(\lambda)}{(1+\lambda^2)}d\lambda

\int^{\infty}_0 \frac{\cos(x)}{(1+x^2)}dx= \frac{\pi}{2e}
 
Last edited:
  • #10
Sherlock said:
I'm looking forward to the Fourier transform method (unless you meant Laplace (Giggle)).

I always think that Laplace transform is a special case of the general Fourier transform .
 

Similar threads

  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 7 ·
Replies
7
Views
4K
  • · Replies 2 ·
Replies
2
Views
886
  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 2 ·
Replies
2
Views
2K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 4 ·
Replies
4
Views
3K
  • · Replies 2 ·
Replies
2
Views
3K