|
| | ZeqULR (const std::vector< int > &nocc_in, const std::vector< int > &nvirt_in, const std::vector< Parallel_Blkcyclic > &pX_in, const int nk_in, const int local_dimension, const int global_dimension) |
| virtual | ~ZeqULR () |
| void | hPsi (const T *const psi_in, T *const hpsi, const int ld_psi, const int nband) |
| void | hPsi (const T *psi_in, T *hpsi, const int ld_psi, const int nband, const std::vector< std::vector< ct::Tensor > > &window_density) |
| std::vector< T > | matrix () |
| | The full (replicated) matrix, column by column. Only used by the LAPACK solver.
|
|
| void | apply (const T *const psi_in, T *const hpsi, const int ld_psi, const int nband, const std::vector< std::vector< ct::Tensor > > *window_density) |
| virtual void | set_dm (const int is, const T *const X, const std::vector< ct::Tensor > *density_add)=0 |
| | rebuild the density matrices the operators read, from the is block of X
|
| virtual void | band_extra (const T *const X, T *const out) const |
| | optional per-band contribution that does not fit the 2x2 block structure. NOTE matrix() deliberately does NOT call this: it exists for the right-hand side, which is not a linear operator, while matrix() is only ever used for the LHS.
|
template<typename
T>
class LR::ZeqULR< T >
Common skeleton of the open-shell (spin-unrestricted) Z-vector operators.
Both sides of the Z-vector equation have the same block structure as the open-shell Casida Hamiltonian HamiltULR: the vector is the concatenation [up-block | down-block] and the operator is a 2x2 array of spin blocks ops[(s_out << 1) + s_in], because every kernel action carries a free outer spin and a summed inner spin, $K_{pq\sigma}[D]=\sum_{\kappa\lambda\sigma'}K_{pq\sigma,\kappa\lambda\sigma'}D_{\kappa\lambda\sigma'}$. The exchange part is $\propto\delta_{\sigma\sigma'}$, so EXX operators only ever go on the diagonal blocks 0 and 3.
Derived classes fill ops in their constructor and implement set_dm, which rebuilds whatever density matrices the operators read from the s_in block of X.