科研 Skill

点缺陷第一性原理计算

dft-defects

Covers first-principles point-defect modeling: vacancy/interstitial/antisite/substitutional construction, charge-state calculations. Use for defect thermodynamics studies.

发布者 Codar安全审核通过v0.1.0更新于 2026-11-18

SKILL.md

DFT Point Defect Calculations

Description

This skill covers the first-principles modeling of point defects in crystalline materials: vacancy, interstitial, antisite, substitutional, and complex defect construction; charge-state calculations; defect formation energy formalism with chemical potential constraints; finite-size corrections (Freysoldt-Neugebauer-Van de Walle, Kumagai-Oba, Makov-Payne); Fermi-level-dependent thermodynamics; transition levels; band-edge alignment; and defect concentration estimates. It uses VASP as the primary DFT backend with pymatgen (including the doped and shakenbreak packages) for automated defect generation, correction calculation, and thermodynamic analysis. Invoke this skill when computing defect formation energies, charge transition levels, defect concentrations, or carrier compensation in semiconductors and insulators.

Domain Context

Point defects are local disruptions of the perfect crystal lattice that control a wide range of functional properties: carrier concentration in semiconductors, ionic conductivity in solid electrolytes, color centers in optical materials, m…

Moved to references/domain-context.md to keep this file short; read it when this part is needed.

When to Use This Skill

  • Computing defect formation energies and thermodynamic transition levels for point defects in semiconductors and insulators.
  • Determining equilibrium carrier concentrations (electrons, holes) as a function of Fermi level and synthesis conditions.
  • Identifying dominant compensating defects (e.g., which vacancy compensates intentional n-type doping).
  • Predicting whether a defect acts as a trap, recombination center, or dopant.
  • Generating DFT reference data for defect-containing structures for ML potential training.
  • Cross-referencing with photoluminescence (PL), EPR, deep-level transient spectroscopy (DLTS), or Hall-effect measurements.
  • Screening defect tolerance in candidate photovoltaic, thermoelectric, or solid-electrolyte materials.

When Not to Use This Skill

  • Extended defects (dislocations, grain boundaries, stacking faults) — these require larger simulation cells and different analysis methods; point-defect formalism does not apply.
  • Metallic hosts — defect formation energy formalism is designed for semiconductors and insulators. In metals, there is no band gap and no well-defined Fermi-level thermodynamics; use simpler vacancy formation energy calculations instead.
  • Highly disordered or amorphous materials — point defect concepts assume a well-defined reference crystal; ensemble approaches over many configurations are needed for disordered hosts.
  • Strongly correlated hosts (Mott insulators) without DFT+U or hybrid — PBE defect levels in NiO, CoO, VO₂, and similar materials are qualitatively wrong without a Hubbard correction or hybrid functional.
  • Defect concentrations at very high temperature — harmonic approximation for defect entropy breaks down; anharmonic vibrational entropy corrections become important above ~0.5 T_melt. [EXPERT REVIEW NEEDED]
  • Surface or interface defects — these combine defect and surface physics; use this skill alongside the DFT Surfaces skill; the correction schemes differ significantly.

Core Concepts

Defect Types

  • Vacancy (V_X): One atom of species X removed from a lattice site. Notation: V_Ga, V_O. Most common intrinsic defect.
  • Interstitial (X_i): Extra atom inserted at a non-lattice position. Notation: O_i, H_i. High-energy in dense-packed structures; common in open frameworks and along diffusion channels.
  • Antisite (X_Y): Atom of species X on a site normally occupied by species Y. Notation: As_Ga (As on Ga site in GaAs). Common in compound semiconductors and oxides.
  • Substitutional (X_Y): Impurity atom X on a host lattice site Y. Notation: N_O (N on O site), Si_Ga. The primary form of intentional doping.
  • Complex defect: Two or more point defects in close proximity, bound by elastic or electrostatic attraction. Notation: (V_Ga–V_As), (V_O–Ti_Li). Can have lower formation energy than the sum of isolated defects and drastically alter transport and optical properties.

Supercell Size and Finite-Size Effects

For a charged defect in a supercell of linear dimension L:

  • The dominant finite-size error scales as q²/(εL) for the electrostatic energy.
  • Elastic relaxation errors scale as ~1/L³.
  • Convergence criterion: surface energy of the relaxed defect changes by < 0.05 eV when doubling supercell volume. [EXPERT REVIEW NEEDED: the 0.05 eV threshold is a practical rule; some properties require tighter convergence]

