0

Let $f: \mathbb R^n \rightarrow \mathbb R$ be a multivariate Gaussian and $g: \mathbb R^n \rightarrow \mathbb R$ a multivariate dirac-function, namely with $i,j,m,n\in\mathbb N,m<n$ and $x=(x_1,\ldots,x_n)$ and $a,b\in\mathbb R$:

\begin{align} & f(x)= \frac {1}{\sqrt {(2\pi )^k|{\boldsymbol {\Sigma }}|}} \cdot \exp \left(-{\frac {1}{2}}({\mathbf {x} }-{\boldsymbol {\mu }})^{\mathrm {T} }{\boldsymbol {\Sigma }}^{-1}({\mathbf {x} }-{\boldsymbol {\mu }})\right) \\[10pt] & g(x) = \begin{cases} \lim\limits_{a\rightarrow0,\ b\rightarrow\infty} \quad \dfrac{1}{a^m\cdot b^{n-m}} & |x_i|\le\frac a2,1\le i\le m,\quad |x_j|\le\frac b2,m<j\le n \\[6pt] \quad 0 & \text{otherwise.} \end{cases} \end{align}

So bascially $g$ is a boxcar function where I have some of the borders shrink in some other expand, so that I get sort of a tube in 2D. If I have not done any mistakes the volume of $g$ should be $1.$ Let us further assume, the simplification that $\Sigma$ is a multiple of the identify matrix.

I would like to convolve these two to $h(x) = (f ∗ g)(x)$. If we would have a regular dirac function with $\lim\limits_{a\rightarrow0,\ b\rightarrow0}$, then the result would be the $h(x)=f(x)$, however in my case this is not the case. Here, we get for the partially evaluated function

$$ h(x\mid\ x_i=c_i, m<i) = \text{constant} $$

where all $c_i\in\mathbb R$. Now, my question: Is

$$ h(x\mid\ x_i=c_i, i\le m) \overset?\propto \exp \left(-{\frac {1}{2}}({\mathbf {x} }-{\boldsymbol {\mu }})^{\mathrm {T} }{\boldsymbol {\Sigma^\star }}^{-1}({\mathbf {x} }-{\boldsymbol {\mu }})\right) $$

a multivariate Gaussian (of dimension $m$)? How would $\Sigma^\star$ would be scaled compared to $\Sigma$?

Make42
  • 1,085
  • You can write $g$ directly as $g(x) =\prod_{i=1}^m \delta(x_i)$. Hopefully now the convolution becomes more transparent. – user619894 Aug 31 '20 at 16:08
  • The Fourier transform changes convolution to pointwise multiplication: $\widehat{f*g} = \widehat f \cdot\widehat {g,}.$ And the Fourier transform of a Gaussian function is a Gaussian function. Multiply the two Fourier transforms and see what you get. $\qquad$ – Michael Hardy Aug 31 '20 at 16:15
  • @user619894: It is not obvious to me, why I can write $g$ as you suggest, can you elaborate? – Make42 Aug 31 '20 at 22:48
  • @MichaelHardy: Thank you for giving me those tips, but it does not get me all the way to the solution: The Fourier transform of the dirac delta function is 1, so in the spectrum, $1\cdot Gaussian$ is a Gaussian and getting it back to "normal", we have a Gaussian. But I knew that already (see my question), so I am not yet sure how this translates to me question. What is the Fourier transform of $g$? – Make42 Aug 31 '20 at 22:58
  • I think that your definition of the "anti" delta in the $g$ shouldn't be normalized, since integrating over the $|x|<b/2$ with a $L_2$ test function, as it stands, will always give zero. – user619894 Sep 02 '20 at 07:17
  • @user619894: I am not sure what you mean: I thought that $1 / (a^m \cdot a^{n-m})$ is already doing the normalization. Can you write the formula in an answer, or edit my post that I can see what you mean? – Make42 Sep 02 '20 at 09:42
  • Consider the one dimensional case: $m=0,n=1$ case $g={1\over b}{\bf 1}(|x|<b/2)$ ( $\bf 1$ is the indicator function), integrating over a test function $p(x)$ would yield ${1\over b} \int_{-b/2}^{b/2} p(x)dx$ . If $\int_{-b/2}^{b/2} p(x)dx$ is bounded for large $b$, this will vanish in the large $b$ limit. Specifically for a Gaussian, as your example, this integral will vanish. – user619894 Sep 02 '20 at 10:04
  • @user619894: Are you using $p$ as an alternative to $f$ as in $(f*g)(x)\triangleq\ \int {-\infty}^{\infty}f(x-\xi)g(\xi),d\xi = \frac1b\int _{-b/2}^{b/2}f(x-\xi),d\xi$? Do you mean because $\lim{b\rightarrow\infty}\int _{-b/2}^{b/2}f(\xi),d\xi=1$ for a Gaussian that the factor $1/b$ makes it $0$? If so - what do you suggest to correct this? – Make42 Sep 02 '20 at 10:39
  • Precisely. I suggest not to divide by $b$ – user619894 Sep 02 '20 at 10:41
  • @user619894: But I would still divide by $a^m$? Either way: Does that not make $\int_{-\infty}^{\infty}g(x)dx = \infty$ or is that no issue? – Make42 Sep 02 '20 at 10:44

