oqp.analysis.density_diff

Attachment / detachment densities for MRSF excited states (unrelaxed).

Given two roots ``i`` (reference state, default S0) and ``n``, the difference
density is ``Delta = gamma^n - gamma^i``.  Because both state 1-RDMs share the
same high-spin reference, the reference cancels and
``Delta = Delta gamma^n - Delta gamma^i`` (the two exposed traceless diagonal
blocks).  Diagonalizing the symmetric ``Delta`` (in the orthonormal MO basis)
and splitting by eigenvalue sign yields the detachment (negative) and
attachment (positive) densities of Head-Gordon et al.

Functions

attachment_detachment(states, n[, ref])

Module Contents

attachment_detachment(states, n, ref=0)
Unrelaxed attachment/detachment analysis for the ref -> n transition.

Returns A, D (AO-basis density matrices), the natural orbitals/occupations,
and the promotion number n_promoted = Tr(A) = Tr(D).