Q: Posterior mean of a normal likelihood with normal prior with experimental data I have some experimental data and was wondering if my methodology of finding the posterior mean was correct.
I have 55 observations $X_i$ for $i=1,\dots,55$ and I believe $X_i \sim N(\theta,1)$. We assume the prior distribution is given by $\theta \sim N(5,10^2)$.
I know that the posterior distribution for $\theta$ given my observations $\underline{x}$ must be $\theta |\underline{x}\sim N(\mu_1,\sigma_1^2)$.
For the sake of clarity, let me define some notation.
$\mu$ is the mean we are trying to assign a posterior distribution to.
$\sigma^2$ is the variance that goes with $\mu$ from above.
$\mu_0$ is the prior  mean.
$\sigma_0^2$ is the prior variance.
$n=55$ is the number of observations.
$\bar{x}$ is the sample mean.
$\mu_1$ is the posterior mean.
$\sigma_1^2$ is the posterior variance.
Here $\bar{x}=1.811745$.
Now, from research, it seems that we should have $$\mu_1 = (\frac{\mu_0}{\sigma_0^2}+\frac{n\bar{x}}{\sigma^2})/(\frac{1}{\sigma_0^2}+\frac{n}{\sigma^2})$$
$$\sigma_1^2=\frac{1}{\frac{1}{\sigma_0^2}+\frac{n}{\sigma^2}} $$
So $\mu_1$ should be equal to about $1.8123$ and $\sigma_1^2$ should equal $0.0181785$. So $\theta |\underline{x}\sim N(1.8123,0.0181785)$. Is this correct?
