According to the PDF at this link (eqn 12), the following is true: $$\text{erf}(x)=\frac{1}{\pi}\int_0^\infty e^{-t} \sin(2x\sqrt{t})\frac{dt}{t} $$
I would like to use this identity as part of a presentation to my students (the integral can be derived in an intuitive way for a heat diffusion problem). If need be I can simply assert "and this is known to be equivalent to the error function" but I'd rather prove it for them. However since the group are not mathematicians I would need to be able to show it using elementary methods; for example integration by parts is fine, but contour integration is not.
I have tried and failed to show the equivalence. Any suggestions welcome.
By the substitution $\sqrt{t}\rightarrow \pi u$, we get \begin{align} 2\frac{1}{\pi}\int^\infty_0 e^{-\pi^2u^2}\frac{\sin(2\pi x u)}{u}\ du = \int^\infty_{-\infty} e^{-\pi^2u^2}\frac{\sin(2\pi x u)}{\pi u}\ du. \end{align}
Apply Plancherel's theorem, which states \begin{align} \int^\infty_{-\infty} f(x)\overline{g(x)}\ dx = \int^\infty_{-\infty} \hat f(\xi)\overline{\hat g(\xi)}\ d\xi, \end{align} then it follows \begin{align} \int^\infty_{-\infty} e^{-\pi^2u^2}\frac{\sin(2\pi x u)}{\pi u}\ du=&\ \frac{1}{\sqrt{\pi}}\int^\infty_{-\infty} e^{-t^2}\chi_{[-x, x]}(t)\ dt = \frac{2}{\sqrt{\pi}} \int^x_0 e^{-t^2}\ dt =\operatorname{erf}(x). \end{align}
I will leave it as an exercise for the reader to check
Hint: Complete the square. Formally ignored the complex number in the square and perform a $u$-substitution.