2D convolution: how to eyeball it?

91 Views Asked by At

I have a question of doing simple convolution in 2d by just "eye-balling" it without doing the actual computation.

In 1D discrete time, when we have a simple input $x(n)=2*\delta(n)+\delta(n-1)+\delta(n-2)$, and that the system impulse response is $h(n)=\delta(n)+\delta(n-1)$, then we dont really need to do the convolution that "formally" (meaning, you flip it, then you shift by 1, and then shift by 2...... and so on), you can just say that, for the first term in $x(n)$, you will see $2*(\delta(n)+\delta(n-1))$, and for the second term in $x(n)$, you see a delay version of $h(n)$...... and you just add them up.

My question is, can you do the similar things in 2D case, in which you don't "really" need to do the convolution (flip it twice, then shift, .....). Can you "eye-ball" it?

For instance

\begin{matrix} 0 & 1 & 0 \\ 0 & 0 & 0 \\ 0 & -1 & 0 \end{matrix}

convolute with

\begin{matrix} 0 & 0 & 0 \\ -2 & -2 & -2 \\ 0 & 0 & 0 \end{matrix}

How do you quickly tell the result without doing the actual "convolution"?