vibe-sketcherDocumentation

vibesketcher.document.defect_corrections

The point-charge image term of a charged defect in a periodic supercell (#195).

A charge q in a periodic cell interacts with its own images and with the uniform compensating background the periodic Coulomb sum implies. Relative to the isolated charge in the same dielectric medium, that costs:

E_periodic - E_isolated = (q^2 / 2) phi,

where phi is the Madelung potential at the charge site from all images and the background, without the charge’s own field. The formation energy is corrected by E_PC = -(q^2 / 2) phi. In a cubic cell of side L and a scalar dielectric constant this is the leading Leslie-Gillan/Makov-Payne term q^2 alpha / (2 eps L), alpha = 2.8373 (M. Leslie and M. J. Gillan, J. Phys. C 18, 973 (1985); G. Makov and M. C. Payne, Phys. Rev. B 51, 4014 (1995)).

For a dielectric tensor eps the Ewald sum is taken in the metric of eps (R. Rurali and X. Cartoixa, Nano Lett. (2009), doi:10.1021/nl802847p; S. T. Murphy and N. D. M. Hine, Phys. Rev. B 87, 094111 (2013); Y. Kumagai and F. Oba, Phys. Rev. B 89, 195205 (2014)):

phi = sum_{R != 0} erfc(g d_R) / (sqrt(det eps) d_R)
      + (4 pi / V) sum_{G != 0} exp(-G.eps.G / (4 g^2)) / G.eps.G
      - 2 g / sqrt(pi det eps) - pi / (V g^2),

with d_R = sqrt(R.eps^-1.R). The result does not depend on the splitting parameter g, which the tests check. This is the point-charge limit of the lattice term E_lat of C. Freysoldt, J. Neugebauer and C. G. Van de Walle, Phys. Rev. Lett. 102, 016402 (2009). Their potential-alignment term -q Delta_{q/b} needs the electrostatic potentials of the defective and pristine runs, which the sketcher does not read; it is a stated input instead.

Module Attributes

COULOMB_EV_ANGSTROM

e^2 / (4 pi eps_0) in eV angstrom, from the CODATA 2018 hartree and bohr.

MAX_TERMS

Lattice-sum terms beyond which a cell is refused rather than summed slowly.

Functions

dielectric_tensor(value)

A symmetric dielectric tensor with every eigenvalue at least 1, or a refusal.

madelung_potential(lattice_angstrom, ...[, ...])

phi in 1/angstrom: images plus compensating background, at the charge site.

point_charge_correction(lattice_angstrom, ...)

The image-charge correction -(q^2/2) phi in eV, with what it rests on.

vibesketcher.document.defect_corrections.COULOMB_EV_ANGSTROM = 14.399645478456184

e^2 / (4 pi eps_0) in eV angstrom, from the CODATA 2018 hartree and bohr.

vibesketcher.document.defect_corrections.MAX_TERMS = 4000000

Lattice-sum terms beyond which a cell is refused rather than summed slowly.

vibesketcher.document.defect_corrections.dielectric_tensor(value)[source]

A symmetric dielectric tensor with every eigenvalue at least 1, or a refusal.

Parameters:

value (float | list[list[float]])

Return type:

NDArray[float64]

vibesketcher.document.defect_corrections.madelung_potential(lattice_angstrom, dielectric, *, splitting=None)[source]

phi in 1/angstrom: images plus compensating background, at the charge site.

splitting is the Ewald parameter g in 1/angstrom of the eps metric; the default balances the real and reciprocal sums.

Parameters:
  • lattice_angstrom (Any)

  • dielectric (Any)

  • splitting (float | None)

Return type:

float

vibesketcher.document.defect_corrections.point_charge_correction(lattice_angstrom, charge, dielectric)[source]

The image-charge correction -(q^2/2) phi in eV, with what it rests on.

Parameters:
Return type:

dict[str, Any]