For a Poisson point process with intensity measure and a square-integrable measurable function ,The second identity follows because distinct points contribute the square of the mean, while the diagonal contribution is .
The expectation identity holds for a general point process with intensity measure whenever the sum is integrable. The stated variance identity uses the additional Poisson point process assumption.
New to topics? Read the docs here!