openfermion.hamiltonians.rhf_params_to_matrix

For restricted Hartree-Fock we have nocc * nvirt parameters.

These are provided as a list that is ordered by (virtuals) imes (occupied).

For example, for H4 we have 2 orbitals occupied and 2 virtuals

occupied = [0, 1] virtuals = [2, 3]

parameters = [(v{0}, o{0}), (v{0}, o{1}), (v{1}, o{0}), (v{1}, o{1})] = [(2, 0), (2, 1), (3, 0), (3, 1)]

You can think of the tuples of elements of the upper right triangle of the antihermitian matrix that specifies the c_{b, i} coefficients.

coefficient matrix [[ c{0, 0}, -c{1, 0}, -c{2, 0}, -c{3, 0}], [ c{1, 0}, c{1, 1}, -c{2, 1}, -c{3, 1}], [ c{2, 0}, c{2, 1}, c{2, 2}, -c{3, 2}], [ c{3, 0}, c{3, 1}, c{3, 2}, c{3, 3}]]

Since we are working with only non-redundant operators we know c{i, i} = 0 and any c{i, j} where i and j are both in occupied or both in virtual = 0.

parameters array of parameters for kappa matrix
num_orbitals total number of spatial orbitals
occ (Optional) indices for doubly occupied sector
virt (Optional) indices for virtual sector

Returns: np.ndarray kappa matrix