Typical supercell sizes: 2×2×2 (64 atoms for 4-atom cell), 3×3×3 (108–216 atoms), or 4×4×4 (256–512 atoms). Larger supercells are preferred for:

  • High charge states (|q| ≥ 2)
  • Materials with low dielectric constants (ε < 5)
  • Soft lattices with long-range elastic relaxation

For non-cubic systems, use a supercell that is approximately cubic (aspect ratio < 2 in all directions) to minimize anisotropic image interactions.

Potential Alignment

Before computing E_f, the electrostatic potential of the defect supercell must be aligned with the perfect bulk supercell. This removes the arbitrary reference of the electrostatic zero. The standard procedure (FNV alignment):

  1. Compute the planar-averaged electrostatic potential V_defect(r) and V_bulk(r)
  2. In a region far from the defect (where the defect perturbation has decayed), compute ΔV = ⟨V_defect(r)⟩_far − ⟨V_bulk(r)⟩_far
  3. Apply the alignment: shift E_VBM by ΔV

The far-field region should be identified by where |V_defect(r) − V_bulk(r) − q × V_model(r)| is minimized. The doped package automates this using the pymatgen DefectEntry infrastructure.

Dielectric Tensor

All image-charge corrections require the total (ionic + electronic) static dielectric tensor ε_total = ε_ionic + ε_electronic. For isotropic materials, a scalar ε suffices. For anisotropic materials (hexagonal, tetragonal, orthorhombic), the full 3×3 tensor is needed.

In VASP: run a separate DFPT calculation on the perfect bulk unit cell with LEPSILON=True (electronic + ionic contributions) or IBRION=8 (ionic contribution from finite differences). The dielectric tensor appears in OUTCAR as "MACROSCOPIC STATIC DIELECTRIC TENSOR IONIC CONTRIBUTION" and "MACROSCOPIC STATIC DIELECTRIC TENSOR (including local field effects in DFT)".

Spin Polarization and Localized States

Many defects carry unpaired electrons and require spin-polarized calculations (ISPIN=2). Missing spin polarization can:

  • Artificially stabilize incorrect ground states (e.g., V_O in TiO₂ has a spin-1 ground state in some charge states)
  • Incorrectly predict whether a defect is in the gap or resonant with the bands
  • Give wrong total energies by several tenths of an eV

Always initialize with non-zero MAGMOM for transition-metal-containing hosts and for all defect charge states that could be magnetic. Run with LORBIT=11 to extract atom-projected DOS and verify localization of the defect state.

Symmetry Breaking and Metastable Configurations

DFT geometry optimization can get trapped in a local minimum if the initial defect geometry has artificially high symmetry. For example, a vacancy in a Jahn-Teller-active system (e.g., V_N in GaN in certain charge states) must break symmetry to find the true ground state. The shakenbreak package addresses this by generating a set of symmetry-broken starting geometries (via atomic displacements) and running all of them; the lowest-energy relaxed structure is the ground state.

Failure to break symmetry can produce formation energies that are 0.1–0.5 eV too high and incorrect transition-level positions. This is one of the most commonly overlooked errors in defect calculations. [EXPERT REVIEW NEEDED: the magnitude of symmetry-breaking errors is highly material-specific; for some systems it can exceed 1 eV]

Key Workflows

Full steps for each part are in references/key-workflows/; open the one you need:

Common Failure Modes

