Page 1 of 1
Correct way to manually input a regular k-point mesh
Posted: Fri Feb 28, 2025 9:56 pm
by hzyeumd
Hi,
I am very new to VASP, so I apologize in advance if this is a basic question. I have carefully reviewed the user manual on KPOINTS but encountered an unexpected discrepancy.
I am performing a simple HF calculation for diamond. The necessary input files and my OUTCAR files are attached to this post. I ran the calculation twice (in separate folders) using two different KPOINTS files:
Since IBZKPT lists the k-points actually used in the first calculation, I expected both runs to produce identical energies. However, the results differ slightly:
You can see that they differ by 0.02 eV, which is significantly larger than the SCF convergence criterion, "ediff = 1e-7".
Is this discrepancy expected? Is there a way to manually input k-points (as in KPOINTS2) and still obtain results consistent with using a regular, auto-generated mesh (as in KPOINTS1)?
I would greatly appreciate any insights or suggestions. Thanks in advance for your help!
================
diamond.zip
Re: Correct way to manually input a regular k-point mesh
Posted: Mon Mar 03, 2025 1:58 pm
by ferenc_karsai
In LHFCALC=.TRUE. calculations one needs to use the KPOINTS in the first way, so with defining the mesh from which it is generated.
This needs to be done this way, since gamma point corrections are calculated at the beginning of the code and they need to know the mesh the k-point was generated from. With explicit k-points this cannot be known.
You should also see that by increasing the number of k-points the difference between calculations using the two KPOINTS files should become smaller, because the gamma point corrections become less important.
Why did you want to use the IBZKPT file in LHFCALC=.TRUE. calculation?
I'm asking because if you are interested in band-structure calculations then you need to use the KPOINTS_OPT file.
Please also see here.
Re: Correct way to manually input a regular k-point mesh
Posted: Mon Mar 03, 2025 2:57 pm
by hzyeumd
Hi Ferenc, thank you for your quick response.
This needs to be done this way, since gamma point corrections are calculated at the beginning of the code and they need to know the mesh the k-point was generated from. With explicit k-points this cannot be known.
That makes perfect sense. In another code I used, the mesh is deduced from the input list of k-points automatically as long as it corresponds to a regular mesh. But I can see that this cannot be done for general k-points input and it may be safer to not do that.
Why did you want to use the IBZKPT file in LHFCALC=.TRUE. calculation?
I'm asking because if you are interested in band-structure calculations then you need to use the KPOINTS_OPT file.
Thank you for the tip about using the KPOINTS_OPT file for band structure calculations. My original intention was to realize "Gamma-inclusive" k-point mesh, which differs by VASP's "Gamma-centered" k-point mesh by a shift. Following your suggestion, I will input the mesh size directly and apply the said shift instead of using the list of k-points input.