qstack.spahm.rho.lowdin

Löwdin orthogonalization for density matrix partitioning.

class qstack.spahm.rho.lowdin.Lowdin_split(mol, dm)[source]

Bases: object

Löwdin orthogonalization for density matrix partitioning.

Transforms density matrix to orthogonal basis using symmetric orthogonalization, enabling clean atomic and bond partitioning of electron density.

S[source]

Overlap matrix in AO basis.

Type:

numpy ndarray

S12[source]

Square root of overlap matrix (S^{1/2}).

Type:

numpy ndarray

S12i[source]

Inverse square root of overlap matrix (S^{-1/2}).

Type:

numpy ndarray

mol[source]

pyscf Mole object.

Type:

pyscf Mole

dm[source]

Original density matrix in AO basis.

Type:

numpy ndarray

dmL[source]

Löwdin-orthogonalized density matrix.

Type:

numpy ndarray

get_bond(at1idx, at2idx)[source]

Extract bond density matrix for an atom pair.

Isolates the density matrix components corresponding to interactions between two atoms, transforming back to AO basis.

Parameters:
  • at1idx (int) – Index of first atom.

  • at2idx (int) – Index of second atom.

Returns:

Bond density matrix in AO basis (2D array).

Return type:

numpy ndarray

sqrtm(m)[source]

Compute matrix square root and inverse square root via eigendecomposition.

Parameters:

m (numpy ndarray) – Symmetric positive-definite matrix.

Returns:

(m^{1/2}, m^{-1/2}) both symmetrized.

Return type:

tuple