2 Answers2

1

EDIT: I simplified the notation a bit to make the answer clearer.

I assume your limiting function $g$ should actually be $\prod_{i=1}^m \delta(x_i)$ ( the normalization by $1\over b$ will cause the entire convolution to vanish, so I treat it as a confusion). In that case, the convolution $$ \int _{-\infty}^{\infty}f(x-\xi)g(\xi)\,d\xi $$ becomes $$ {1\over{\sqrt {(2\pi )^k|{\boldsymbol {\Sigma }}|}}} \int _{-\infty}^{\infty} \exp \left(-{\frac {1}{2}}({\mathbf {\xi} }-{\boldsymbol {\mu }})^{\mathrm {T} }{\boldsymbol {\Sigma }}^{-1}({\mathbf {\xi} }-{\boldsymbol {\mu }})\right) \prod_{i=1}^m \delta(x_i-\xi_i)\prod_{j=1}^{m} d\xi_j\prod_{k=m+1}^{n} d\xi_k $$

At this point some simplification can be made by noticing that the $\xi$ are integration variables, and we can "swallow" the $\mu$ into them, integrating over $\xi-\mu$ instead. This leaves us with $$ {1\over{\sqrt {(2\pi )^k|{\boldsymbol {\Sigma }}|}}} \int _{-\infty}^{\infty} \exp \left(-{\frac {1}{2}}({\mathbf {\xi} })^{\mathrm {T} }{\boldsymbol {\Sigma }}^{-1}({\mathbf {\xi} })\right) \prod_{i=1}^m \delta(x_i-\xi_i-\mu_i)\prod_{j=1}^{m} d\xi_j\prod_{k=m+1}^{n} d\xi_k $$

if we split the inverse covariance $\Sigma^{-1} $ into 4 parts: $\Sigma^{-1}_{<<};\Sigma^{-1}_{>>};\Sigma^{-1}_{><};\Sigma^{-1}_{<>}$ where the subscripts determine whether the indices are $i\le m;i>m$ respectively, we see that the expression in the exponent can be split into $$({\mathbf {\xi} })^{\mathrm {T} }{\boldsymbol {\Sigma }}^{-1}({\mathbf {\xi} }) = ({\mathbf {\xi}_{<} })^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{<<} ({\mathbf {\xi}_{<} })+ ({\mathbf {\xi}_{>} })^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{>>} ({\mathbf {\xi}_{>} })+ 2({\mathbf {\xi_{<}} })^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{<>} ({\mathbf {\xi}_{>} })$$

