I need to solve this gaussian integral: $$\int_\mathbb{R} (2\pi)^{-n/2}\mid \Sigma\mid ^{-\frac{1}{2}}e^{-\frac{1}{2}(u-Kx)^T\Sigma ^{-1}(u-Kx)} u^TRu \,\mathrm du$$ It is the integral of a multivariate guassian with mean $Kx$ and variance $\Sigma$. $R$ is a constant. $R$ and $K$ are symmetric of size $n$. $u$ is a column vector of size $n$.

I am reading a paper and I have to demonstrate an equation, but it is the first time I encounter multivariate gaussian integral.

Any help is appreciated, thanks.


This is what I have done so far:
Substitute $v=(u-Kx)$: $$ (2\pi)^{-\frac{n}{2}}\mid \Sigma\mid ^{-\frac{1}{2}}\int_\mathbb{U} e^{-\frac{1}{2}v^T\Sigma ^{-1}v} (v+Kx)^TR(v+Kx) d\text{u} $$ Split the integral and solve the parts one by one (notice that $x^TKRv = (Kx)^T(v^TR)^T=v^TRKx$): $$ \int_\mathbb{R} e^{-\frac{1}{2}v^T\Sigma ^{-1}v} v^TRv d\text{u}=? $$ $$ \int_\mathbb{R} e^{-\frac{1}{2}v^T\Sigma ^{-1}v} v^TRKx d\text{u}=\int_\mathbb{R} e^{-\frac{1}{2}v^T\Sigma ^{-1}v} x^TKRv d\text{u} $$ $$ =-e^{-\frac{1}{2}v^T\Sigma ^{-1}v} \Sigma RKx \mid_{-\infty}^\infty=? $$ $$ \int_\mathbb{R} e^{-\frac{1}{2}v^T\Sigma ^{-1}v} x^TKRKx d\text{u}=((2\pi)^n \mid \Sigma \mid)^{\frac{1}{2}}x^TKRKx $$

I have no idea how to solve the first.
About the second, I think it should be $0$ (seeing the final result that I have to prove) but I don't know why.


The integral is equivalent with calculating the expectation: $$ \mathbb{E}[u^TRu], $$ where $u \sim \mathcal{N}(Kx,\Sigma)$. From matrix cookbook 1, eq. (296) you have: $$ \mathbb{E}[u^TRu] = \mathrm{Tr}(R\Sigma) + x^TK^TRKx. $$


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.