occ
Loading...
Searching...
No Matches
occ::qm::cphf::Solver Class Reference

#include <cphf.h>

Public Member Functions

 Solver (const MolecularOrbitals &mo, ResponseFunction G, Settings settings={})
Result solve (const std::vector< Mat > &B, const std::vector< Mat > *U0=nullptr) const
 Solve for every right-hand side B (a vo vector each).
std::vector< Mat > apply (const std::vector< Mat > &U) const
 The orbital Hessian (A + B) applied to each U; exposed for testing.
std::vector< Mat > apply (const std::vector< Mat > &U, std::vector< Mat > &G) const
 As apply, also returning the response G[D(U)] C_o.
Mat vo_block (const Mat &X) const
 C_v^s^T X C_o^s for every channel, as a vo vector (X as in contract_occupied).
Mat vo_zero () const
 A zero vo vector.
Eigen::Map< Mat > block (Mat &U, int s) const
 Channel s of a vo vector, nvirt_s x nocc_s.
Eigen::Map< const Mat > block (const Mat &U, int s) const
double occupation () const
 Electrons per orbital: 2 restricted, 1 unrestricted.
const std::vector< SpinChannel > & channels () const
const Mat & orbital_energy_differences () const
 e_a - e_i, a vo vector.

Constructor & Destructor Documentation

◆ Solver()

occ::qm::cphf::Solver::Solver ( const MolecularOrbitals & mo,
ResponseFunction G,
Settings settings = {} )

Member Function Documentation

◆ apply() [1/2]

std::vector< Mat > occ::qm::cphf::Solver::apply ( const std::vector< Mat > & U) const

The orbital Hessian (A + B) applied to each U; exposed for testing.

◆ apply() [2/2]

std::vector< Mat > occ::qm::cphf::Solver::apply ( const std::vector< Mat > & U,
std::vector< Mat > & G ) const

As apply, also returning the response G[D(U)] C_o.

◆ block() [1/2]

Eigen::Map< const Mat > occ::qm::cphf::Solver::block ( const Mat & U,
int s ) const

◆ block() [2/2]

Eigen::Map< Mat > occ::qm::cphf::Solver::block ( Mat & U,
int s ) const

Channel s of a vo vector, nvirt_s x nocc_s.

◆ channels()

const std::vector< SpinChannel > & occ::qm::cphf::Solver::channels ( ) const
inline

◆ occupation()

double occ::qm::cphf::Solver::occupation ( ) const
inline

Electrons per orbital: 2 restricted, 1 unrestricted.

A second-order property summed over vo vectors carries it, e.g. the polarisability alpha_xy = -2 occupation() vo_block(r_x) . U_y.

◆ orbital_energy_differences()

const Mat & occ::qm::cphf::Solver::orbital_energy_differences ( ) const
inline

e_a - e_i, a vo vector.

◆ solve()

Result occ::qm::cphf::Solver::solve ( const std::vector< Mat > & B,
const std::vector< Mat > * U0 = nullptr ) const

Solve for every right-hand side B (a vo vector each).

U0, if given, is the starting guess (e.g. a solution with a cheaper, approximate response).

◆ vo_block()

Mat occ::qm::cphf::Solver::vo_block ( const Mat & X) const

C_v^s^T X C_o^s for every channel, as a vo vector (X as in contract_occupied).

◆ vo_zero()

Mat occ::qm::cphf::Solver::vo_zero ( ) const

A zero vo vector.


The documentation for this class was generated from the following file:
  • /home/runner/work/occ/occ/include/occ/qm/cphf.h