I'm trying to solve a simple mass-dashpot-spring system $$m\ddot{u}(t) + c\dot{u}(t) + ku(t) = F(t)$$ by making use of the Fourier transform defined as $$\tilde{f}(s) = \int_{-\infty}^{\infty} f(t) \, \mathrm{e}^{-\mathrm{i} (2 \pi s) t} \mathrm{d}t$$ such that the ODE transforms into $$-(2 \pi s)^2 m \tilde{u}(s) + \mathrm{i} (2 \pi s) c \tilde{u}(s) + k \tilde{u}(s) = \tilde{F}(s)$$ to eventually solve $$\tilde{u}(s) = \frac{\tilde{F}(s)}{-(2 \pi s)^2 m + \mathrm{i} (2 \pi s) c + k}$$ Say I have the forcing $$F(t) = \left\lbrace\matrix{\cos(t) & 0 \leq t < \pi/2 \\ 0 & \text{otherwise}}\right. \quad \rightarrow \quad \tilde{F}(s) = \frac{\mathrm{e}^{-\mathrm{i} \pi^2 s} + \mathrm{i} (2 \pi s)}{1-(2\pi s)^2}$$ accept the initial conditions $$u(0)=0, \; \dot{u}|_{t=0} = 0$$ and have the parameters $$m=1.3, \; c=0.6, \; k=1.7$$ Now, I want to transform it back to the time domain using the discrete Fourier transform. I think the basic idea is to compute solutions $\tilde{u}$ for several values of $s$ like this. If I plot the vector containing the complex valued solutions this results in (red - real, green - imaginary)

Then when using Maple's InverseFourierTransform function on the resulting vector I obtain rubbish:

What am I doing wrong here?