The aim of this article is to analyze numerical schemes using two-layer neural networks with infinite width for the resolution of the high-dimensional Poisson partial differential equation with Neumann boundary condition. Using Barron’s representation of the solution [IEEE Trans. Inform. Theory 39 (1993), pp. 930–945] with a probability measure defined on the set of parameter values, the energy is minimized thanks to a gradient curve dynamic on the
2
2
-Wasserstein space of the set of parameter values defining the neural network. Inspired by the work from Bach and Chizat [On the global convergence of gradient descent for over-parameterized models using optimal transport, 2018; ICM–International Congress of Mathematicians, EMS Press, Berlin, 2023], we prove that if the gradient curve converges, then the represented function is the solution of the elliptic equation considered. Numerical experiments are given to show the potential of the method.