= Solution
Use the <Bayes' theorem> to multiply the <Ising model> prior by the conditionally independent normal likelihood factors. For fixed observed $x$, the <posterior distribution> is
$$
\boxed{\pi(s\mid x)\propto
\exp\!\left[-J\sum_{\{i,j\}\in\mathcal N}s_is_j
-\frac12\sum_{k\in D}\left\{x_k-\left(\sum_{j\in\mathcal N_k}s_j\right)^7\right\}^2\right],\qquad s\in\{-1,1\}^D.}
$$
There is no boundary wraparound: the neighbor sets use only actual horizontal and vertical edges inside the square. Each unordered edge is counted once. In particular, the prior retains the printed minus sign in front of $J$, and the likelihood retains the seventh power. The finite state space and finite observed values make every posterior weight positive and finite, with a finite positive normalizing sum.
Back to article page