where indicates electron coordinates corresponding to and proton coordinates corresponding to and are the vectors of the periodic lattice associated with the simulation box. Notice that this summation converges only for neutral systems . For short range interaction it is possible to consider only the closest images, that represents an efficient and accurate way to calculate the potential energy. For long range interaction the equation eq. 4.9 cannot be used in a numerical simulation because the sum is very slowly convergent, so other approaches are necessary.

It is not possible to use a truncated Coulomb potential. In fact, large inaccuracies are introduced by neglecting the long-range part (see Ref. (78)).

In the following we present the well known Ewald method that allows to evaluate in an efficient way the potential energy in periodic systems.