Failure ModeSymptomsLikely CauseDiagnosticFix
Supercell too smallFormation energy changes by > 0.1 eV when doubling supercell size; correction term is > 30% of total formation energyImage-charge interactions dominate; strain not decayedRun two supercell sizes; check that E_corr < 0.3 × E_fUse larger supercell: min 128 atoms for
Wrong charge correction schemeFormation energies inconsistent between q and q+1 at a transition level; kink in E_f vs E_F plotMP correction for non-cubic supercell; FNV misalignment; wrong dielectricCompare MP vs FNV corrections; plot potential alignment curvesUse FNV (Freysoldt) with full LOCPOT alignment; use KO for anisotropic ε
Unconverged potential alignmentFNV ΔV not flat in the far-field region; potential continues to oscillate far from defectDefect charge delocalizes to supercell boundary; supercell too small for alignment regionPlot V_defect - V_bulk - q×V_model vs position; check flatness > 4 Å from defectIncrease supercell; check that LOCPOT was written (LVTOT=True)
Missing spin polarizationFormation energy wrong by 0.1–1 eV; DOS shows metallic character for insulating defectISPIN=1; no MAGMOM initialization; wrong spin state for complex defectRe-run with ISPIN=2, MAGMOM initialized; check NUPDOWN for fixed-spin testAlways use ISPIN=2 for all defect charge states; initialize MAGMOM per species
Artificial symmetry (no SnB)Ground state energy 0.1–0.5 eV too high; incorrect transition level positions; DFT finds saddle pointHigh-symmetry initial geometry prevents Jahn-Teller distortionCompare energy with shakenbreak distorted runs; check if lowest-symmetry config is lowerRun shakenbreak for all defects; never use only the symmetric initial geometry
ISIF=3 applied to defect supercellCell volume changes upon relaxation; defect concentration depends on cell size; non-comparable to bulkVariable-cell relaxation used; DFT minimizes artificial stressCheck ISIF in INCAR; cell should match bulkSet ISIF=2 for all defect supercell calculations
Wrong chemical potential referenceFormation energies off by 0.5–2 eV; wrong stability windowμ_i referenced to wrong DFT total energy; competing phase not includedCross-check μ_i values against ΔH_f of host and all competing phasesUse consistent DFT functional + POTCAR across all reference calculations; include all competing phases in μ space
GGA band-gap error uncorrectedTransition levels 0.5–2 eV off from experiment; levels appear above CBM that should be in gapBand gap underestimated; VBM/CBM shiftedCompare DFT gap to experimental; apply Lany-Zunger or HSE06 correctionApply scissor correction; run HSE06 single-point; always report DFT gap alongside results
Defect state resonant with bandsCharged defect has electrons/holes delocalized into band; formation energy unphysicalShallow defect or wrong charge state in a too-small gapCheck PDOS of defect supercell; look for localized state in gapUse HSE06 if bands are not correctly positioned; check charge state stability
k-mesh not convergedEnergy oscillates with k-point sampling; adsorption-like energy noiseToo few k-points for metallic-like defect stateConvergence test: Γ-only vs 2×2×2 vs 4×4×4; check for metallic PDOS at defectUse Γ-only only for large supercells (> 100 atoms) confirmed insulating
Comparing non-equivalent supercellsFormation energies inconsistent between defect and bulkDifferent supercell sizes, shapes, or POTCAR versions usedCross-check atom count, cell vectors, POTCAR SHAAlways use identical supercell (same transformation matrix from same bulk cell)
Missing competing phasesChemical potential region appears wider than physicalNot all stable phases in the phase diagram includedCheck Materials Project or ICSD for known binary/ternary phases in the composition spaceRun DFT for all relevant competing phases; use ChemicalPotentialDiagram from pymatgen/doped
LREAL=Auto for final energiesSystematic force errors ~1 meV/Å; affects transition level positions slightlyReal-space projection for large supercells adds basis errorCheck LREAL in INCAR; compare energy from LREAL=Auto vs LREAL=False single-pointUse LREAL=False for all final single-point energy calculations

Best Practices

Supercell construction:

  • Always use the same bulk unit cell (same POTCAR, same lattice constant) for all defect calculations and the reference bulk calculation. A single inconsistent POTCAR version can introduce an error of several tenths of an eV.
  • Construct supercells by a transformation matrix applied to the primitive cell, not by manually scaling; this ensures the defect-image distance is isotropic.
  • For charged defects (|q| ≥ 2) in low-dielectric materials (ε < 10), use at least a 3×3×3 supercell of the conventional cell.
  • Always compute the perfect bulk supercell using exactly the same ENCUT, KPOINTS, and POTCAR as the defect supercells.

INCAR for defect supercells:

  • ISMEAR=0 with SIGMA=0.05 for all semiconductors and insulators. Never use ISMEAR=1 or ISMEAR=2 for semiconductors — incorrect occupation of gap states.
  • ISPIN=2 with MAGMOM initialized to non-zero values for all atoms (even non-magnetic elements if the defect introduces a local moment).
  • ALGO=Normal (Davidson); ALGO=Fast can miss some spin-state crossings.
  • ISIF=2: relax atoms only; never relax the cell for defect calculations.
  • NELM=200 or higher; defect supercells can require many SCF iterations.
  • LVTOT=True for all charged defect calculations (required for FNV potential alignment).

