Show that solution to wave equation can be used to solve the Heat equation Let $u$ be a regular and bounded solution of $u_{tt}-u_{xx}=0$ in $\mathbb{R} \times \mathbb{R}$ with $u(0,x) = g(x)$, $u_t(0,x)=0$ in $\mathbb{R}$. Define
$$
w(t,x) = \frac{1}{\sqrt{4 \pi t}} \int_{\mathbb{R}} u(s,x)e^{-\frac{s^2}{4t}}ds
$$
Show that $w$ solves the heat equation $w_t - w_{xx} = 0$ in $(0,\infty) \times \mathbb{R}$ with $w(0,x) = g(x)$ in $\mathbb{R}$.
So far I have tried this: The solution to the wave equation $u_{tt} - u_{xx}=0$ must be of the form found in d'Alembert's formula. So i plugged this formula into $w$ and then calculated $w_t$ and $w_{xx}$. But I don't see any obvious simplifications that lead to the result.

Notice that
$$w(t,x)=\int_\mathbb R u(s,x) K(t,s) ds$$
where $K$ is the heat kernel which we know satisfies $(\partial_t + \Delta)K=0$ (where I use the Laplacian with a negative sign).
Now when you compute $(\partial_t+\Delta)w$, using your favorite theorem to justify the interchange of differentiation and integration, you can bring $(\partial_t+\Delta)$ inside the integral. Then, the time derivative will only interact with the heat kernel $K$ and the Laplacian will only act on $u$. With the information we have about $u$ and $K$, we arrive at an integral appearing in Green's second identity (by which I mean an integral of the form $\int (f\Delta g - g\Delta f) ds$) and thus show $(\partial_t+\Delta)w=0$.
