Page 1 of 1
Dipole correction using LDIPOL
Posted: Mon May 11, 2026 11:37 am
by IBRAHIM
Dear VASP admin,
When using LDIPOL for molecules or slabs in VASP, does the molecule or slab need to be placed at a specific position inside the simulation cell?
We are confused by the following statement in the VASP wiki https://www.vasp.at/wiki/Electrostatic_corrections: "Note that the system has plenty of vacuum on either side. This empty space is important for the potential corrections needed for the LDIPOL tag."
Many thanks in advance,
Ibrahim
Re: Dipole correction using LDIPOL
Posted: Mon May 11, 2026 3:35 pm
by martin.schlipf
VASP has a built-in mechanism to determine the position where the center of the cell is. We recommend that you set it with the tag DIPOL manually if you want to be more precise. Otherwise you need to make sure that VASP got it correct
Re: Dipole correction using LDIPOL
Posted: Tue May 12, 2026 7:16 am
by IBRAHIM
Thanks for your reply.
- That means that for LDIPOL tag, there is no specific position inside the simulation cell, and we should instead take care of the cell center defined by the DIPOL tag, right?
- How can we make sure that VASP interpreted it correctly when the default value is used? When we checked the XML files, we found <v name="DIPOL"> -100.00000000 -100.00000000 -100.00000000 </v>. Also, the SCF procedure was stable and the calculations converged.
Many thanks in advance,
Ibrahim
Re: Dipole correction using LDIPOL
Posted: Tue May 12, 2026 10:41 am
by martin.schlipf
If you do not set the DIPOL flag, VASP will report something like this
Code: Select all
DIPCOR: dipole corrections for dipol
direction 3 min pos 58,
in the OUTCAR file. The position (here 58) tells you where VASP put the dipole. If you do set DIPOL, VASP will use it to compute position from that. The position is given as a grid coordinate.
Re: Dipole correction using LDIPOL
Posted: Tue May 12, 2026 11:30 am
by IBRAHIM
Thanks again for your reply.
In fact, we tested one of our systems with and without DIPOL and with the cluster is centered and when it is shifted away from the center.
We observed the following:
- When the cluster is centered and DIPOL is set to (0.5, 0.5, 0.5), the calculation converges.
- When the cluster is centered and DIPOL is not specified in the INCAR file, the calculation does not converge.
- When the cluster is shifted away from the center and DIPOL is not specified in the INCAR file, the calculation converges.
So, if the calculation converges, does this mean that VASP has correctly interpreted the DIPOL tag and that the dipole correction has been correctly applied?
Many thanks in advance,
Ibrahim
Re: Dipole correction using LDIPOL
Posted: Wed May 13, 2026 6:33 am
by martin.schlipf
If you set DIPOL in the INCAR file, VASP knowns where the center of the cluster is and will always use the correct position. Otherwise it will guess where it is by looking at the density. If can make a mistake and that then leads to the calculation not converging. Think of it this way: You should typically tell VASP where the center of the cell is, but if you forget, VASP will try to converge the calculation anyway using reasonable defaults.
You can see that in the output that you produced by looking at the line that I had suggested echo $file; grep 'direction.*min pos' $file | tail -n 5. If you set DIPOL in the INCAR file, VASP does not need to guess where the center is and always uses the same position. In the case that does not converge, VASP guesses very different positions in every iteration. In contrast, when VASP finds the correct position like in the last case, the calculation converges.
Code: Select all
DIPOL-position-centered/OUTCAR
direction 1 min pos 1, direction 2 min pos 1, direction 3 min pos 1,
direction 1 min pos 1, direction 2 min pos 1, direction 3 min pos 1,
direction 1 min pos 1, direction 2 min pos 1, direction 3 min pos 1,
direction 1 min pos 1, direction 2 min pos 1, direction 3 min pos 1,
direction 1 min pos 1, direction 2 min pos 1, direction 3 min pos 1,
No-DIPOL-position-centered/OUTCAR
direction 1 min pos 120, direction 2 min pos 193, direction 3 min pos 98,
direction 1 min pos 183, direction 2 min pos 224, direction 3 min pos 243,
direction 1 min pos 256, direction 2 min pos 130, direction 3 min pos 67,
direction 1 min pos 168, direction 2 min pos 86, direction 3 min pos 45,
direction 1 min pos 159, direction 2 min pos 82, direction 3 min pos 42,
No-DIPOL-position-shifted/OUTCAR
direction 1 min pos 97, direction 2 min pos 86, direction 3 min pos 94,
direction 1 min pos 96, direction 2 min pos 86, direction 3 min pos 93,
direction 1 min pos 95, direction 2 min pos 86, direction 3 min pos 92,
direction 1 min pos 94, direction 2 min pos 87, direction 3 min pos 92,
direction 1 min pos 93, direction 2 min pos 87, direction 3 min pos 92,
Re: Dipole correction using LDIPOL
Posted: Wed May 13, 2026 12:29 pm
by IBRAHIM
Thank you very much for the detailed reply.
martin.schlipf wrote: Wed May 13, 2026 6:33 am
If you set DIPOL in the INCAR file, VASP does not need to guess where the center is and always uses the same position.
Does this have an effect in the case of ionic optimization, where the center of the cluster can change relative to its initial position?
Many thanks in advance,
Ibrahim
Re: Dipole correction using LDIPOL
Posted: Thu May 14, 2026 4:44 pm
by martin.schlipf
VASP will not included a force contribution from the DIPOL moving in the cell while in principle it should. But if that would lead to a force then the dipole correction is not a good approximation.
Re: Dipole correction using LDIPOL
Posted: Mon May 18, 2026 7:58 am
by IBRAHIM
martin.schlipf wrote: Thu May 14, 2026 4:44 pm
VASP will not included a force contribution from the DIPOL moving in the cell while in principle it should. But if that would lead to a force then the dipole correction is not a good approximation.
Thank you.
Could you please clarify this point further?
We would set the tag DIPOL manually in INCAR to be more precise, as you recommended. Should we be concerned about this during ionic optimization?
Many thanks in advance,
Ibrahim
Re: Dipole correction using LDIPOL
Posted: Mon May 18, 2026 10:53 am
by IBRAHIM
Also, I f we restarted the calculation with CONTCAR, should every time DIPOL is modified in INCAR.
Many thanks in advance,
Ibrahim
Re: Dipole correction using LDIPOL
Posted: Mon May 18, 2026 12:43 pm
by martin.schlipf
In principle you should change DIPOL but that should almost never necessary in practice. It is only required if the atoms move by such a large amount that was the center of the cluster is not anymore. It does not need to be the exact center, approximately in the center is fine.