Dear Dr Tee,
I hope this message finds you well.
I am Lingzhi Cao, a PhD student in University of Melbourne. I am currently working with the ELECTRODE package in LAMMPS to use the constant potential method for controlling the electric potential at a solid–liquid interface. However, I encountered some discrepancies when attempting to extract the electric potential, and I would greatly appreciate your insights on this.
Here is the procedure I followed:
I began by running the au-aq
test case provided in the package. I first ran the simulation using the in.ffield
input script to get a trajectory file, and then performed a rerun on this trajectory while switching off vdW interactions (i.e., only retaining the coul/long interactions). During this rerun, I extracted the electrostatic potential energy of each atom using compute pe/atom pair kspace
. My intention was to compute the local electric potential by dividing this energy by the corresponding atomic charge.
However, I noticed a discrepancy: the electric potential values derived in this way do not match the applied values specified in the original in.ffield
input. Specifically, I had set a potential difference of 2 V between the two electrodes using the command:
fix conp bot electrode/conp -1.0 1.805132 couple top 1.0 symm on ffield yes etypes on
If I interpret the syntax correctly, this should enforce -1 V on the bottom electrode and +1 V on the top. But the potential values I obtained from my postprocessing instead showed -0.19 V for the negative electrode and +0.39 V for the positive one. Interestingly, atoms within each metal surface do appear to share a consistent potential, but the absolute values differ from what I had expected.
Could you kindly advise if there is anything I may have misunderstood in either the interpretation of the electrode/conp
settings or the methodology I used for extracting the electric potential?
To help clarify my issue, I’ve uploaded my input scripts to dropbox (https://www.dropbox.com/scl/fi/b14qbtpkdhwgkymcivwqu/input_scripts_lc.tar.xz?rlkey=6tgdmfkp75m1kwmvx6rnmlts7&st=w6t6c4d9&dl=0). I am using LAMMPS version 29Aug2024, compiled with Intel OneAPI and the Intel acceleration package.
Thanks @srtee very much for your excellent work on the ELECTRODE package. I’m truly grateful for your time and any guidance you can provide.
Kind regards,