ffsim.contract.num_op_sum_linop¶
- ffsim.contract.num_op_sum_linop(coeffs, norb, nelec, *, orbital_rotation=None)[source]¶
Convert a (rotated) linear combination of number operators to a linear operator.
A rotated linear combination of number operators has the form
\[\mathcal{U} (\sum_{i \sigma} \lambda_i n_{i\sigma}) \mathcal{U}^\dagger\]where \(n_{i\sigma}\) denotes the number operator on orbital \(i\) with spin \(\sigma\), the \(\lambda_i\) are real numbers, and \(\mathcal{U}\) is an optional orbital rotation.
- Parameters:
- Return type:
- Returns:
A LinearOperator that implements the action of the linear combination of number operators.