Isserlis' theorem

In probability theory, Isserlis' theorem or Wick's probability theorem is a formula that allows one to compute higher-order moments of the multivariate normal distribution in terms of its covariance matrix. It is named after Leon Isserlis.

This theorem is also particularly important in particle physics, where it is known as Wick's theorem after the work of. Other applications include the analysis of portfolio returns, quantum field theory and generation of colored noise.

Statement
If $$(X_1,\dots, X_{n})$$ is a zero-mean multivariate normal random vector, then$$\operatorname{E} [\,X_1 X_2\cdots X_{n}\,] = \sum_{p\in P_n^2}\prod_{\{i,j\}\in p} \operatorname{E}[\,X_i X_j\,] = \sum_{p\in P_n^2}\prod_{\{i,j\}\in p} \operatorname{Cov}(\,X_i, X_j\,), $$where the sum is over all the pairings of $$\{1,\ldots,n\}$$, i.e. all distinct ways of partitioning $$\{1,\ldots,n\}$$ into pairs $$\{i,j\}$$, and the product is over the pairs contained in $$p$$.

More generally, if $$(Z_1,\dots, Z_{n})$$ is a zero-mean complex-valued multivariate normal random vector, then the formula still holds.

The expression on the right-hand side is also known as the hafnian of the covariance matrix of $$(X_1,\dots, X_{n})$$.

Odd case
If $$n=2m+1$$ is odd, there does not exist any pairing of $$\{1,\ldots,2m+1\}$$. Under this hypothesis, Isserlis' theorem implies that$$\operatorname{E}[\,X_1 X_2\cdots X_{2m+1}\,] = 0.$$ This also follows from the fact that $$-X=(-X_1,\dots,-X_n)$$ has the same distribution as $$X$$, which implies that $$\operatorname{E}[\,X_1 \cdots X_{2m+1}\,]=\operatorname{E}[\,(-X_1) \cdots (-X_{2m+1})\,]=-\operatorname{E}[\,X_1 \cdots X_{2m+1}\,] = 0$$.

Even case
In his original paper, Leon Isserlis proves this theorem by mathematical induction, generalizing the formula for the $$4^{\text{th}}$$ order moments, which takes the appearance

\operatorname{E}[\,X_1 X_2 X_3 X_4\,] = \operatorname{E}[X_1X_2]\,\operatorname{E}[X_3X_4] + \operatorname{E}[X_1X_3]\,\operatorname{E}[X_2X_4] + \operatorname{E}[X_1X_4]\,\operatorname{E}[X_2X_3]. $$ If $$n=2m$$ is even, there exist $$(2m)!/(2^{m}m!) = (2m-1)!!$$ (see double factorial) pair partitions of $$\{1,\ldots,2m\}$$: this yields $$(2m)!/(2^{m}m!) = (2m-1)!!$$ terms in the sum. For example, for $$4^{\text{th}}$$ order moments (i.e. $$4$$ random variables) there are three terms. For $$6^{\text{th}}$$-order moments there are $$3\times 5=15$$ terms, and for $$8^{\text{th}}$$-order moments there are $$3\times5\times7 = 105$$ terms.

Example
We can evaluate the characteristic function of gaussians by the Isserlis theorem:$$E[e^{-iX}] = \sum_k \frac{(-i)^k}{k!} E[X^k] = \sum_k \frac{(-i)^{2k}}{(2k)!} E[X^{2k}] = \sum_k \frac{(-i)^{2k}}{(2k)!} \frac{(2k)!}{k!2^k} E[X^{2}]^k = e^{-\frac 12 E[X^2]}$$

Proof
Since the formula is linear on both sides, if we can prove the real case, we get the complex case for free.

Let $$\Sigma_{ij} = \operatorname{Cov}(X_i, X_j)$$ be the covariance matrix, so that we have the zero-mean multivariate normal random vector $$(X_1, ..., X_n) \sim N(0, \Sigma)$$. Since both sides of the formula are continuous with respect to $$\Sigma$$, it suffices to prove the case when $$\Sigma$$ is invertible.

Using quadratic factorization $$-x^T\Sigma^{-1}x/2 + v^Tx - v^T\Sigma v/2 = -(x-\Sigma v)^T\Sigma^{-1}(x-\Sigma v)/2$$, we get

$$\frac{1}{\sqrt{(2\pi)^n\det\Sigma}}\int e^{-x^T\Sigma^{-1}x/2 + v^Tx} dx = e^{v^T\Sigma v/2}$$

Differentiate under the integral sign with $$\partial_{v_1, ..., v_n}|_{v_1, ..., v_n=0}$$ to obtain

$$E[X_1\cdots X_n] = \partial_{v_1, ..., v_n}|_{v_1, ..., v_n=0}e^{v^T\Sigma v/2}$$.

That is, we need only find the coefficient of term $$v_1\cdots v_n$$ in the Taylor expansion of $$e^{v^T\Sigma v/2}$$.

If $$n$$ is odd, this is zero. So let $$n = 2m$$, then we need only find the coefficient of term $$v_1\cdots v_n$$ in the polynomial $$\frac{1}{m!}(v^T\Sigma v/2)^m$$.

Expand the polynomial and count, we obtain the formula. $$\square$$

Gaussian integration by parts
An equivalent formulation of the Wick's probability formula is the Gaussian integration by parts. If $$(X_1,\dots X_{n})$$ is a zero-mean multivariate normal random vector, then

$$\operatorname{E}(X_1 f(X_1,\ldots,X_n))=\sum_{i=1}^{n} \operatorname{Cov}(X_1, X_i)\operatorname{E}(\partial_{X_i}f(X_1,\ldots,X_n)).$$This is a generalization of Stein's lemma.

The Wick's probability formula can be recovered by induction, considering the function $$f:\mathbb{R}^n\to\mathbb{R}$$ defined by $$f(x_1,\ldots,x_n)=x_2\ldots x_n$$. Among other things, this formulation is important in Liouville conformal field theory to obtain conformal Ward identities, BPZ equations and to prove the Fyodorov-Bouchaud formula.

Non-Gaussian random variables
For non-Gaussian random variables, the moment-cumulants formula replaces the Wick's probability formula. If $$(X_1,\dots X_{n})$$ is a vector of random variables, then $$\operatorname{E}(X_1 \ldots X_n)=\sum_{p\in P_n} \prod_{b\in p} \kappa\big((X_i)_{i\in b}\big),$$where the sum is over all the partitions of $$\{1,\ldots,n\}$$, the product is over the blocks of $$p$$ and $$\kappa\big((X_i)_{i\in b}\big)$$ is the joint cumulant of $$(X_i)_{i\in b}$$.