Loading...
Loading...
Expert assistant for VASP (Vienna Ab initio Simulation Package) calculations - input file generation, parameter selection, workflow setup, and best practices for accurate DFT calculations
npx skill4agent add jkitchin/skillz vaspENCUT = 520 # eV, typical for PAW potentials# Method 1: Automatic mesh
KSPACING = 0.5 # Å⁻¹, automatic generation
# Method 2: Manual KPOINTS file
# Recommended density: 30-50 k-points per Å⁻¹PREC = Accurate # High, Normal, AccurateEDIFF = 1E-6 # eV, energy convergence# System description
SYSTEM = Cu bulk FCC
# Electronic minimization
ENCUT = 520 # Cutoff energy (eV)
EDIFF = 1E-6 # SCF convergence (eV)
NELM = 100 # Max electronic steps
ALGO = Fast # Algorithm: Normal, Fast, All
ISMEAR = 1 # Smearing: -5(tetra), 0(Gauss), 1(M-P)
SIGMA = 0.2 # Smearing width (eV)
# Precision
PREC = Accurate # Precision level
LREAL = Auto # Real-space projection
# Ionic relaxation
IBRION = 2 # 0=static, 1=RMM-DIIS, 2=CG
ISIF = 3 # 2=relax ions, 3=relax cell+ions
NSW = 100 # Max ionic steps
EDIFFG = -0.02 # Force convergence (eV/Å)
# Output
LWAVE = .FALSE. # Write WAVECAR
LCHARG = .FALSE. # Write CHGCARCu FCC bulk
1.0 # Universal scaling
3.61 0.00 0.00 # Lattice vectors
0.00 3.61 0.00
0.00 0.00 3.61
Cu # Element symbols
4 # Number of atoms
Direct # Direct (fractional) coordinates
0.00 0.00 0.00
0.50 0.50 0.00
0.50 0.00 0.50
0.00 0.50 0.50Automatic mesh
0 # 0=automatic
Gamma # Gamma or Monkhorst-Pack
8 8 8 # k-point grid
0 0 0 # ShiftAutomatic mesh
0
Monkhorst-Pack
8 8 8
0 0 0k-points for band structure
10 # Number of points between high-symmetry points
Line-mode # Line mode for band structure
Reciprocal
0.0 0.0 0.0 !Γ
0.5 0.0 0.5 !X
0.5 0.0 0.5 !X
0.5 0.25 0.75 !W# Concatenate POTCARs in same order as POSCAR
cat ~/vasp/potpaw_PBE/Cu/POTCAR > POTCAR
# For compounds:
cat ~/vasp/potpaw_PBE/Cu/POTCAR \
~/vasp/potpaw_PBE/O/POTCAR > POTCARpotpaw_PBE/Element/POTCARpotpaw_PBE.52/Element/POTCARpotpaw_PBE.54/IBRION = 2 # Conjugate gradient
ISIF = 3 # Relax cell + ions
NSW = 100
EDIFFG = -0.02 # Force convergence
ISMEAR = 1 # Methfessel-Paxton
SIGMA = 0.2EDIFFG < 0EDIFFG > 0IBRION = -1 # No ionic updates
NSW = 0
ISMEAR = -5 # Tetrahedron (accurate DOS)
# OR
ISMEAR = 0 # Gaussian (if tetra not converged)
SIGMA = 0.05ICHARG = 2 # From atoms
LCHARG = .TRUE. # Write CHGCARICHARG = 11 # Read CHGCAR, no update
LORBIT = 11 # Write PROCAR
# Use line-mode KPOINTSISMEAR = -5 # Tetrahedron method
LORBIT = 11 # Projected DOS
NEDOS = 3000 # DOS resolution
# Use dense k-point meshIBRION = 0 # MD
NSW = 1000 # MD steps
POTIM = 1.0 # Time step (fs)
TEBEG = 300 # Start temperature (K)
TEEND = 300 # End temperature
SMASS = 0 # NVE: 0, NVT: >0
MDALGO = 2 # 1=Andersen, 2=Nose-HooverIBRION = 6 # DFPT for phonons
NFREE = 2 # Central differences
POTIM = 0.015 # Displacement (Å)
EDIFF = 1E-8 # Tight convergence!IBRION = 6 # DFPT
ISIF = 3
NFREE = 4 # For elastic constantsLHFCALC = .TRUE. # Activate hybrid
HFSCREEN = 0.2 # HSE screening parameter
AEXX = 0.25 # Exact exchange fraction
ALGO = All # Or Damped
TIME = 0.4 # Damping for convergenceALGO = Exact
NBANDS = 200 # Many empty bands
LOPTICS = .TRUE.ALGO = GW0 # Or EVGW
NOMEGA = 50LDAU = .TRUE.
LDAUTYPE = 2 # Dudarev
LDAUL = 2 -1 # l quantum number (d, s/p)
LDAUU = 5.0 0.0 # U value (eV)
LDAUJ = 0.0 0.0 # J valueIVDW = 11 # DFT-D3 (Grimme)GGA = MK # optPBE-vdW
LUSE_VDW = .TRUE.
AGGAC = 0.0000# Test sequence
KPOINTS: 4x4x4, 6x6x6, 8x8x8, 10x10x10, 12x12x12
# Converged when ΔE < 1 meV/atom between successive grids# Test ENCUT
ENCUT: 400, 450, 500, 550, 600 eV
# Converged when ΔE < 1 meV/atom
# Forces may need higher cutoff| ISMEAR | Method | Use Case |
|---|---|---|
| -5 | Tetrahedron | Static calcs, DOS, accurate energies |
| -4 | Tetrahedron+Blöchl | Like -5, slightly different |
| -1 | Fermi smearing | Metals |
| 0 | Gaussian | General purpose |
| 1+ | Methfessel-Paxton order N | Relaxations, metals |
# INCAR
ENCUT = 520
PREC = Accurate
IBRION = 2
ISIF = 3
NSW = 100
EDIFFG = -0.02
ISMEAR = 1
SIGMA = 0.2
ALGO = Fast
LREAL = Auto
# KPOINTS
Gamma-centered
0
Gamma
8 8 8
0 0 0# INCAR
ENCUT = 600 # Higher cutoff
PREC = Accurate
IBRION = -1
NSW = 0
EDIFF = 1E-8 # Tight convergence
ISMEAR = -5 # Tetrahedron
ALGO = Normal
LREAL = .FALSE. # Reciprocal space
# KPOINTS (very dense)
0
Gamma
12 12 12
0 0 0# INCAR
ENCUT = 400 # Lower cutoff
PREC = Normal
EDIFF = 1E-4 # Loose
ISMEAR = 0
SIGMA = 0.1
ALGO = Fast
LREAL = Auto
# KPOINTS (coarse)
0
Gamma
4 4 4
0 0 0NCORE = 4 # Cores per band (orbital parallelization)
# OR
NPAR = 8 # Number of groups for band parallelization
KPAR = 4 # k-point parallelization
LPLANE = .TRUE. # Plane-wise distributionLREAL = Auto # Reduce memory for large systems
NCORE = 4 # Reduce memory per core# Fix: Reduce POTIM or use different IBRION
POTIM = 0.2# Fix: Increase NELM, change ALGO
NELM = 200
ALGO = All# Fix: Reduce POTIM, check structure
POTIM = 0.1
SYMPREC = 1E-8# Try sequential fixes:
1. ALGO = All
2. Increase NELM = 200
3. AMIX = 0.2, BMIX = 0.0001
4. Check initial structure (too close atoms?)| Goal | IBRION | ISIF | ISMEAR | EDIFFG |
|---|---|---|---|---|
| Relax ions only | 2 | 2 | 1 | -0.02 |
| Relax cell+ions | 2 | 3 | 1 | -0.02 |
| Static energy | -1 | 2 | -5 | N/A |
| MD simulation | 0 | 2 | 0 | N/A |
| Band structure | -1 | 2 | 0 | N/A |
| Phonons (DFPT) | 6 | 2 | 0 | N/A |
materials-propertiesexamples/references/