Derivation of the Schrödinger–Poisson equation from the quantum N-body problem