CP2K 2.4 (Revision 12889)
Functions | Variables

qs_diis Namespace Reference

Apply the direct inversion in the iterative subspace (DIIS) of Pulay in the framework of an SCF iteration for convergence acceleration. More...

Functions

subroutine, public qs_diis_b_create (diis_buffer, nbuffer, error)
 Allocates an SCF DIIS buffer.
subroutine qs_diis_b_check_i_alloc (diis_buffer, matrix_struct, nspin, scf_section, error)
 Allocate and initialize a DIIS buffer for nao*nao parameter variables and with a buffer size of nbuffer.
subroutine, public qs_diis_b_step (diis_buffer, mo_array, kc, sc, delta, error_max, diis_step, eps_diis, nmixing, s_matrix, scf_section, roks, error)
 Update the SCF DIIS buffer, and if appropriate does a diis step.
subroutine, public qs_diis_b_clear (diis_buffer, error)
 clears the buffer

Variables

CHARACTER(len=*), parameter,
private 
moduleN = 'qs_diis'
INTEGER, save last_diis_b_id = 0

Detailed Description

Apply the direct inversion in the iterative subspace (DIIS) of Pulay in the framework of an SCF iteration for convergence acceleration.

Literature
  • P. Pulay, Chem. Phys. Lett. 73, 393 (1980)
  • P. Pulay, J. Comput. Chem. 3, 556 (1982)
History
  • Changed to BLACS matrix usage (08.06.2001,MK)
  • rewritten to include LSD (1st attempt) (01.2003, Joost VandeVondele)
  • DIIS for ROKS (05.04.06,MK)
Author:
Matthias Krack (28.06.2000)

Function Documentation

subroutine qs_diis::qs_diis_b_check_i_alloc ( TYPE(qs_diis_buffer_type),pointer  diis_buffer,
TYPE(cp_fm_struct_type),pointer  matrix_struct,
INTEGER,intent(in)  nspin,
TYPE(section_vals_type),pointer  scf_section,
TYPE(cp_error_type),intent(inout)  error 
) [private]

Allocate and initialize a DIIS buffer for nao*nao parameter variables and with a buffer size of nbuffer.

Parameters:
diis_bufferthe buffer to initialize
matrix_structthe structure for the matrix of the buffer
errorvariable to control error logging, stopping,... see module cp_error_handling
Note:
check to allocate matrixes only when needed, using a linked list?
History
  • Creation (07.05.2001, Matthias Krack)
  • Changed to BLACS matrix usage (08.06.2001,MK)
  • DIIS for ROKS (05.04.06,MK)
Author:
Matthias Krack

Definition at line 127 of file qs_diis.f90.

References cp_fm_types::cp_fm_create(), cp_output_handling::cp_print_key_finished_output(), error, and timings::timeset().

Referenced by qs_diis_b_step().

Here is the call graph for this function:

Here is the caller graph for this function:

subroutine,public qs_diis::qs_diis_b_clear ( TYPE(qs_diis_buffer_type),pointer  diis_buffer,
TYPE(cp_error_type),intent(inout)  error 
)

clears the buffer

Parameters:
diis_bufferthe buffer to clear
errorvariable to control error logging, stopping,... see module cp_error_handling
History
02.2003 created [fawzi]
Author:
fawzi

Definition at line 548 of file qs_diis.f90.

References timings::timeset().

Referenced by qs_scf::init_scf_loop(), and xas_methods::xas().

Here is the call graph for this function:

Here is the caller graph for this function:

subroutine,public qs_diis::qs_diis_b_create ( TYPE(qs_diis_buffer_type),pointer  diis_buffer,
INTEGER,intent(in)  nbuffer,
TYPE(cp_error_type),intent(inout)  error 
)

Allocates an SCF DIIS buffer.

Parameters:
diis_bufferthe buffer to create
errorvariable to control error logging, stopping,... see module cp_error_handling
History
02.2003 created [fawzi]
Author:
fawzi

Definition at line 76 of file qs_diis.f90.

References CPPostcondition, last_diis_b_id, and timings::timeset().

Here is the call graph for this function:

subroutine,public qs_diis::qs_diis_b_step ( TYPE(qs_diis_buffer_type),pointer  diis_buffer,
TYPE(mo_set_p_type),dimension(:),pointer  mo_array,
TYPE(cp_fm_p_type),dimension(:),pointer  kc,
TYPE(cp_fm_type),pointer  sc,
REAL(KIND=dp),intent(in)  delta,
REAL(KIND=dp),intent(out)  error_max,
LOGICAL,intent(out)  diis_step,
REAL(KIND=dp),intent(in)  eps_diis,
INTEGER,intent(in),optional  nmixing,
TYPE(cp_dbcsr_p_type),dimension(:),optional,pointer  s_matrix,
TYPE(section_vals_type),pointer  scf_section,
LOGICAL,intent(in),optional  roks,
TYPE(cp_error_type),intent(inout)  error 
)

Update the SCF DIIS buffer, and if appropriate does a diis step.

Parameters:
errorvariable to control error logging, stopping,... see module cp_error_handling
History
  • Creation (07.05.2001, Matthias Krack)
  • Changed to BLACS matrix usage (08.06.2001, MK)
  • 03.2003 rewamped [fawzi]
  • Adapted for high-spin ROKS (08.04.06,MK)
Author:
Matthias Krack

Definition at line 226 of file qs_diis.f90.

References string_utilities::compress(), cp_dbcsr_operations::copy_dbcsr_to_fm(), cp_fm_basic_linalg::cp_fm_column_scale(), cp_output_handling::cp_print_key_finished_output(), mathlib::diamat_all(), error, qs_mo_types::get_mo_set(), qs_diis_b_check_i_alloc(), and timings::timeset().

Referenced by qs_scf_diagonalization::do_general_diag(), qs_scf_diagonalization::do_ot_diag(), qs_scf_diagonalization::do_roks_diag(), and qs_scf_diagonalization::do_special_diag().

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

Definition at line 57 of file qs_diis.f90.

Referenced by qs_diis_b_create().

CHARACTER(len=*),parameter,private qs_diis::moduleN = 'qs_diis'

Definition at line 56 of file qs_diis.f90.