  Given a system of linear equations $\ell_i(x)=\beta_i$ in an $n$-vector $x$
of 0-1 variables, we compute the expectation of $\exp\left\{- \sum_i \gamma_i
\left(\ell_i(x) - \beta_i\right)^2\right\}$, where $x$ is a vector of
independent Bernoulli random variables and $\gamma_i >0$ are constants. The
algorithm runs in quasi-polynomial $n^{O(\ln n)}$ time under some sparseness
condition on the matrix of the system. The result is based on the absence of
the zeros of the analytic continuation of the expectation for complex
probabilities, which can also be interpreted as the absence of a phase
transition in the Ising model with a sufficiently strong external field. As an
example, we consider the problem of "smoothed counting" of perfect matchings in
hypergraphs.