The $\delta$'s enforce $\xi=x-\mu$ on the $_<$ indices, turning the expression in the exponent to $$ ({\mathbf {x}_{<} }-{\boldsymbol {\mu }_{<}})^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{<<} ({\mathbf {x}_{<} }-{\boldsymbol {\mu }}_{<})+ ({\mathbf {\xi}_{>} })^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{>>} ({\mathbf {\xi}_{>} })+ 2({\mathbf {x_{<}} }-{\boldsymbol {\mu }_{<}})^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{<>} ({\mathbf {\xi}_{>} }) $$ and we are left with an integral over the $\xi_>$ terms: $$ {1\over{\sqrt {(2\pi )^k|{\boldsymbol {\Sigma }}|}}} \left(\exp(-{1\over2}({\mathbf {x}_{<} }-{\boldsymbol {\mu }_{<}})^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{<<} ({\mathbf {x}_{<} }-{\boldsymbol {\mu }}_{<}) \right)\int \prod d{\xi}_> \exp\left(-{1\over2} \left(({\mathbf {\xi}_{>} })^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{>>} ({\mathbf {\xi}_{>} })+ 2({\mathbf {x_{<}} }-{\boldsymbol {\mu }_{<}})^{\mathrm {T} } {\boldsymbol {\Sigma }}^{-1}_{<>} ({\mathbf {\xi}_{>} }) \right)\right) $$

which can be calculated by completing the square.

user619894
  • 3,838
  • Ok, there is quite a bit for me to unpack: 1) It is not obvious to me, why $\prod_{i=1}^m \delta(x_i)$ satisfies my needs: Let $n=3,m=2$, then the value for $i=3$ is irrelevant, and $\delta(x_1\neq0)=0$, $\delta(x_1=0)=\infty$, $\delta(x_2\neq0)=0$ and $\delta(x_2=0)=\infty$ (I know, a lot of abuse of notation). But why would $\delta(x_1=0)\cdot\delta(x_2=0)$ have surface of 1 under the integral and why would $0\cdot\delta(x_2=0) =0$? – Make42 Sep 02 '20 at 13:57
  • In your first large formula: Why are there two $d\xi_{...}$, but only one integral symbol? Did you mean something like $\iint_{-\infty}^{\infty}$? The second one is $d\xi_{k}$, but I don't really see a $k$ within the integral? What am I missing?
  • – Make42 Sep 02 '20 at 13:58
  • 1
  • Am beginning to grasp what you wrote, but what do you mean with "completing the square"? In your last formula, is everything including and after the $\int$ a single real number? Is it 1 (which would make the integral under the entire last formula 1, as with a regular Gaussian)?
  • – Make42 Sep 02 '20 at 14:19
  • Regarding the delta functions, each one has area 1 for the single coordinate it describes. To understand what a delta function does you have to examine how it acts when you integrate it with a test function. So don't try to interpret $\delta(0)\delta(0)$ directly, rather think about the double integral $\int\int dx_1dx_2 f(x_1,x_2)\delta(x_1)\delta(x_2)$ – user619894 Sep 02 '20 at 15:55
  • Regarding the single integral, you are correct, I was trying to lighten the notation, sorry for the confusion. – user619894 Sep 02 '20 at 15:56
  • Regarding completing the square, you can google completing the square gaussian for some detailed explanations. – user619894 Sep 02 '20 at 16:00
  • also, there was a typo , that is why the k was missing. I corrected – user619894 Sep 02 '20 at 16:03
  • There are more typos, but since I got negative feedback, when I corrected them last time at a different question, I will just point them out: In the last formula after the $\frac12$ there should be a $($ and then later the corresponding $)$ is required too, of course. Also, you are using k twice in the second large formula: Once as a running variables, once as the dimension. – Make42 Sep 03 '20 at 10:59
  • I completed the square for the Gaussian (please see my answer), but what do I do now? It is not obvious to me what - once I plugin this back into the integral - the result is (especially whether it is a Gaussian). – Make42 Sep 03 '20 at 11:07
  • How does "The 's enforce =− on the < indices," happen? – Make42 Nov 29 '20 at 22:17
  • Also: I think I was meaning of a Dirac delta and the epsilon from https://math.stackexchange.com/questions/3927949/opposite-of-delta-delta-distribution – Make42 Nov 29 '20 at 22:17
  • @Make42 Integrating a test function $\int f(\xi)\delta(x-\xi-\mu)d\xi=f(x-\mu)$ so whenever we have such an integral we can replace $\xi$ with $x-\mu$. – user619894 Nov 30 '20 at 07:56