Loading [MathJax]/extensions/TeX/AMSsymbols.js
SIRIUS 7.5.0
Electronic structure library and applications
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
Public Member Functions | Private Attributes | List of all members
sirius::config_t::iterative_solver_t Class Reference

Parameters of the iterative solver. More...

#include <config.hpp>

Public Member Functions

 iterative_solver_t (nlohmann::json &dict__)
 
auto type () const
 Type of the iterative solver. More...
 
void type (std::string type__)
 
auto num_steps () const
 Number of steps (iterations) of the solver. More...
 
void num_steps (int num_steps__)
 
auto subspace_size () const
 Size of the variational subspace is this number times the number of bands. More...
 
void subspace_size (int subspace_size__)
 
auto locking () const
 Lock eigenvectors of the smallest eigenvalues when they have converged at restart. More...
 
void locking (bool locking__)
 
auto early_restart () const
 Restart early when the ratio unconverged vs lockable vectors drops below this threshold. More...
 
void early_restart (double early_restart__)
 
auto energy_tolerance () const
 Tolerance for the eigen-energy difference \( |\epsilon_i^{old} - \epsilon_i^{new} | \). More...
 
void energy_tolerance (double energy_tolerance__)
 
auto residual_tolerance () const
 Tolerance for the residual L2 norm. More...
 
void residual_tolerance (double residual_tolerance__)
 
