Check of Laplace transform This afternoon I solved a ODE with a Laplace transform. Now I want to check if the solution whether it is correct, but I cannot get to the solution.
The ODE is:
$$\ddot{x} +4x = f(t), x(t=0)=3, \dot{x}(t=0)=-1$$
As a solution I found:$$ {x(t) =3\cos(2t)-\frac 12\sin(2t)+  \frac 12\int_0^t f(\tau) \, \sin(2(t-\tau))d\tau}$$
The problem is: How do I check the last part (under the integral?
 A: First, given $\ddot{x}+4x=f$ with $\dot{x}(0)=-1$ and $x(0)=3$, we find that  
$$\mathscr{L}\{\ddot{x}\}=s^2\mathscr{L}\{x\}-3s+1 \tag1$$
Hence, we have
$$\mathscr{L}\{x\}=\underbrace{\frac{3s}{(s^2+4)}}_{\text{Laplace Transform of}\,\,3\cos(2t)}-\underbrace{\frac{1}{(s^2+4)}}_{\text{Laplace Transform of}\,\,\frac12\sin(2t)} +\underbrace{\frac{\mathscr{L}\{f\}}{(s^2+4)}}_{\text{Laplace Transform of}\,\,f(t)*\frac12\sin(2t)}$$
Inverting, we have
$$\begin{align}
x(t)&=3\cos(2t)-\frac12 \sin(2t) +\left(f(t)*\frac12\sin(2t)\right)\\\\
&=3\cos(2t)-\frac12 \sin(2t) +\frac12 \int_{-\infty}^\infty f(\tau)u(\tau)\sin(2(t-\tau))u(t-\tau)\,d\tau\\\\
&=3\cos(2t)-\frac12 \sin(2t) +\frac12 \int_{0}^t f(\tau)\sin(2(t-\tau))\,d\tau\tag2
\end{align}$$
as was to be shown!



We now verify that $(2)$ is the solution to the ODE of interest.

Differentiating $(2)$ using Leibniz's Rule, we find that 
$$\begin{align}
\dot{x}(t)&=-2(3\sin(2t))+2\left(-\frac12 \cos(2t)\right)+\frac12 f(t)\sin(2(t-t))+\frac12 \int_0^t f(\tau) 2\cos(2(t-\tau))\,d\tau\\\\
&=-2(3\sin(2t))+2\left(-\frac12 \cos(2t)\right)+ \int_0^t f(\tau) \cos(2(t-\tau))\,d\tau \tag3
\end{align}$$
Differentiating $(3)$ again using Leibniz's Rule, we find that 
$$\begin{align}
\ddot{x}(t)&=-4(3\cos(2t))-4\left(-\frac12 \sin(2t)\right)+f(t)\cos(2(t-t))-4\,\frac12 \int_0^t f(\tau)\sin(2(t-\tau))\,d\tau\\\\
&=-4x(t)+f(t)
\end{align}$$
And we are done!
