Skip to content

Hybrid DFT: PBE0 exact exchange ​

The v2.x electronic-structure prototype adds PBE0 to the gated KS-DFT engine. PBE0 is PBE exchange-correlation plus 25 % exact Hartree–Fock exchange. The exact-exchange path is currently restricted to closed-shell systems.

Status. Implemented behind alpha-dft-hybrid and exposed on the Rust, Python, WASM and CLI surfaces. Range-separated hybrids, unrestricted exact exchange and the ORCA/PySCF parity gate are still pending. See the v2.x roadmap.

Feature. alpha-dft-hybrid (included in alpha-v2).

Theory ​

The hybrid exchange-correlation energy is

Exc=aExHF+(1−a)ExPBE+EcPBE,a=0.25,

with

ExHF=−14∑μνλσPμνPλσ(μλ|νσ).

The corresponding Fock matrix is

F=Hcore+J+Vxc−a2K,

where

Kμν=∑λσPλσ(μλ|νσ).

The implementation reuses the existing DFT ERI tensor and adds the exchange matrix once per SCF iteration. The semilocal PBE exchange is scaled by 1−a on the grid, so exact and semilocal exchange are never double-counted.

API ​

rust
use sci_form::dft::ks_fock::{solve_ks_dft, DftConfig, DftMethod};

let config = DftConfig {
    method: DftMethod::Pbe0,
    ..DftConfig::default()
};
let result = solve_ks_dft(&elements, &positions, &config)?;
println!("E = {} Hartree", result.total_energy);

PBE0 is available through DftMethod::Pbe0; pbe0, pbe-0 and hybrid are accepted aliases. The variant and its aliases exist only with the alpha-dft-hybrid feature, which also enables alpha-dft.

The standalone Rust/Python/WASM/CLI entry points use DftConfig::default(), i.e. the Minimal/STO-3G Kohn–Sham basis. The pKa workflow in redox and pKa is a separate path that explicitly selects the split-valence 3-21G basis.

For water at [0,0,0, 0.9572,0,0, -0.239987,0.927297,0] with max_iterations=50:

text
total_energy = -75.2454830117255 Ha
gap          = 14.522742631047386 eV
n_basis      = 7
n_electrons  = 10
scf_iterations = 6
converged    = true

The SCF result is only returned when it converged. A smaller iteration cap is an error (NotConvergedError in Python, {error} in WASM, exit code 1 in the CLI), and max_iterations must be an integer ≥ 1.

Scope ​

CapabilityStatus
Restricted closed-shell PBE0implemented
Unrestricted/open-shell PBE0returns Unsupported
Range-separated hybridsnot implemented
B3LYPnot implemented
Analytical hybrid gradientnot implemented

The current gradient path is for the pure DFT functional; PBE0 gradients are a follow-up.

Validation ​

GateObservableResult
Water PBE0 SCFConvergencepasses
Water PBE0 energyFinite and negativepasses
Electron count10 electronspasses
Unrestricted PBE0Explicit errorguarded

The important missing gate is method parity against PySCF/ORCA for the same PBE0/basis. Until that exists, the implementation is a prototype.

Bindings ​

SurfaceEntry point
CLIsci-form pbe0 <elements> <coords> [--max-iterations N]
WASMcompute_pbe0_energy(elements, coords, max_iterations), or alpha_compute_dft(elements, coords, "pbe0")
Pythoncompute_pbe0_energy(elements, coords, max_iterations=100)

All three are built only with alpha-dft-hybrid (or alpha-v2).

Limitations ​

  • The exact-exchange matrix is built with the existing O(N^4) ERI loop; no RI or Cholesky exchange yet.
  • Restricted closed-shell only.
  • PBE0 uses the existing PBE evaluator with the exchange scaled by 0.75; no B3LYP.
  • No range separation, no exact-exchange gradient and no response properties.
  • Native builds and bindings need the alpha-dft-hybrid feature.
  • No benchmark against PySCF/ORCA yet.

Next steps ​

  1. Add an unrestricted exact-exchange path.
  2. Add RI/Cholesky exact exchange for larger systems.
  3. Add range-separated hybrids.
  4. Add the analytical PBE0 gradient.
  5. Add PySCF/ORCA parity and a 20-molecule reaction-energy set.
  6. Add a 20-molecule reaction-energy benchmark.

Released under the MIT License.