This depends what your goal is. For structural optimization this is actually a tricky thing. In general people suggest using the force convergence criterion set to something like 10-30 meV/A (EDIFFG = -0.02 to -0.03), but this will give you not a nicely converged structure, let alone anything useful for frequency calculations.
Force optimizations (when set to good accuracy: EDIFFG = -0.001 or 1meV/A) tend to get stuck in plateau's.
Even if this is not the case, I found that when restarting from such force optimized structures, performing an energy based structure optimization, you find a different structure at much lower energy. So the best option in my experience is using an energy convergence criterion (to start from): set to EDIFFG=1E-6 or lower, with EDIFF=EDIFFG/10. You will end up with forces being converged to less that 1-2 meV/A for the atom experiencing the largest force. If the energy criterion get's stuck on a plateau (e.g. in a molecular crystal) you can still perform a continuation using the force criterion with forces set to 1meV/A (or lower)
(some more on structure optimization you can find here on my website:
For good structural relaxation, EDIFFG = -0.00001 to -0.00002 may be good option to set. If your structure has no variable atomic coordinates, you can skip this parameter.
If you are running your VASP calculation on multiple nodes then you can also use 'NPAR' parameter to make your parallel calculation faster. In my opinion your 'EDIFFG' value is good enough if your material system is metallic.
Is your system magnetic? If not, then remove ISPIN tag. This will faster your calculation. If you have wall time or electricity issue, then you can restart your calculation replacing original poscar by contcar.
Thank you sir No my system is not magnetic but I want to apply spin dependent DFT so I put ISPIN tag . Pulkit Sir my system is not metallic it is wide band gap semiconductor. Yes I am running it in 64 core .Actually I put H2 molecules on metal functionalize 3x3x1 sheet of the material it moving to 20 to 30 steps give message like this please rerun with smaller EDIFF, or copy CONTCAR
to POSCAR and continue this happened so many times with me
Dear Danny E. P. Vanpoucke Sir my goal to calculate adsorption energy of Hydrogen with metal fuctionalize sheet
Pushkar, as it seems you do not have a very small system and are looking into the adsorption of a small molecule, the suggested settings by Enamul Haque are too much.
EDIFF= 1.0E-7
EDIFFG = 1.0E-6
(note that EDIFFG = -1.0E-5, i.e. 0.01meV/A forces are doubtfull to ever be reached...in any system I am tempted to say...while 1.0E-10 (energy) will probably make you run into algoritmic convergence issues due to the numerical accuracy of a double.)
To speed your life up:
Parallelise: preferably over KPOINTS (KPAR) as this scales ridiculously well
1) perform a stepwise optimisation: First do an initial optimisation using Gamma-point only (this is to get your H2 bound to the surface--> check this)
2) increase you k-point set in steps (2x2x1, 3x3x1, 5x5x1 if the latter is your target). Howere do this not in a single relaxation, but in series of relaxations (eg no more than 100 ionic steps, and consider the step converged if your relaxation converges within 10 ionic steps...note that this approach is specifically for systems where the shape and/or volume of the cell changes)
3) btw SIGMA should not be used with IBRION=-5, and if you use it, never set it to a value as large as 0.1 eV...0.05 or even 0.01 will be better combined with a gaussian smearing.
Dear Danny E. P. Vanpoucke , Yes, it is too much for some systems, but it ( EDIFF = 1E-8; 1E-9) is good enough for H-O based systems. Please see this example in vaspwiki. Thanks a lot. https://cms.mpi.univie.ac.at/wiki/index.php/H2O_vibration.
Dear Enamul Haque indeed for a simple molecule or a small unitcell solid, it definately is...but the moment you look into adsorbed molecules on a surface things become more complicated. From experience I can tell you momentum transfer from a surface to a molecule can really complicate relaxations. :-)
Thanks all for your valuable suggestion. Dear Danny E. P. Vanpoucke sir I am using tetrahedron smearing ISMEAR = -5 which is not taking less than 5X5X1 kpoints
I'm not sure if this question has already been fully answered, but in my experience, it is best to keep NSW around 20-25 and restart from a previous CONTCAR if you don't converge within that many steps. Often times your system will get stuck in local energy minima and you won't ever get out. So, check your energy and forces to see if they are converging or if they are just oscillating after 20-25 ionic steps. You may need to shift a few atoms slightly to get the system to find the global minimum, but that truly is the crux of dft and structural optimization.
I am new to DFT calculation, and I am using VASP. In a lot of my jobs, the forces are already smaller than the EDIFFG tag that I set in the INCAR, but, the jobs won't stop!!! The jobs will continue to run, and sometimes the forces get worse. Please help me with this matter. Thanks!
As you might known, VASP works through a rule that guess a charge density and apply it to solve a KS function. The process will be dominated by ALGO term and that will produce a electrons energy satisfied EDIFF. If all the guess under NELM steps cannot make it, then the VASP will move ions by IBRION method unless you pick NSW= 0 and repeat the circle, where ion terms will need to satisfy EDIFFG.
So a converge condition needs to satisfy BOTH EDIFF and EDIFFG terms. If you find your forces get worse, it may due to the energy cannot converge. So you may reduce EDIFF or optimize a better initial positions. Sometimes, the choose of functions in POTCAR or PREC may also affect the convergence.