Integral of weird function

I am trying to solve the following integral

$$$${\cal I}=\int_{-\infty}^{\infty}\frac{d\omega}{2\pi}\frac{2\tau}{1+\omega^{2}\tau^{2}}\frac{\sin^{2}\left[\left(\omega+\Omega\right)t/2\right]}{\left[\left(\omega+\Omega\right)/2\right]^{2}}$$$$ for finite $$\Omega$$. I could only solve it for $$\Omega=0$$, yielding

$$$${\cal I}=2 \left[\tau^{2}\left(e^{-t/\tau}-1\right)+\tau \thinspace t\right]$$$$

I also tried to solve using the fact below

$$$${\cal I}=\int_{0}^{t}\int_{0}^{t}dt_{1}dt_{2} e^{-|t_1-t_2|/\tau}e^{i\Omega\left(t_{1}-t_{2}\right)}=\int_{-\infty}^{\infty}\frac{d\omega}{2\pi}\frac{2\tau}{1+\omega^{2}\tau^{2}}\frac{\sin^{2}\left[\left(\omega+\Omega\right)t/2\right]}{\left[\left(\omega+\Omega\right)/2\right]^{2}}$$$$ although this did not help much. Any thoughts?

Let $$I_0=\int_{-\infty}^{\infty}\frac{d\omega}{2\pi}\frac{2\tau}{1+\omega^{2}\tau^{2}}\frac{\sin^{2}\left[\left(\omega+\Omega\right)t/2\right]}{\left[\left(\omega+\Omega\right)/2\right]^{2}}$$ After easy transformations we can write the integral in the form $$I_0=\frac{t^3}{2\pi\tau}\int_{-\infty}^{\infty}\frac{dx}{a^2+(x-b)^2}\frac{\sin^2x}{x^2}$$ where $$a=\frac{t}{2\tau} , \,b=\frac{\Omega t}{2}$$.

We can also rewrite the integral in the form $$I_0=\frac{t^3}{2\pi\tau}\int_{-\infty}^{\infty}\frac{dx}{a^2+(x-b)^2}\frac{1-\cos2x}{2\,x^2}=\frac{t^3}{2\pi\tau}\Re \,I$$ where $$I=\frac{1}{2}\int_{-\infty}^{\infty}\frac{dx}{(x-b+ia)(x-b-ia)}\frac{1-e^{2ix}}{x^2}$$ To evaluate $$I$$ we go in the complex plane and make a closed contour - adding a big half-circle with the radius $$R\to\infty$$ (counter-clockwise) in the upper half-plane, and a small half-circle with the radius $$r\to0$$ around $$z=0$$ (clockwise), also in the upper half-plane. $$\oint=I+I_R+I_r=2\pi i\sum Res$$ We have a single simple pole inside our contour (at $$z=b+ia$$). It is easy to show that $$I_R\to0$$ at $$R\to\infty$$, therefore $$I=2\pi i Res_{z=b+ia}\frac{1}{2}\frac{1}{(x-b+ia)(x-b-ia)}\frac{1-e^{2ix}}{x^2}-I_r$$ But $$-I_r$$ give us $$\,\,\pi i \,Res_{z=0}\frac{1}{2}\frac{1}{(x-b+ia)(x-b-ia)}\frac{1-e^{2ix}}{x^2}$$.

Evaluating residues, we get $$I=\frac{2\pi i}{2}\frac{1-e^{2ib-2a}}{(b+ia)^2\,2ia}+\frac{\pi i}{2}\frac{-2i}{(b-ia)(b+ia)}$$

