1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
//! Safe Rust wrapper for [libxc](https://www.tddft.org/programs/libxc/), the library
//! of exchange-correlation functionals for density-functional theory (DFT).
//!
//! # Overview
//!
//! This crate provides [`LibXCFunctional`], the central type that represents a
//! single DFT exchange-correlation functional. It wraps the C `xc_func_type`
//! pointer, manages its lifetime, and exposes three categories of operations:
//!
//! - **Construction** — create a functional by name or ID, with spin
//! polarization: [`from_identifier`](LibXCFunctional::from_identifier),
//! [`from_number`](LibXCFunctional::from_number) (plus `_f` fallible
//! variants).
//!
//! - **Introspection** — query identity, family (LDA/GGA/MGGA/hybrid), kind,
//! capability flags, hybrid/CAM/VV10 coefficients, auxiliary functionals, and
//! literature references.
//!
//! - **Computation** — evaluate the functional and its derivatives (up to 4th
//! order) on a grid via [`compute_xc`](LibXCFunctional::compute_xc) and
//! variants. With the `cuda` feature, GPU computation is available via
//! [`cuda_compute_xc`](LibXCFunctional::cuda_compute_xc) using functionals
//! created with
//! [`from_identifier_with_device`](LibXCFunctional::from_identifier_with_device).
// documentation exception
use *;