Calculating $\int^{\infty}_{0}\frac{e^{-y}sin^2(y)}{y}dy$ Ihave this exercise that I found in past midterms archives. It goes like this:

Show that the function $f(x,y)=e^{-y}sin(2xy)$ is integrable on $[0,1]×[0,\infty)$. Then deduce the value of  $\int^{\infty}_{0}\frac{e^{-y}sin^2(y)}{y}dy$

Showing that $f$ is integrable wasn't difficult, mainly I only needed to show that $e^{-y}$ is integrable on $[0,\infty)$. But I don't see how the first function can help to solve the integral. 
 A: Fubini's theorem applies:
$$ \int_{0}^{+\infty}\frac{e^{-y}\sin^2 y}{y}\,dy = \int_{0}^{+\infty}\int_{0}^{1}e^{-y}\sin(2xy)\,dx\, dy = \int_{0}^{1}\frac{2x}{1+4x^2}\,dx = \left[\frac{1}{4}\log(1+4x^2)\right]_{0}^{1}=\color{red}{\frac{\log 5}{4}}.$$
A: Just for the sake of curiosity, let me give thee another way to calculate the integral. It's called differentiate under the integral sign method. 
I think everyone shall practice with this method, it can be a very powerful tool.
Suppose thy integral has another parameter $a$ on it:
$$I(a) = \int_0^{+\infty} e^{-ay}\frac{\sin^2(y)}{y}\ dy$$
You immediately see that for $a = 1$ we recognise your integral.
Now take the derivative with respect upon $a$:
$$I'(a) = -\int_0^{+\infty} e^{-ay}\sin^2(y)\ dy$$
Which is an easy integral to evaluate
$$I'(a) = -\frac{2}{4a + a^3}$$
Form this, let's calculate $I(a)$ by integrating in $a$, another easy calculation that yields
$$I(a) = -\int \frac{2}{4a + a^3}\ da = -2\left(\frac{\ln(1)}{4} - \frac{1}{8}\ln(4 + a^2)\right)$$
Since thy integral could be obtained by $I(1)$, here it is:
$$I(1) = \color{red}{\frac{\ln(5)}{4}}$$