Correction and alignment:

  • Never report charged defect formation energies without an image-charge correction. Even the Makov-Payne correction is better than no correction.
  • Always plot the LOCPOT alignment curves to verify that the far-field region is flat. A non-flat alignment indicates either a too-small supercell or a delocalized defect state.
  • Use the full dielectric tensor (not a scalar average) for KO correction in anisotropic materials.
  • Report which correction scheme was used and its magnitude relative to the total formation energy.

Chemical potentials:

  • Always compute ΔH_f for the host and all competing phases with the same POTCAR and functional as the defect calculations. Mixing DFT+U energies with PBE energies for chemical potentials introduces systematic errors.
  • For oxides with GGA+U: use VASP-recommended U values consistently for both host and competing phases, or apply the Materials Project mixing scheme.
  • Always show the chemical potential stability diagram alongside formation energy diagrams; it defines the accessible synthesis window.

Symmetry breaking:

  • For all defects in materials with partially filled d or f shells (transition metals, rare earths) and all vacancies in compound semiconductors, run shakenbreak before relying on any single starting geometry.
  • Keep all distorted geometry outputs, even those that did not find the global minimum; they document the energy landscape.

Reporting:

  • State: supercell size (atoms), correction scheme, dielectric tensor used, chemical potential limits, DFT functional, band gap (DFT and experimental/reference), whether band-gap correction was applied and how.
  • Show formation energy diagrams for at least two chemical potential limits (element-rich and element-poor).
  • Always plot potential alignment curves in a supplement or verification section.

Integration with Other Skills

Upstream (required before defect calculations):

  • VASP Workflow — bulk relaxation (ISIF=3) provides the reference lattice constant, POTCAR, and bulk energy. All VASP job submission, INCAR patterns, and convergence checking protocols apply to defect supercell calculations.
  • DFT Convergence — ENCUT and k-mesh convergence from the bulk skill carry over directly. EDIFF=1e-6 for relaxation, 1e-8 for single-points. The force threshold EDIFFG=-0.02 eV/Å is standard for defect relaxation.
  • Quantum ESPRESSO Workflow — QE can be used as an alternative DFT backend for defect calculations; ph.x with epsil=.true. provides the dielectric tensor. Post-processing corrections via pydeft or equivalent tools.
  • Pymatgen Analysis — DefectGenerator, ChemicalPotentialDiagram, DefectThermodynamics (via doped), structure manipulation, OUTCAR parsing, and POSCAR generation for all defect structures. Phase diagram construction and competing-phase enumeration.
  • ASE Framework — structure manipulation, extxyz dataset generation for MLP training (Workflow 8), and MLP calculator evaluation on defect structures.

Closely related DFT skills:

  • DFT Phonons — defect-induced local vibrational modes (LVM) require phonon calculations on defect supercells. The same supercell and INCAR discipline (LREAL=False, EDIFF=1e-8) apply. LVM frequencies are used to identify defect species in HREELS and IR.
  • DFT Surfaces — surface defects (vacancies, substitutions at surface sites) combine surface slab methodology with point defect formalism. Charge corrections are modified for slab geometry; see the Kumagai-Oba slab correction extension.
  • DFT Dataset Generation — defect supercells and their relaxation trajectories are valuable training structures for MLPs. Workflow 8 in this skill generates an extxyz dataset compatible with DFT dataset generation pipelines.
  • High-Throughput DFT — automated defect workflows at scale (screening defects across many host materials) use FireWorks/AiiDA task management with the doped/pydefect infrastructure. [FORWARD REFERENCE — skill not yet created]

Downstream consumers:

  • MLP Validation — defect formation energies from MLP vs DFT are a key validation metric for potentials targeting ionic conductors, radiation damage, or defect-sensitive functional materials.
  • Scientific Visualization — formation energy diagrams, transition level plots, chemical potential stability diagrams, and Fermi-level dependent concentration plots are the standard outputs of defect thermodynamics analysis.
  • Reproducibility Workflow — defect calculations involve many coupled files (bulk POSCAR, supercell POSCARs per defect/charge, dielectric OUTCAR, LOCPOT files for alignment, chemical potential inputs). All must be archived with clear provenance chains.
  • Materials Databases Access — competing phase energies, dielectric constants, and reference defect data can be cross-checked against the Materials Project, AFLOW, or Alexandria databases; chemical potential limits can be constructed from database entries when local DFT calculations are unavailable. [FORWARD REFERENCE — skill may be in progress]

