Solution (source code)

= Solution

Apply the <product rule> to the <vector field> $F=\phi\nabla\psi-\psi\nabla\phi$:
$$
\nabla\cdot F=\nabla\phi\cdot\nabla\psi+\phi\nabla^2\psi-\nabla\psi\cdot\nabla\phi-\psi\nabla^2\phi=\phi\nabla^2\psi-\psi\nabla^2\phi.
$$
The two mixed <dot products> cancel. The <divergence theorem>, using the outward <unit normal>, then gives <Green's second identity>:
$$
\boxed{\int_V(\phi\nabla^2\psi-\psi\nabla^2\phi)\,dV=\int_S(\phi\,n\cdot\nabla\psi-\psi\,n\cdot\nabla\phi)\,dS.}
$$
The usual assumptions are a sufficiently regular boundary and fields with the derivatives and integrability needed for the theorem; singular sources can instead be treated by excising small balls or using <distributions>.