# With respect to the dirac delta function, what does $\delta [x + 2A, y - A]$

I have come across the following function and I'm trying to figure out what it really is. I have this function:

$f[x, y] = \delta [x + 2A, y - A] - \delta [x - A, y + A]$. The $\delta$ is representative of the dirac delta function. This function is used as input to some finite impulse response filter.

What does this function really mean? Is the first part of the function 0 everywhere except $-2A, A$ and the second part 0 everywhere except $A, -A$ ?

• In an image represented as pixels in two dimensions, say as samples on a rectangular grid, this would be a positive impulse at $(-2A,A)$ and a negative impulse at $(A,-A)$. If your filter had impulse response $g(x,y)$, it would produce $g(x+2A,y-A)-g(x-A,y+A)$ when the input was $f(x,y)$. – Dilip Sarwate Feb 19 '12 at 22:41
• @DilipSarwate Thanks for the comment. Would it really be those 2 separate calls to the impulse response? It is two separate dirac delta functions, but they are one function f(x,y). Having trouble understanding why that would be – Steve Feb 20 '12 at 0:04
• It's a bit of an under-abstracted (and IMO not particularly good) notation you use there. In physics, we would write it like this: "$f(\mathbf{r}) = \delta(\mathbf{r}-\mathbf{r}'_1) - \delta(\mathbf{r}-\mathbf{r}'_2)$ with $\mathbf{r}'_1=(-2A,A),\mathbf{r}'_1=(A,-A)_{\mathbf{e}_x,\mathbf{e}_y}$" which I consider to make it much clearer that you're right with what's going on. – leftaroundabout Feb 20 '12 at 0:07

A (two-dimensional) finite-impulse-response filter has an impulse response $g(x,y)$ that is nonzero only for $(x,y)$ in a region of finite area (continuous parameters) of for a finite number of values of $x$ and $y$ (discrete parameter). For example, $g(x,y)$ might be nonzero only for points inside a circle of radius $r$. Specifically, consider $$g(x,y) = \begin{cases}1, &x^2 + y^2 \leq r^2,\\0, &\text{otherwise}\end{cases}$$ describes an image filter whose response to a point source (impulse function) at the origin is a disc of radius $r$ in the filtered image. For input $f(x,y) = \delta (x + 2A, y - A) - \delta (x - A, y + A)$, the filter output would be the sum of a positive disc centered at $(-2A,A)$ and a negative disc centered at $(A,-A)$ with cancellation occurring where the discs overlapped. (Disc ovrlap would be determined by the relationship between $A$ and $r$). More formally, $$g(x,y)\circledast f(x,y) = \begin{cases} 1, &(x+2A)^2 + (y-A)^2 \leq r^2, (x-A)^2+(y+A)^2 > r^2,\\ -1, &(x+2A)^2 + (y-A)^2 > r^2, (x-A)^2+(y+A)^2 \leq r^2,\\ 0, &\text{otherwise.}\end{cases}$$ where we have combined the outer darkness of $0$ with the $0$ produced by the cancellation of the discs in the region of overlap (if any).

Similar calculations can be done for the discrete case as well.

First i am showing how a 1D function $f(x) = \delta[x+2A] - \delta[x-A]$ looks like.  • In the 1D case, $\delta(x+2A)$ is a (positive-valued) impulse at $x = -2A$, not at $x = +2A$ the way you have it. Similarly, $-\delta(x-A)$ is a (negative-valued) impulse at $x= A$, not at $x=-A$ the way you have it. This basic mis-interpretation carries over into the 2D case as well. I am unable to understand your clarification as to what you mean by filtering. What does "the matrix to be operated on image will look like +1 & -1 in those places except those points." mean? – Dilip Sarwate Feb 22 '12 at 20:41