and, after easy transformation $$I=\frac{\pi}{a^2+b^2}\Big(1+\frac{1}{2a}\big(e^{-2i\tan^{-1}\frac{a}{b}}-e^{-2a+2ib-2i\tan^{-1}\frac{a}{b}}\big)\Big)$$ Taking the real part, putting $$a$$ and $$b$$ and switching to $$I_0$$, we finally get the answer: $$\bbox[5px,border:2px solid #C0A000]{I_0=\frac{2\tau t}{1+\Omega^2\tau^2}\Big[1+\frac{\tau}{t}\Big(e^{-\frac{t}{\tau}}\cos(\Omega t+2\tan^{-1}\Omega \tau)-\cos(2\tan^{-1}\Omega \tau)\Big)\Big]}$$ It is interesting to check the answer in specific cases:

1. $$\tau=0\,\,\Rightarrow \frac{I_0}{2\tau}=t$$

On the other hand, $$\frac{I_0}{2\tau}=\int_{-\infty}^\infty\frac {d\omega}{2\pi}\frac{\sin^2(\frac{\omega+\Omega}{2}t)}{(\frac{\omega+\Omega}{2})^2}=\frac{1}{\pi}\int_{-\infty}^\infty\frac{\sin^2(xt)}{x^2}dx=t$$

1. $$\Omega=0$$ $$I_0 (\Omega=0)=2\tau t\Big[1+\frac{\tau}{t}\Big(e^{-\frac{t}{\tau}}-1\Big)\Big]$$ what is in agreement with your partial solution.
2. $$t=0\,\, \Rightarrow I_0=0$$

Indeed, $$I_0(t\to0)\to \frac{2\tau^2}{1+\Omega^2\tau^2}\big(e^{-\frac{t}{\tau}}-1\big)\cos(2\tan^{-1}\Omega\tau)\to 0$$ 4. $$\tau\to\infty$$ $$I_0\to\frac{2}{\Omega^2}\Big(\cos(\Omega t+\pi)-\cos\pi\Big)=\frac{2}{\Omega^2}\Big(1-\cos(\Omega t)\Big)$$ On the other hand, using $$\lim_{\epsilon\to 0}\frac{\epsilon}{x^2+\epsilon^2}=\pi\delta(x)$$ (the Dirac' delta-function) $$I_0(\tau\to\infty)=\int_{-\infty}^\infty\frac{d\omega}{\pi}\frac{1/\tau}{\omega^2+(1/\tau)^2}\frac{\sin^{2}\left[\left(\omega+\Omega\right)t/2\right]}{\left[\left(\omega+\Omega\right)/2\right]^2}\to\frac{4\sin^2(\Omega t/2)}{\Omega^2}=\frac{2}{\Omega^2}\Big(1-\cos(\Omega t)\Big)$$

$$I=\iint\limits_{[0,t]^2}dt_1\,dt_2\,e^{-|t_1-t_2|/\tau}e^{i\Omega(t_1-t_2)}$$ notice that: $$|t_1-t_2|=\begin{cases}(t_1-t_2)&t_1>t_2\\0&t_1=t_2\\-(t_1-t_2)&t_1 so we could split it into two parts to make it easier: $$0\le t_1\le t,0\le t_2\le t_1$$ $$0\le t_2\le t,0\le t_1\le t_2$$ leaving: $$\int\limits_0^tdt_1\int\limits_0^{t_1}dt_2\,e^{-(t_1-t_2)/\tau}e^{i\Omega(t_1-t_2)}+\int\limits_0^tdt_2\int\limits_0^{t_2}dt_1\,e^{(t_1-t_2)/\tau}e^{i\Omega(t_1-t_2)}\\ =\frac{{\tau}\mathrm{e}^{-\frac{t}{{\tau}}}\left(\left(\left(\mathrm{i}{\omega}^3t+{\omega}^2\right){\tau}^3+\left({\omega}^2t-2\mathrm{i}{\omega}\right){\tau}^2+\left(\mathrm{i}{\omega}t-1\right){\tau}+t\right)\mathrm{e}^\frac{t}{{\tau}}+\left(-\mathrm{i}{\omega}^2\sin\left({\omega}t\right)-{\omega}^2\cos\left({\omega}t\right)\right){\tau}^3+\left(2\mathrm{i}{\omega}\cos\left({\omega}t\right)-2{\omega}\sin\left({\omega}t\right)\right){\tau}^2+\left(\mathrm{i}\sin\left({\omega}t\right)+\cos\left({\omega}t\right)\right){\tau}\right)}{\left({\omega}^2{\tau}^2+1\right)^2} -\frac{{\tau}\mathrm{e}^{-\frac{t}{{\tau}}}\left(\left(\left(\mathrm{i}{\omega}^3t-{\omega}^2\right){\tau}^3+\left(-{\omega}^2t-2\mathrm{i}{\omega}\right){\tau}^2+\left(\mathrm{i}{\omega}t+1\right){\tau}-t\right)\mathrm{e}^\frac{t}{{\tau}}+\left({\omega}^2\cos\left({\omega}t\right)-\mathrm{i}{\omega}^2\sin\left({\omega}t\right)\right){\tau}^3+\left(2{\omega}\sin\left({\omega}t\right)+2\mathrm{i}{\omega}\cos\left({\omega}t\right)\right){\tau}^2+\left(\mathrm{i}\sin\left({\omega}t\right)-\cos\left({\omega}t\right)\right){\tau}\right)}{\left({\omega}^2{\tau}^2+1\right)^2}$$ (I swapped the $$\Omega$$ for $$\omega$$ here just for speed). Whilst this result is quite long, it can be simplified and is definately do-able.

• Can you please simplify the result? Sep 24, 2021 at 1:43

After some minor simplification, we have for the antiderivative

$$I=\frac{4\tau}\pi\int \frac{\sin ^2\left(\frac{1}{2} t (\omega +\Omega )\right)}{\left(\tau ^2 \omega ^2+1\right) (\omega +\Omega )^2}\,d\omega$$ Using $$x=\frac{t (\omega +\Omega )}2$$ gives $$\int \frac{\sin ^2\left(\frac{1}{2} t (\omega +\Omega )\right)}{\left(\tau ^2 \omega ^2+1\right) (\omega +\Omega )^2}\,d\omega=\frac {t^3}{8\tau^2}\int \frac{\sin^2(x) }{x^2(x^2+ax+b) }\,dx$$ with $$a=-t \Omega$$ and $$b=\frac{t^2 \left(\tau ^2 \Omega ^2+1\right)}{4 \tau ^2}$$.

Let $$r$$ and $$s$$ be the complex roots of the quadratic and use partial fraction decomposition $$\frac 1{x^2(x-r)(x-s)}=\frac{r+s}{r^2 s^2 x}+\frac{1}{r^2 (r-s) (x-r)}-\frac{1}{s^2 (r-s) (x-s)}+\frac{1}{r s x^2}$$ which make that we face two kinds of integratels $$J=\int \frac{\sin^2(x) }{x^2} \,dx=\text{Si}(2 x)+\frac{\cos (2 x)-1}{2 x}$$

$$K_c=\int \frac{\sin^2(x) }{x-c} \,dx=-\frac{1}{2} (\cos (2 c) \text{Ci}(2 x-2 c)+\sin (2 c) \text{Si}(2 c-2 x)-\log (x-c))$$