Solution (source code)

= Solution

The <Kullback-Leibler divergence> between the posterior normal distribution and $N(0,\tau^2)$ is
$$
\boxed{
D_{\mathrm{KL}}\{p(\theta\mid y)\Vert\pi\}
=\frac12\left[
\frac{\sigma_\theta^2+\widetilde\theta^2}{\tau^2}
-1+\log\left(\frac{\tau^2}{\sigma_\theta^2}\right)
\right]}.
$$