Free interactive course · 37 lectures and a capstone · 10 parts
Density Functional Theory and VASP
An interactive course from the Schrödinger equation to calculations you can defend.
Density functional theory (DFT) is the method behind most electronic-structure calculations of real materials, and VASP is one of its most widely used codes. This course builds both from first principles: the quantum mechanics you need, the Hohenberg–Kohn and Kohn–Sham theory, exchange–correlation functionals, k-points, plane waves and PAW, and then the calculations used in research, from relaxations and magnetism to phonons, migration barriers and machine-learning potentials.
The thread through the course
Each idea makes the next one necessary. Follow the chain from the Schrödinger equation to a VASP calculation.
- Born–Oppenheimer
- Many electrons
- Density
- Hohenberg–Kohn
- Kohn–Sham
- SCF
- Bloch states and k-points
- Plane waves
- PAW
- VASP
- Energies and forces
- Phonons, NEB, MD, ML potentials
How the lectures work
Slides with the lecture underneath
Each lecture is a set of 16:9 slides, and under each slide are the notes of what is said about it. Read the page like an article, or press P to present the slides full screen.
Interactive figures
Change a parameter and watch the physics respond. Every number in a figure is computed in your browser; model systems are labelled as models.
Self-contained
Every symbol is defined where it appears and the key equations are derived, with worked numbers, so you can learn without another book open. Terms and VASP tags open a short explanation in place.
VASP cheat sheets
The practical side of the course: what to type, how to check that it worked and what usually goes wrong, organized by task and checked against VASP 6.6.1.
- INCAR The tags to set yourself, their defaults, smearing choices and copy-ready INCARs for each task.
- KPOINTS Every KPOINTS format, which mesh suits which lattice, KSPACING and band-structure paths.
- POTCAR Suffixes decoded, building and checking a POTCAR without printing it, and the rare-earth choice.
- POSCAR The format line by line, selective dynamics, CONTCAR reuse and the mistakes that stop a run.
- Slurm job script CPU and GPU job scripts, MPI ranks and threads, NCORE and KPAR, chained jobs and monitoring.
- Reading the output Which file holds what, one-line commands for energy, forces, stress, moments and convergence.
- Errors and fixes Each error message with its cause and fix, and what to try when the SCF or a relaxation will not converge.
- Relaxation From a starting structure to converged geometry, static energy, DOS and band structure.
- Magnetism Ferro-, antiferro- and ferrimagnetic setups, moments, spin–orbit coupling, anisotropy and DFT+U.
- Properties Every major property with the tags, earlier steps, output files and analysis tools it needs.
- NEB Migration barriers with stock VASP and with VTST: setup, climbing image and checks.
- AIMD and ML force fields Thermostats and ensembles, time steps, analysis, and on-the-fly machine-learned force fields.
Start here
Part I · Quantum mechanics you need
- Lecture 1
The Born–Oppenheimer approximation
What physical problem is VASP solving when it relaxes a structure?
- Lecture 2
Wavefunctions, operators and eigenvalues
What does Ĥψ = Eψ actually mean?
- Lecture 3
The variational principle and basis sets
How does an unsolvable differential equation become a finite calculation?
- Lecture 4
Atomic orbitals, core and valence electrons
Where do s, p, d and f, and “core” versus “valence”, come from?
- Lecture 5
Pauli exclusion and Slater determinants
What makes many electrons harder than one, and what does the Pauli principle demand?
- Lecture 6
The Hartree–Fock method
What is the best you can do with one Slater determinant, and what does it miss?
Milestone. Explain why electronic structure is a many-body problem, and what “self-consistent” means.
Part II · Density functional theory
- Lecture 7
Electron density and functionals
Can three coordinates replace 3N?
- Lecture 8
The Hohenberg–Kohn theorems
Why is the density, in principle, enough?
- Lecture 9
The Kohn–Sham equations
How did Kohn and Sham turn an existence theorem into a working method?
- Lecture 10
Exchange–correlation energy and the xc hole
What physics is hidden inside the exchange–correlation energy?
- Lecture 11
LDA, GGA and the PBE functional
What exactly is approximated when INCAR says GGA = PE?
- Lecture 12
Self-consistent field convergence
Why can't VASP solve the Kohn–Sham equations once and stop?
Milestone. Explain the chain from the Schrödinger equation through Born–Oppenheimer, the many-electron problem, the density, Hohenberg–Kohn and Kohn–Sham to the exchange–correlation energy and the SCF loop.
Part III · Electrons in crystals
- Lecture 13
The reciprocal lattice and the Brillouin zone
Why does a crystal lead naturally into reciprocal space?
- Lecture 14
Bloch's theorem and band structure
What does a k-point physically represent?
- Lecture 15
k-point sampling and Monkhorst–Pack grids
Why does a periodic calculation need many k-points, and how many?
- Lecture 16
Smearing: ISMEAR and SIGMA
Why do metals need special treatment of occupations, and what do ISMEAR and SIGMA really do?
Part IV · How VASP represents electrons
- Lecture 17
Plane waves and the ENCUT cutoff
What exactly does ENCUT truncate?
- Lecture 18
PAW, pseudopotentials and the POTCAR
Why is choosing a POTCAR a physics decision?
- Lecture 19
VASP input files and convergence tests
What does each line of my inputs do, and how do I know my numbers are converged?
Milestone. Explain why VASP uses periodic cells, k-points, plane waves, ENCUT, PAW datasets and the POTCAR.
Part V · Energies, forces and structures
- Lecture 20
Formation energy and the convex hull
What number is VASP minimizing, and when is comparing two of them meaningful?
- Lecture 21
Forces, stress and structural relaxation
How can an electronic calculation produce forces, and what changes when ISIF changes?
- Lecture 22
Equations of state and elastic constants
How do I get a reliable lattice constant, bulk modulus or elastic tensor?
Part VI · Spin, magnetism and correlated electrons
- Lecture 23
Spin-polarized DFT and magnetism
What does spin-polarized DFT solve differently, and why can MAGMOM change the answer?
- Lecture 24
Spin–orbit coupling and magnetic anisotropy
Why does a magnet's energy depend on which way its moments point?
- Lecture 25
DFT+U and the Hubbard U
What does DFT+U correct, and why does the answer depend on U?
Part VII · Beyond semilocal functionals
- Lecture 26
Meta-GGA functionals: SCAN and r²SCAN
What does the kinetic-energy density add, and is higher on the ladder always better?
- Lecture 27
Hybrid functionals and HSE06
Why is HSE so much more expensive than PBE, and what do you get for the cost?
- Lecture 28
van der Waals and dispersion corrections
Why does semilocal DFT miss what holds graphite layers and molecular crystals together?
Milestone. Compare PBE, DFT+U, r²SCAN, dispersion-corrected DFT and HSE by approximation, cost and typical failures.
Part VIII · Reading electronic structure
- Lecture 29
Band structure, DOS and projected DOS
What can, and can't, be concluded from a band structure?
- Lecture 30
Why DFT underestimates band gaps
Why is “PBE underestimates band gaps” an incomplete explanation?
Part IX · From energies and forces to materials properties
- Lecture 31
Phonons and dynamical stability
How do second derivatives of the energy become vibrational spectra, and what does an imaginary mode mean?
- Lecture 32
The nudged elastic band method
How do we find the barrier for an atom, or a proton, to hop?
- Lecture 33
Ab initio molecular dynamics
How do DFT forces drive atoms in time, and how do I know my MD is trustworthy?
- Lecture 34
Machine-learning interatomic potentials
How can DFT data train a fast potential, and which DFT errors does it inherit?
Part X · Doing DFT responsibly
- Lecture 35
DFT errors: convergence versus accuracy
What kind of error am I reducing when I converge a calculation?
- Lecture 36
Writing a defensible DFT methods section
How do I choose, justify and report a methodology that survives peer review?
- Capstone
Audit a real VASP calculation
Could every choice in one of your own calculations survive a referee's questions?
Milestone. Design, critique and defend a DFT methodology for a real research problem.
Who this course is for
Students and researchers who want to understand what a DFT calculation does, not only how to run one. You need calculus and first-year physics; quantum mechanics is taught from the start. You need access to VASP only for the hands-on labs.
Also on this site: an interactive guide to crystallographic symmetry and the 230 space groups, the language behind POSCAR files and k-point meshes.
How the course is checked
- Every claim is checked against primary papers, textbooks, lecture notes and the official VASP documentation before it is published. Each lecture ends with a short list of further reading.
- VASP tags and defaults are checked against the VASP Wiki when a lecture is written.
- Numbers in interactive figures come from code tested against exact results.
- Lab results come from real VASP runs, never invented output.
- Each lecture is fact-checked independently before it is published.
About the instructor
I'm a computational materials scientist and Ph.D. candidate in Mechanical Engineering at the University of North Carolina at Charlotte, and an Academic Cooperation Participant at Lawrence Livermore National Laboratory. I use DFT and VASP in my research on rare-earth permanent magnets, proton-conducting ceramics, carbon allotropes and molecular crystals, alongside machine-learning interatomic potentials and generative models.