Green's function method for Helmholtz equation with an obstacle Suppose I wish to solve the 2D inhomogeneous Helmholtz equation 
$$ (-\nabla^2 +k^2)\psi(\vec{r})=-V(\vec{r})\psi(\vec{r})$$
for a potential $V(\vec{r})$ which corresponds to an impenetrable obstacle, i.e. $V(\vec{r})=\infty$ inside some domain in the plane and $V(\vec{r})=0$ outside it (this corresponds to stationary scattering of waves by the obstacle).
I think the Green function method leads to the identity
$$ \psi(\vec{r})=\psi_0(\vec{r})-\int_{\mathbb{R}^2} G(\vec{r},\vec{q}) V(\vec{q})\psi(\vec{q})d^2q,$$
where 
$$ (-\nabla^2 +k^2)\psi_0(\vec r)=0,\quad (-\nabla^2 +k^2)G(\vec{r},\vec{q})=\delta(\vec{r}-\vec{q}).$$
This seems simple, but: The product $V(\vec{q})\psi(\vec{q})$ must be zero inside the obstacle because $\psi$ vanishes there, and it must also be zero outside the obstacle, because $V$ vanishes there.
So how am I supposed to understand this integral? I suppose it somehow reduces to the boundary of the obstacle, but I am not able to see this exactly.
 A: $\newcommand{\bbx}[1]{\,\bbox[15px,border:1px groove navy]{\displaystyle{#1}}\,}
 \newcommand{\braces}[1]{\left\lbrace\,{#1}\,\right\rbrace}
 \newcommand{\bracks}[1]{\left\lbrack\,{#1}\,\right\rbrack}
 \newcommand{\dd}{\mathrm{d}}
 \newcommand{\ds}[1]{\displaystyle{#1}}
 \newcommand{\expo}[1]{\,\mathrm{e}^{#1}\,}
 \newcommand{\ic}{\mathrm{i}}
 \newcommand{\mc}[1]{\mathcal{#1}}
 \newcommand{\mrm}[1]{\mathrm{#1}}
 \newcommand{\pars}[1]{\left(\,{#1}\,\right)}
 \newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}}
 \newcommand{\root}[2][]{\,\sqrt[#1]{\,{#2}\,}\,}
 \newcommand{\totald}[3][]{\frac{\mathrm{d}^{#1} #2}{\mathrm{d} #3^{#1}}}
 \newcommand{\verts}[1]{\left\vert\,{#1}\,\right\vert}$

The "correct" equation involves de Gauss-Green Theorem. Namely $\ds{\pars{~\mbox{by the way,}\ \psi\pars{\vec{r}} = 0\quad \forall\ \vec{r} \in \mathbb{R}^{3}\quad\mbox{is the}\ solution~}}$,

\begin{align}
& \mbox{With}\quad\vec{r}\ \mbox{and}\ \vec{q}\quad
\mbox{"inside the domain"}\ \color{red}{\mc{D}}\,,\quad
\left\{\begin{array}{rcl}
\ds{\pars{-\nabla^{2} + k^{2}}\psi\pars{\vec{r}}} & \ds{=} & \ds{0}
\\[2mm]
\ds{\pars{-\nabla^{2} + k^{2}}\mrm{G}\pars{\vec{r},\vec{q}}} & \ds{=} & \ds{\delta\pars{\vec{r} - \vec{q}}}
\end{array}\right.
\\[1cm] &
\mbox{Then,}\
\mrm{G}\pars{\vec{r},\vec{q}}\pars{-\nabla^{2} + k^{2}}\psi\pars{\vec{r}} -
\psi\pars{\vec{r}}\pars{-\nabla^{2} + k^{2}}\mrm{G}\pars{\vec{r},\vec{q}} =
-\psi\pars{\vec{r}}\delta\pars{\vec{r} - \vec{q}}
\\[5mm] &
-\nabla\cdot\bracks{\mrm{G}\pars{\vec{r},\vec{q}}\nabla\psi\pars{\vec{r}} -
\psi\pars{\vec{r}}\nabla\mrm{G}\pars{\vec{r},\vec{q}}} =
-\psi\pars{\vec{r}}\delta\pars{\vec{r} - \vec{q}}
\\[5mm] &
\mbox{Integrating over}\ \vec{r} \in \color{red}{\mc{D}}:
\\ &
\psi\pars{\vec{q}}  =
\int_{\partial\color{red}{\mc{D}}}\bracks{\mrm{G}\pars{\vec{r},\vec{q}}\nabla\psi\pars{\vec{r}} -
\psi\pars{\vec{r}}\nabla\mrm{G}\pars{\vec{r},\vec{q}}}\cdot
\dd\vec{S_{\,\vec{r}}}
\end{align}

Now, you set $\ds{\mrm{G}\pars{\vec{r},\vec{q}} \equiv
\mrm{G}_{D}\pars{\vec{r},\vec{q}}}$ where
  $\ds{\left.\rule{0pt}{5mm}\mrm{G}_{D}\pars{\vec{r},\vec{q}}
\right\vert_{\ \vec{r}\ \in\ \partial\color{red}{\mc{D}}} = 0}$:

$$
\bbx{\psi\pars{\vec{r}}  =
-\int_{\partial\color{red}{\mc{D}}}
\psi\pars{\vec{q}}\nabla\mrm{G}_{D}\pars{\vec{q},\vec{r}}\cdot
\dd\vec{S_{\,\vec{q}}}\,,\qquad\vec{r} \in \color{red}{\mc{D}}\,,\quad
\left.\rule{0pt}{5mm}\mrm{G}_{D}\pars{\vec{q},\vec{r}}
\right\vert_{\ \vec{q}\ \in\ \partial\color{red}{\mc{D}}} = 0}
$$
