# Math Help - Integral

1. ## Integral

Challenge Question:

$\int^{\infty}_{0} \frac{\cos x - \cos 3x}{x^{2}} \ dx$

Moderator editor: Approved Challenge question.

2. Originally Posted by Random Variable
Challenge Question:

$\int^{\infty}_{0} \frac{\cos x - \cos 3x}{x^{2}} \ dx$

Moderator editor: Approved Challenge question.

$\int_0^{\infty} \frac{ \cos x - \cos{3x} }{ x^2}~dx$

$= \int_0^{\infty} \int_1^3 \frac{\sin{xy}}{x}~dxdy$

$= \frac{\pi}{2} \int_1^3 dy = \pi$

3. Originally Posted by Random Variable
Challenge Question:

$\int^{\infty}_{0} \frac{\cos x - \cos 3x}{x^{2}} \ dx$

Moderator editor: Approved Challenge question.
Alternatively. Let $J(\theta)=\int_0^{\infty}\frac{\cos(x)-\cos(\theta x)}{x^2}dx$. Then, $J'(\theta)=\int_0^{\infty}\frac{\partial}{\partial \theta}\frac{\cos(x)-\cos(\theta x)}{x^2}dx=\int_0^{\infty}\frac{\sin(\theta x)}{x}dx$. Let $\theta x=z$ to get $\int_0^{\infty}\frac{\sin(z)}{z}dz$ but this is a routine calculation ( $\frac{1}{z}=\int_0^{\infty}e^{-zt}dt$) and it equals $\frac{\pi}{2}$. So, $J'(\theta)=\frac{\pi}{2}$ and so $J(\theta)=\frac{\pi\theta}{2}+C$. But, $0=J(1)=\frac{\pi}{2}+C\implies C=-\frac{\pi}{2}$. Thus, $J(\theta)=\frac{\pi}{2}\left(\theta-1\right)$

4. or

$\int^{\infty}_{0} \frac{\cos x - \cos 3x}{x^{2}} \ dx = \int^{\infty}_{0} \int^{\infty}_{0} te^{-xt} (\cos x - \cos 3x) \ dt \ dx$

$= \int^{\infty}_{0} t \Big(\mathcal{L} \{\cos x\} - \mathcal{L} \{\cos 3x\} \Big) dt = \int^{\infty}_{0} \Big(\frac{t^{2}}{t^{2}+1} - \frac{t^{2}}{t^{2}+9} \Big) \ dt$

$= \int^{\infty}_{0} \Big(\frac{9}{t^{2}+9} - \frac{1}{1+t^{2}} \Big) \ dt = \Big(3 \tan (t/3) -\tan t\Big) \Big|^{\infty}_{0} = -\frac{\pi}{2} + \frac{3 \pi}{2} = \pi$