I wish to find the function $u(x,t)$ which solves the following PDE:
$$\begin{cases} \partial_{t}u - \Delta u = 0, \; t \in \mathbb{R}_{+}, \; x \in \mathbb{R}^{d} \\ u(0,x) = e^{-x^{2}}, \; x\in \mathbb{R}^{d} \end{cases}$$
After several steps related to applying the Fourier transform I arrive at $$u(x,t) = \frac{1}{(4\pi t)^{\frac{d}{2}}} \int_{\mathbb{R}^{n}} e^{-\frac{|x-y|^2}{4t}}e^{-y^2}dy$$ To evaluate this integral, I know I must
- Complete the square
- Apply Fubini's theorem
- Note that $\int_{-\infty}^{\infty} e^{-x^2}dx = \sqrt{\pi}$
However, after several attempts at doing this I cannot arrive at a function $u$ which satisfies the PDE. My latest attempt yielded: $$u = \frac{e^{\frac{-x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}} e^{\frac{(4t+1)x^2}{4^3 t^3}} \Bigg(\frac{\pi \cdot 4t}{4t+1}\Bigg)^{\frac{d}{2}}$$ which, upon inspecting the boundary condition, results in dividing by zero since $t = 0$ is in the denominator of many terms.
Is my computation of the integral correct? If so, that will mean my error lies elsewhere in my work.
Newest attempt:
\begin{align*} \frac{1}{(4\pi t)^{\frac{d}{2}}}\prod_{j=1}^{d}\int_{-\infty}^{\infty}e^{-\frac{(x_j-y_j)^2}{4t}}e^{-y_j^2}dy_j &= \frac{1}{(4\pi t)^{\frac{d}{2}}}\prod_{j=1}^{d}\int_{-\infty}^{\infty}e^{\frac{-x_j^2 +2x_j y_j -y_j^2}{4t}}e^{-y_j^2}dy_j \\ &= \frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\prod_{j=1}^{d}\int_{-\infty}^{\infty}e^{\frac{2x_j y_j -y_j^2}{4t}}e^{-y_j^2}dy_j \\ &=\frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\prod_{j=1}^{d}\int_{-\infty}^{\infty}e^{-(\frac{1}{4t}+1)y_j^2 + \frac{x_j y_j}{2t}}dy_j \end{align*}
Now complete the square of: $-(\frac{1}{4t}+1)y_j^2 + \frac{x_j y_j}{2t}$.
Factor out the coefficient of the squared term: $-(\frac{1}{4t}+1)\left ( y_j^2 - \frac{x_jy_j}{2t\cdot (\frac{1}{4t}+1)}\right )$
\begin{align*}y_j^2 - \frac{x_jy_j}{2t\cdot (\frac{1}{4t}+1)}&= (y_j -\frac{\frac{x_j}{2t\cdot (\frac{1}{4t}+1)}}{2})^2 - \frac{x_j^2}{t^2(\frac{1}{4t}+1)^{2}}\end{align*}
$-(\frac{1}{4t}+1)\left( (y_j -\frac{\frac{x_j}{2t\cdot (\frac{1}{4t}+1)}}{2})^2 - \frac{x_j^2}{t^2(\frac{1}{4t}+1)^{2}} \right) =\\\boxed{ -(\frac{1}{4t}+1)\left (y_j -\frac{x_j}{t\cdot (\frac{1}{4t}+1)} \right)^2 + \frac{x_j^2}{t^2(\frac{1}{4t}+1)}}$
Now substitute the above into the integrand and manipulate to obtain the gaussian integral.
\begin{align*} \frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\prod_{j=1}^{d}\int_{-\infty}^{\infty}e^{-(\frac{1}{4t}+1)y_j^2 + \frac{x_j y_j}{2t}}dy_j &= \frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\prod_{j=1}^{d}\int_{-\infty}^{\infty}e^{ -(\frac{1}{4t}+1)\left (y_j -\frac{x_j}{t\cdot (\frac{1}{4t}+1)} \right)^2 + \frac{x_j^2}{t^2(\frac{1}{4t}+1)}}dy_j\\ &= \frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\cdot e^{\frac{x^2}{t^2(\frac{1}{4t}+1)}}\prod_{j=1}^{d}\int_{-\infty}^{\infty}e^{ -(\frac{1}{4t}+1)\left (y_j -\frac{x_j}{t\cdot (\frac{1}{4t}+1)} \right)^2}dy_j \end{align*} Let $z = \sqrt{(\frac{1}{4t}+1)}\left (y_j -\frac{x_j}{t\cdot (\frac{1}{4t}+1)} \right) \implies dz = \left (\sqrt{(\frac{1}{4t}+1)} \right ) dy_j $ \begin{align*} &= \frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\cdot e^{\frac{x^2}{t^2(\frac{1}{4t}+1)}}\prod_{j=1}^{d}\frac{1}{\sqrt{(\frac{1}{4t}+1)}}\int_{-\infty}^{\infty}e^{ -z^2}dz \\ &= \frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\cdot e^{\frac{x^2}{t^2(\frac{1}{4t}+1)}}\prod_{j=1}^{d}\frac{1}{\sqrt{(\frac{1}{4t}+1)}}\sqrt{\pi}\\ &= \frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\cdot e^{\frac{x^2}{t^2(\frac{1}{4t}+1)}} \cdot \left (\frac{\pi}{(\frac{1}{4t}+1)} \right)^{\frac{d}{2}}\\ &=\frac{e^{-\frac{x^2}{4t}}}{(4\pi t)^{\frac{d}{2}}}\cdot e^{\frac{x^2}{t^2(\frac{1}{4t}+1)}} \cdot \left (\frac{4\pi t}{4t+1} \right)^{\frac{d}{2}} \\ &=\boxed{ e^{-\frac{x^2}{4t}}\cdot e^{\frac{x^2}{t^2(\frac{1}{4t}+1)}} \cdot \left (\frac{1}{4t+1} \right)^{\frac{d}{2}}} \end{align*}
But again, this seems to be incorrect.
solved: $$u(x,t) = \boxed{\left (\frac{1}{4t+1} \right)^{\frac{d}{2}}e^{-\frac{x^2}{4t+1}}}$$
Everyone take my experience as a caution to check your arithmetic!
Getting the integral right is just be being really careful in all steps. To be sure you have the correct answer you should first check that you get the correct limit as $t\to 0^+$ and if so the best test is to insert it into the PDE and verify that it satisfy it.
There are also other ways you can find the solution to check it. For example from completing the square its easy to see that the solution should be on the form $u(x,t) = a(t)e^{-b(t)x^2}$ where $a(0) = b(0) = 1$ to match the initial condition. Using this as an ansatz the PDE gives us $$(\dot{a} - a\dot{b}x^2)e^{-b(t)x^2} = \sum_i (-2ab + 4ab^2 x_i^2)e^{-b(t)x^2} = (-2abd + 4ab^2 x^2)e^{-b(t)x^2}$$ which gives you the simple ODEs $\dot{b} = -4b^2$ and $\frac{\dot{a}}{a} = -2db$. Solving for $b$ gives $b = \frac{1}{4t+1}$. Then solving for $a$ gives $a = (1+4t)^{-d/2}$ so the solution is $u = (1+4t)^{-d/2}e^{-x^2/(1-4t)}$ which agrees with what you found.
Another way would be to take the Fourier transform of the PDE to find $$\dot{\hat{u}} + k^2\hat{u} = 0\to \hat{u}(k,t) = \hat{u}(k,0)e^{-k^2t}$$ and then take the Fourier transform of the initial condition and finally the inverse transform of $\hat{u}(k,t)$. However in this case this is not any simpler as you will have to evaluate the (complex) Fourier integrals (unless you have some transform tables you can look up the answer from).