Key References

  1. Freysoldt, C., Neugebauer, J. & Van de Walle, C. G. (2009). "Fully ab initio finite-size corrections for charged-defect supercell calculations." Physical Review Letters 102, 016402. The FNV correction scheme; must be cited when using FNV corrections.
  2. Kumagai, Y. & Oba, F. (2014). "Electrostatics-based finite-size corrections for first-principles point defect calculations." Physical Review B 89, 195205. The Kumagai-Oba correction for anisotropic dielectrics; required for layered or hexagonal materials.
  3. Van de Walle, C. G. & Neugebauer, J. (2004). "First-principles calculations for defects and impurities: Applications to III-nitrides." Journal of Applied Physics 95, 3851. Comprehensive review of defect formation energy formalism; the primary reference for the formalism.
  4. Lany, S. & Zunger, A. (2008). "Assessment of correction methods for the band-gap problem and for finite-size effects in supercell defect calculations: Case studies for ZnO and GaAs." Physical Review B 78, 235104. The Lany-Zunger band-gap and finite-size correction scheme.
  5. Mosquera-Lois, I., Kavanagh, S. R., Walsh, A. & Scanlon, D. O. (2023). "Identifying the ground state structures of point defects in solids." npj Computational Materials 9, 25. The SnB (shakenbreak) methodology for symmetry breaking; cite when using shakenbreak.
  6. Kavanagh, S. R. (2024). "doped: Python toolkit for robust and reproducible charged defect supercell calculations." Journal of Open Source Software 9, 6433. The doped package; must be cited when using doped for automated defect workflows.
  7. Makov, G. & Payne, M. C. (1995). "Periodic boundary conditions in ab initio calculations." Physical Review B 51, 4014. The Makov-Payne first-order electrostatic correction.
  8. Freysoldt, C., Grabowski, B., Hickel, T., Neugebauer, J., Kresse, G., Janotti, A. & Van de Walle, C. G. (2014). "First-principles calculations for point defects in solids." Reviews of Modern Physics 86, 253. Comprehensive review of the field; the standard reference for the entire defect calculation workflow.

[EXPERT REVIEW NEEDED: The FNV vs Kumagai-Oba correction choice for moderately anisotropic materials (e.g., tetragonal perovskites with 10–20% anisotropy) is not always clear-cut. Verify the dielectric anisotropy threshold above which KO is necessary. Also verify that the ISPIN=2 requirement applies uniformly to all closed-shell defects (e.g., V_O^{+2} in closed-shell MgO) or only to open-shell charge states.]

示例提示词

帮我计算这种氧化物中氧空位的带电缺陷形成能并做尺寸修正。

所属插件

计算材料学:第一性原理与原子模拟面向计算材料研究:DFT 与第一性原理(VASP、Quantum ESPRESSO、CP2K、AiiDA)、缺陷/表面/声子/弹性常数、机器学习势函数训练与验证、分子动力学与增强采样、晶体性质图神经网络与生成模型。

安装该插件会一并获得同领域的 35 个 Skill / MCP。

同插件的其他科研 Skill

常见问题

点缺陷第一性原理计算能做什么?

Covers first-principles point-defect modeling: vacancy/interstitial/antisite/substitutional construction, charge-state calculations. Use for defect thermodynamics studies。

如何安装点缺陷第一性原理计算?

在科搭 Codar 左侧点击「插件」,在「组件」页签搜索「点缺陷第一性原理计算」并安装;在 Claude Code 或 Codex 中可以发送本页的安装提示词,或下载 Skill 包后解压到 ~/.claude/skills 或 ~/.codex/skills。

点缺陷第一性原理计算需要哪些权限?

该科研 Skill没有声明额外权限;执行具体操作时仍由 Agent 按自身规则请求确认。

点缺陷第一性原理计算经过官方审核吗?

是。SpeedSkills 收录的每个版本都会记录内容摘要与权限声明,当前版本已通过安全审核。