auto relative_tolerance () const
 Relative tolerance for the residual L2 norm. (0 means this criterion is effectively not used. More...
 
void relative_tolerance (double relative_tolerance__)
 
auto empty_states_tolerance () const
 Additional tolerance for empty states. More...
 
void empty_states_tolerance (double empty_states_tolerance__)
 
auto converge_by_energy () const
 Defines the flavour of the iterative solver. More...
 
void converge_by_energy (int converge_by_energy__)
 
auto min_num_res () const
 Minimum number of residuals to continue iterative diagonalization process. More...
 
void min_num_res (int min_num_res__)
 
auto num_singular () const
 Number of singular components for the LAPW Davidson solver. More...
 
void num_singular (int num_singular__)
 
auto init_eval_old () const
 Initialize eigen-values with previous (old) values. More...
 
void init_eval_old (bool init_eval_old__)
 
auto init_subspace () const
 Tell how to initialize the subspace. More...
 
void init_subspace (std::string init_subspace__)
 
auto extra_ortho () const
 Orthogonalize the new subspace basis functions one more time in order to improve the numerical stability. More...
 
void extra_ortho (bool extra_ortho__)
 

Private Attributes

nlohmann::json & dict_
 

Detailed Description

Parameters of the iterative solver.

Definition at line 411 of file config.hpp.

Constructor & Destructor Documentation

◆ iterative_solver_t()

sirius::config_t::iterative_solver_t::iterative_solver_t ( nlohmann::json &  dict__)
inline

Definition at line 414 of file config.hpp.

Member Function Documentation

◆ type() [1/2]

auto sirius::config_t::iterative_solver_t::type ( ) const
inline

Type of the iterative solver.

Definition at line 419 of file config.hpp.

◆ type() [2/2]

void sirius::config_t::iterative_solver_t::type ( std::string  type__)
inline

Definition at line 423 of file config.hpp.

◆ num_steps() [1/2]

auto sirius::config_t::iterative_solver_t::num_steps ( ) const
inline

Number of steps (iterations) of the solver.

Definition at line 431 of file config.hpp.

◆ num_steps() [2/2]

void sirius::config_t::iterative_solver_t::num_steps ( int  num_steps__)
inline

Definition at line 435 of file config.hpp.

◆ subspace_size() [1/2]

auto sirius::config_t::iterative_solver_t::subspace_size ( ) const
inline

Size of the variational subspace is this number times the number of bands.

Definition at line 443 of file config.hpp.

◆ subspace_size() [2/2]

void sirius::config_t::iterative_solver_t::subspace_size ( int  subspace_size__)
inline

Definition at line 447 of file config.hpp.

◆ locking() [1/2]

auto sirius::config_t::iterative_solver_t::locking ( ) const
inline

Lock eigenvectors of the smallest eigenvalues when they have converged at restart.

Definition at line 455 of file config.hpp.

◆ locking() [2/2]

void sirius::config_t::iterative_solver_t::locking ( bool  locking__)
inline

Definition at line 459 of file config.hpp.

◆ early_restart() [1/2]

auto sirius::config_t::iterative_solver_t::early_restart ( ) const
inline

Restart early when the ratio unconverged vs lockable vectors drops below this threshold.

When there's just a few vectors left unconverged, it can be more efficient to lock the converged ones, such that the dense eigenproblem solved in each Davidson iteration has lower dimension. Restarting has some overhead in that it requires updating wave functions.

Definition at line 472 of file config.hpp.

◆ early_restart() [2/2]

void sirius::config_t::iterative_solver_t::early_restart ( double  early_restart__)
inline

Definition at line 476 of file config.hpp.

◆ energy_tolerance() [1/2]

auto sirius::config_t::iterative_solver_t::energy_tolerance ( ) const
inline

Tolerance for the eigen-energy difference \( |\epsilon_i^{old} - \epsilon_i^{new} | \).

This parameter is reduced during the SCF cycle to reach the high accuracy of the wave-functions.

Definition at line 487 of file config.hpp.

◆ energy_tolerance() [2/2]

void sirius::config_t::iterative_solver_t::energy_tolerance ( double  energy_tolerance__)
inline

Definition at line 491 of file config.hpp.

◆ residual_tolerance() [1/2]

auto sirius::config_t::iterative_solver_t::residual_tolerance ( ) const
inline

Tolerance for the residual L2 norm.

Definition at line 499 of file config.hpp.

◆ residual_tolerance() [2/2]

void sirius::config_t::iterative_solver_t::residual_tolerance ( double  residual_tolerance__)
inline

Definition at line 503 of file config.hpp.

◆ relative_tolerance() [1/2]

auto sirius::config_t::iterative_solver_t::relative_tolerance ( ) const
inline

Relative tolerance for the residual L2 norm. (0 means this criterion is effectively not used.

Definition at line 511 of file config.hpp.

◆ relative_tolerance() [2/2]

void sirius::config_t::iterative_solver_t::relative_tolerance ( double  relative_tolerance__)
inline

Definition at line 515 of file config.hpp.

◆ empty_states_tolerance() [1/2]

auto sirius::config_t::iterative_solver_t::empty_states_tolerance ( ) const
inline

Additional tolerance for empty states.

Setting this variable to 0 will treat empty states with the same tolerance as occupied states.

Definition at line 526 of file config.hpp.

◆ empty_states_tolerance() [2/2]

void sirius::config_t::iterative_solver_t::empty_states_tolerance ( double  empty_states_tolerance__)
inline

Definition at line 530 of file config.hpp.

◆ converge_by_energy() [1/2]

auto sirius::config_t::iterative_solver_t::converge_by_energy ( ) const
inline

Defines the flavour of the iterative solver.

If converge_by_energy is set to 0, then the residuals are estimated by their norm. If converge_by_energy is set to 1 then the residuals are estimated by the eigen-energy difference. This allows to estimate the unconverged residuals and then compute only the unconverged ones.

Definition at line 543 of file config.hpp.

◆ converge_by_energy() [2/2]

void sirius::config_t::iterative_solver_t::converge_by_energy ( int  converge_by_energy__)
inline

Definition at line 547 of file config.hpp.

◆ min_num_res() [1/2]

auto sirius::config_t::iterative_solver_t::min_num_res ( ) const
inline

Minimum number of residuals to continue iterative diagonalization process.

Definition at line 555 of file config.hpp.

◆ min_num_res() [2/2]

void sirius::config_t::iterative_solver_t::min_num_res ( int  min_num_res__)
inline

Definition at line 559 of file config.hpp.

◆ num_singular() [1/2]

auto sirius::config_t::iterative_solver_t::num_singular ( ) const
inline

Number of singular components for the LAPW Davidson solver.

Singular components are the eigen-vectors of the APW-APW block of overlap matrix

Definition at line 570 of file config.hpp.

◆ num_singular() [2/2]

void sirius::config_t::iterative_solver_t::num_singular ( int  num_singular__)
inline

Definition at line 574 of file config.hpp.

◆ init_eval_old() [1/2]

auto sirius::config_t::iterative_solver_t::init_eval_old ( ) const
inline

Initialize eigen-values with previous (old) values.

Definition at line 582 of file config.hpp.

◆ init_eval_old() [2/2]

void sirius::config_t::iterative_solver_t::init_eval_old ( bool  init_eval_old__)
inline

Definition at line 586 of file config.hpp.

◆ init_subspace() [1/2]

auto sirius::config_t::iterative_solver_t::init_subspace ( ) const
inline

Tell how to initialize the subspace.

It can be either 'lcao', i.e. start from the linear combination of atomic orbitals or 'random'- start from the randomized wave functions.

Definition at line 598 of file config.hpp.

◆ init_subspace() [2/2]

void sirius::config_t::iterative_solver_t::init_subspace ( std::string  init_subspace__)
inline

Definition at line 602 of file config.hpp.

◆ extra_ortho() [1/2]

auto sirius::config_t::iterative_solver_t::extra_ortho ( ) const
inline

Orthogonalize the new subspace basis functions one more time in order to improve the numerical stability.

Definition at line 610 of file config.hpp.

◆ extra_ortho() [2/2]

void sirius::config_t::iterative_solver_t::extra_ortho ( bool  extra_ortho__)
inline

Definition at line 614 of file config.hpp.

Member Data Documentation

◆ dict_

nlohmann::json& sirius::config_t::iterative_solver_t::dict_
private

Definition at line 622 of file config.hpp.


The documentation for this class was generated from the following file: