using your package I encountered some problem I could not resolve by myself. I'd be deeply grateful if you could offer some advice.
The problem is the following:
Using P3M and ELC with an external potential (via the "pot_diff" argument), I get Coulomb energies that make no sense. The energy contribution of charges in the "external" potential defined by "pot_diff" seems to be off by a factor of 2.
Let's say the system has a length of 10 and pot_diff=1V is set. Further, only two particles are placed in the system at z=0 (charge q=+1e) and at z=9 (charge q=-1e) and the prefactor for the P3M is set such that the interactions among the particles are negligible. For this case, I would expect a Coulomb energy of approx. 0.8eV. However, espresso seems to have a different opinion, namely that it should be 0.4eV.
Please find a minimal example code attached to this email.
I'm looking forward to hearing from you,