19 dbcsr_csr_dbcsr_blkrow_dist, dbcsr_csr_destroy, dbcsr_csr_type, dbcsr_csr_write, &
49#include "./base/base_uses.f90"
55 CHARACTER(len=*),
PARAMETER,
PRIVATE :: moduleN =
'pao_io'
65 REAL(
dp),
DIMENSION(:, :),
ALLOCATABLE :: p
69 CHARACTER(LEN=default_string_length) :: name =
""
71 CHARACTER(LEN=default_string_length) :: prim_basis_name =
""
72 INTEGER :: prim_basis_size = -1
73 INTEGER :: pao_basis_size = -1
74 INTEGER :: nparams = -1
78 INTEGER,
PARAMETER,
PRIVATE :: file_format_version = 4
91 REAL(kind=
dp),
PARAMETER :: eps_cell = 1.0e-10_dp, &
94 CHARACTER(LEN=default_string_length) :: param
95 INTEGER :: iatom, ikind, natoms
96 INTEGER,
ALLOCATABLE,
DIMENSION(:) :: atom2kind
97 INTEGER,
DIMENSION(:),
POINTER :: col_blk_sizes, row_blk_sizes
100 REAL(
dp),
ALLOCATABLE,
DIMENSION(:, :) :: hmat, positions
101 REAL(
dp),
DIMENSION(:, :),
POINTER :: block_x, buffer
108 cpassert(len_trim(pao%restart_file) > 0)
109 IF (pao%iw > 0)
WRITE (pao%iw,
'(A,A)')
" PAO| Reading matrix_X from restart file: ", trim(pao%restart_file)
115 particle_set=particle_set)
118 IF (para_env%is_source())
THEN
119 CALL pao_read_raw(pao%restart_file, param, hmat,
kinds, atom2kind, positions, xblocks)
122 IF (maxval(abs(hmat - cell%hmat)) > eps_cell)
THEN
123 cpwarn(
"Restarting from different cell")
127 IF (trim(param) /= trim(adjustl(
id2str(pao%parameterization))))
THEN
128 cpabort(
"Restart PAO parametrization does not match")
132 DO ikind = 1,
SIZE(
kinds)
137 IF (
SIZE(positions, 1) /= natoms)
THEN
138 cpabort(
"Number of atoms do not match")
143 IF (atom2kind(iatom) /= particle_set(iatom)%atomic_kind%kind_number)
THEN
144 cpabort(
"Restart atomic kinds do not match.")
151 diff = max(diff, maxval(abs(positions(iatom, :) - particle_set(iatom)%r)))
153 cpwarn_if(diff > eps_pos,
"Restarting from different atom positions")
159 CALL dbcsr_get_info(pao%matrix_X, row_blk_size=row_blk_sizes, col_blk_size=col_blk_sizes)
161 ALLOCATE (buffer(row_blk_sizes(iatom), col_blk_sizes(iatom)))
162 IF (para_env%is_source())
THEN
163 cpassert(row_blk_sizes(iatom) ==
SIZE(xblocks(iatom)%p, 1))
164 cpassert(col_blk_sizes(iatom) ==
SIZE(xblocks(iatom)%p, 2))
165 buffer = xblocks(iatom)%p
167 CALL para_env%bcast(buffer)
168 CALL dbcsr_get_block_p(matrix=pao%matrix_X, row=iatom, col=iatom, block=block_x, found=found)
169 IF (
ASSOCIATED(block_x))
THEN
190 SUBROUTINE pao_read_raw(filename, param, hmat, kinds, atom2kind, positions, xblocks, ml_range)
191 CHARACTER(LEN=default_path_length),
INTENT(IN) :: filename
192 CHARACTER(LEN=default_string_length),
INTENT(OUT) :: param
193 REAL(
dp),
ALLOCATABLE,
DIMENSION(:, :) :: hmat
195 INTEGER,
ALLOCATABLE,
DIMENSION(:) :: atom2kind
196 REAL(
dp),
ALLOCATABLE,
DIMENSION(:, :) :: positions
198 INTEGER,
DIMENSION(2),
INTENT(OUT),
OPTIONAL :: ml_range
200 CHARACTER(LEN=default_string_length) :: label, str_in
201 INTEGER :: i1, i2, iatom, ikind, ipot, natoms, &
202 nkinds, nparams, unit_nr, xblocks_read
204 REAL(
dp),
DIMENSION(3) :: pos_in
205 REAL(
dp),
DIMENSION(3, 3) :: hmat_angstrom
207 cpassert(.NOT.
ALLOCATED(hmat))
208 cpassert(.NOT.
ALLOCATED(
kinds))
209 cpassert(.NOT.
ALLOCATED(atom2kind))
210 cpassert(.NOT.
ALLOCATED(positions))
211 cpassert(.NOT.
ALLOCATED(xblocks))
217 CALL open_file(file_name=filename, file_status=
"OLD", file_form=
"FORMATTED", &
218 file_action=
"READ", unit_number=unit_nr)
221 READ (unit_nr, fmt=*) label, i1
222 IF (trim(label) /=
"Version")
THEN
223 cpabort(
"PAO restart file appears to be corrupted.")
225 IF (i1 /= file_format_version) cpabort(
"Restart PAO file format version is wrong")
228 READ (unit_nr, fmt=*) label
231 IF (trim(label) ==
"Parametrization")
THEN
232 READ (unit_nr, fmt=*) label, str_in
235 ELSE IF (trim(label) ==
"Cell")
THEN
236 READ (unit_nr, fmt=*) label, hmat_angstrom
237 ALLOCATE (hmat(3, 3))
238 hmat(:, :) = hmat_angstrom(:, :)/
angstrom
240 ELSE IF (trim(label) ==
"Nkinds")
THEN
241 READ (unit_nr, fmt=*) label, nkinds
242 ALLOCATE (
kinds(nkinds))
244 ELSE IF (trim(label) ==
"Kind")
THEN
245 READ (unit_nr, fmt=*) label, ikind, str_in, i1
246 cpassert(
ALLOCATED(
kinds))
247 kinds(ikind)%name = str_in
250 ELSE IF (trim(label) ==
"PrimBasis")
THEN
251 READ (unit_nr, fmt=*) label, ikind, i1, str_in
252 cpassert(
ALLOCATED(
kinds))
253 kinds(ikind)%prim_basis_size = i1
254 kinds(ikind)%prim_basis_name = str_in
256 ELSE IF (trim(label) ==
"PaoBasis")
THEN
257 READ (unit_nr, fmt=*) label, ikind, i1
258 cpassert(
ALLOCATED(
kinds))
259 kinds(ikind)%pao_basis_size = i1
261 ELSE IF (trim(label) ==
"NPaoPotentials")
THEN
262 READ (unit_nr, fmt=*) label, ikind, i1
263 cpassert(
ALLOCATED(
kinds))
264 ALLOCATE (
kinds(ikind)%pao_potentials(i1))
266 ELSE IF (trim(label) ==
"PaoPotential")
THEN
267 READ (unit_nr, fmt=*) label, ikind, ipot, i1, i2, r1, r2
268 cpassert(
ALLOCATED(
kinds(ikind)%pao_potentials))
269 kinds(ikind)%pao_potentials(ipot)%maxl = i1
270 kinds(ikind)%pao_potentials(ipot)%max_projector = i2
271 kinds(ikind)%pao_potentials(ipot)%beta = r1
272 kinds(ikind)%pao_potentials(ipot)%weight = r2
274 ELSE IF (trim(label) ==
"NParams")
THEN
275 READ (unit_nr, fmt=*) label, ikind, i1
276 cpassert(
ALLOCATED(
kinds))
277 kinds(ikind)%nparams = i1
279 ELSE IF (trim(label) ==
"Natoms")
THEN
280 READ (unit_nr, fmt=*) label, natoms
281 ALLOCATE (positions(natoms, 3), atom2kind(natoms), xblocks(natoms))
282 positions = 0.0_dp; atom2kind = -1
283 IF (
PRESENT(ml_range)) ml_range = [1, natoms]
285 ELSE IF (trim(label) ==
"MLRange")
THEN
289 READ (unit_nr, fmt=*) label, i1, i2
290 IF (
PRESENT(ml_range)) ml_range = [i1, i2]
292 ELSE IF (trim(label) ==
"Atom")
THEN
293 READ (unit_nr, fmt=*) label, iatom, str_in, pos_in
294 cpassert(
ALLOCATED(
kinds))
296 IF (trim(
kinds(ikind)%name) == trim(str_in))
EXIT
298 cpassert(
ALLOCATED(atom2kind) .AND.
ALLOCATED(positions))
299 atom2kind(iatom) = ikind
300 positions(iatom, :) = pos_in/
angstrom
302 ELSE IF (trim(label) ==
"Xblock")
THEN
303 READ (unit_nr, fmt=*) label, iatom
304 cpassert(
ALLOCATED(
kinds) .AND.
ALLOCATED(atom2kind))
305 ikind = atom2kind(iatom)
306 nparams =
kinds(ikind)%nparams
307 cpassert(nparams >= 0)
308 ALLOCATE (xblocks(iatom)%p(nparams, 1))
310 READ (unit_nr, fmt=*) label, iatom, xblocks(iatom)%p
311 xblocks_read = xblocks_read + 1
312 cpassert(iatom == xblocks_read)
314 ELSE IF (trim(label) ==
"THE_END")
THEN
318 READ (unit_nr, fmt=*) label
323 cpassert(xblocks_read == natoms)
337 INTEGER,
INTENT(IN) :: ikind
340 CHARACTER(LEN=default_string_length) :: name
341 INTEGER :: ipot, nparams, pao_basis_size, z
345 TYPE(
qs_kind_type),
DIMENSION(:),
POINTER :: qs_kind_set
348 atomic_kind_set=atomic_kind_set, &
349 qs_kind_set=qs_kind_set)
351 IF (ikind >
SIZE(atomic_kind_set) .OR. ikind >
SIZE(qs_kind_set))
THEN
352 cpabort(
"Some kinds are missing.")
357 basis_set=basis_set, &
358 pao_basis_size=pao_basis_size, &
362 IF (pao_kind%nparams /= nparams)
THEN
363 cpabort(
"Number of parameters do not match")
365 IF (trim(pao_kind%name) /= trim(name))
THEN
366 cpabort(
"Kind names do not match")
368 IF (pao_kind%z /= z)
THEN
369 cpabort(
"Atomic numbers do not match")
371 IF (trim(pao_kind%prim_basis_name) /= trim(basis_set%name))
THEN
372 cpabort(
"Primary Basis-set name does not match")
374 IF (pao_kind%prim_basis_size /= basis_set%nsgf)
THEN
375 cpabort(
"Primary Basis-set size does not match")
377 IF (pao_kind%pao_basis_size /= pao_basis_size)
THEN
378 cpabort(
"PAO basis size does not match")
381 cpabort(
"Number of PAO_POTENTIALS does not match")
385 IF (pao_kind%pao_potentials(ipot)%maxl /=
pao_potentials(ipot)%maxl)
THEN
386 cpabort(
"PAO_POT_MAXL does not match")
388 IF (pao_kind%pao_potentials(ipot)%max_projector /=
pao_potentials(ipot)%max_projector)
THEN
389 cpabort(
"PAO_POT_MAX_PROJECTOR does not match")
391 IF (pao_kind%pao_potentials(ipot)%beta /=
pao_potentials(ipot)%beta)
THEN
392 cpwarn(
"PAO_POT_BETA does not match")
394 IF (pao_kind%pao_potentials(ipot)%weight /=
pao_potentials(ipot)%weight)
THEN
395 cpwarn(
"PAO_POT_WEIGHT does not match")
412 CHARACTER(len=*),
PARAMETER :: printkey_section =
'DFT%LS_SCF%PAO%PRINT%RESTART', &
413 routinen =
'pao_write_restart'
415 INTEGER :: handle, unit_max, unit_nr
420 CALL timeset(routinen, handle)
423 CALL get_qs_env(qs_env, input=input, para_env=para_env)
430 file_action=
"WRITE", &
431 file_position=
"REWIND", &
432 file_status=
"UNKNOWN", &
437 CALL para_env%max(unit_max)
438 IF (unit_max > 0)
THEN
439 IF (pao%iw > 0)
WRITE (pao%iw,
'(A,A)')
" PAO| Writing restart file."
440 IF (unit_nr > 0)
THEN
441 CALL write_restart_header(pao, qs_env, energy, unit_nr)
444 CALL pao_write_diagonal_blocks(para_env, pao%matrix_X,
"Xblock", unit_nr)
449 IF (unit_nr > 0)
WRITE (unit_nr,
'(A)')
"THE_END"
452 CALL timestop(handle)
462 SUBROUTINE pao_write_diagonal_blocks(para_env, matrix, label, unit_nr)
465 CHARACTER(LEN=*),
INTENT(IN) :: label
466 INTEGER,
INTENT(IN) :: unit_nr
468 INTEGER :: iatom, natoms
469 INTEGER,
DIMENSION(:),
POINTER :: col_blk_sizes, row_blk_sizes
471 REAL(
dp),
DIMENSION(:, :),
POINTER :: local_block, mpi_buffer
474 CALL dbcsr_get_info(matrix, row_blk_size=row_blk_sizes, col_blk_size=col_blk_sizes)
475 cpassert(
SIZE(row_blk_sizes) ==
SIZE(col_blk_sizes))
476 natoms =
SIZE(row_blk_sizes)
479 ALLOCATE (mpi_buffer(row_blk_sizes(iatom), col_blk_sizes(iatom)))
480 NULLIFY (local_block)
481 CALL dbcsr_get_block_p(matrix=matrix, row=iatom, col=iatom, block=local_block, found=found)
482 IF (
ASSOCIATED(local_block))
THEN
483 IF (
SIZE(local_block) > 0)
THEN
485 mpi_buffer(:, :) = local_block(:, :)
488 mpi_buffer(:, :) = 0.0_dp
491 CALL para_env%sum(mpi_buffer)
492 IF (unit_nr > 0)
THEN
493 WRITE (unit_nr, fmt=
"(A,1X,I10,1X)", advance=
'no') label, iatom
494 WRITE (unit_nr, *) mpi_buffer
496 DEALLOCATE (mpi_buffer)
500 IF (unit_nr > 0)
FLUSH (unit_nr)
502 END SUBROUTINE pao_write_diagonal_blocks
511 SUBROUTINE write_restart_header(pao, qs_env, energy, unit_nr)
515 INTEGER,
INTENT(IN) :: unit_nr
517 CHARACTER(LEN=default_string_length) :: kindname
518 INTEGER :: iatom, ikind, ipot, nparams, &
525 TYPE(
qs_kind_type),
DIMENSION(:),
POINTER :: qs_kind_set
529 particle_set=particle_set, &
530 atomic_kind_set=atomic_kind_set, &
531 qs_kind_set=qs_kind_set)
533 WRITE (unit_nr,
"(A,5X,I0)")
"Version", file_format_version
534 WRITE (unit_nr,
"(A,5X,F20.10)")
"Energy", energy
535 WRITE (unit_nr,
"(A,5X,I0)")
"Step", pao%istep
536 WRITE (unit_nr,
"(A,5X,A)")
"Parametrization",
id2str(pao%parameterization)
539 WRITE (unit_nr,
"(A,5X,I0)")
"Nkinds",
SIZE(atomic_kind_set)
540 DO ikind = 1,
SIZE(atomic_kind_set)
543 pao_basis_size=pao_basis_size, &
547 WRITE (unit_nr,
"(A,5X,I10,1X,A,1X,I3)")
"Kind", ikind, trim(kindname), z
548 WRITE (unit_nr,
"(A,5X,I10,1X,I3)")
"NParams", ikind, nparams
549 WRITE (unit_nr,
"(A,5X,I10,1X,I10,1X,A)")
"PrimBasis", ikind, basis_set%nsgf, trim(basis_set%name)
550 WRITE (unit_nr,
"(A,5X,I10,1X,I3)")
"PaoBasis", ikind, pao_basis_size
551 WRITE (unit_nr,
"(A,5X,I10,1X,I3)")
"NPaoPotentials", ikind,
SIZE(
pao_potentials)
553 WRITE (unit_nr,
"(A,5X,I10,1X,I3)", advance=
'no')
"PaoPotential", ikind, ipot
554 WRITE (unit_nr,
"(1X,I3)", advance=
'no')
pao_potentials(ipot)%maxl
555 WRITE (unit_nr,
"(1X,I3)", advance=
'no')
pao_potentials(ipot)%max_projector
556 WRITE (unit_nr,
"(1X,F20.16)", advance=
'no')
pao_potentials(ipot)%beta
562 WRITE (unit_nr, fmt=
"(A,5X)", advance=
'no')
"Cell"
563 WRITE (unit_nr, *) cell%hmat*
angstrom
566 WRITE (unit_nr,
"(A,5X,I0)")
"Natoms",
SIZE(particle_set)
567 DO iatom = 1,
SIZE(particle_set)
568 kindname = particle_set(iatom)%atomic_kind%name
569 WRITE (unit_nr, fmt=
"(A,5X,I10,5X,A,1X)", advance=
'no')
"Atom ", iatom, trim(kindname)
570 WRITE (unit_nr, *) particle_set(iatom)%r*
angstrom
573 END SUBROUTINE write_restart_header
585 CHARACTER(len=*),
PARAMETER :: routinen =
'pao_write_ks_matrix_csr'
587 CHARACTER(LEN=default_path_length) :: file_name, fileformat
588 INTEGER :: handle, ispin, output_unit, unit_nr
589 LOGICAL :: bin, do_kpoints, do_ks_csr_write, uptr
590 REAL(kind=
dp) :: thld
592 TYPE(dbcsr_csr_type) :: ks_mat_csr
596 CALL timeset(routinen, handle)
598 NULLIFY (dft_section)
609 CALL get_qs_env(qs_env=qs_env, do_kpoints=do_kpoints)
611 IF (do_ks_csr_write .AND. (.NOT. do_kpoints))
THEN
617 fileformat =
"UNFORMATTED"
619 fileformat =
"FORMATTED"
622 DO ispin = 1,
SIZE(ls_scf_env%matrix_ks)
627 CALL dbcsr_copy(matrix_ks_nosym, ls_scf_env%matrix_ks(ispin))
633 WRITE (file_name,
'(A,I0)')
"PAO_KS_SPIN_", ispin
635 extension=
".csr", middle_name=trim(file_name), &
636 file_status=
"REPLACE", file_form=fileformat)
637 CALL dbcsr_csr_write(ks_mat_csr, unit_nr, upper_triangle=uptr, threshold=thld, binary=bin)
641 CALL dbcsr_csr_destroy(ks_mat_csr)
646 CALL timestop(handle)
660 CHARACTER(len=*),
PARAMETER :: routinen =
'pao_write_s_matrix_csr'
662 CHARACTER(LEN=default_path_length) :: file_name, fileformat
663 INTEGER :: handle, output_unit, unit_nr
664 LOGICAL :: bin, do_kpoints, do_s_csr_write, uptr
665 REAL(kind=
dp) :: thld
667 TYPE(dbcsr_csr_type) :: s_mat_csr
671 CALL timeset(routinen, handle)
673 NULLIFY (dft_section)
684 CALL get_qs_env(qs_env=qs_env, do_kpoints=do_kpoints)
686 IF (do_s_csr_write .AND. (.NOT. do_kpoints))
THEN
692 fileformat =
"UNFORMATTED"
694 fileformat =
"FORMATTED"
700 CALL dbcsr_copy(matrix_s_nosym, ls_scf_env%matrix_s)
706 WRITE (file_name,
'(A,I0)')
"PAO_S"
708 extension=
".csr", middle_name=trim(file_name), &
709 file_status=
"REPLACE", file_form=fileformat)
710 CALL dbcsr_csr_write(s_mat_csr, unit_nr, upper_triangle=uptr, threshold=thld, binary=bin)
714 CALL dbcsr_csr_destroy(s_mat_csr)
718 CALL timestop(handle)
732 CHARACTER(len=*),
PARAMETER :: routinen =
'pao_write_hcore_matrix_csr'
734 INTEGER :: handle, output_unit
735 LOGICAL :: do_h_csr_write, do_kpoints
739 mark_used(ls_scf_env)
741 CALL timeset(routinen, handle)
743 NULLIFY (dft_section)
754 CALL get_qs_env(qs_env=qs_env, do_kpoints=do_kpoints)
756 IF (do_h_csr_write .AND. (.NOT. do_kpoints))
THEN
757 CALL cp_warn(__location__,
"Writing the PAO Core Hamiltonian matrix in CSR format NYA")
760 CALL timestop(handle)
774 CHARACTER(len=*),
PARAMETER :: routinen =
'pao_write_p_matrix_csr'
776 INTEGER :: handle, output_unit
777 LOGICAL :: do_kpoints, do_p_csr_write
781 mark_used(ls_scf_env)
783 CALL timeset(routinen, handle)
785 NULLIFY (dft_section)
796 CALL get_qs_env(qs_env=qs_env, do_kpoints=do_kpoints)
798 IF (do_p_csr_write .AND. (.NOT. do_kpoints))
THEN
799 CALL cp_warn(__location__,
"Writing the PAO density matrix in CSR format NYA")
802 CALL timestop(handle)
Define the atomic kind types and their sub types.
subroutine, public get_atomic_kind(atomic_kind, fist_potential, element_symbol, name, mass, kind_number, natom, atom_list, rcov, rvdw, z, qeff, apol, cpol, mm_radius, shell, shell_active, damping)
Get attributes of an atomic kind.
Handles all functions related to the CELL.
logical function, public dbcsr_has_symmetry(matrix)
...
subroutine, public dbcsr_convert_dbcsr_to_csr(dbcsr_mat, csr_mat)
...
subroutine, public dbcsr_desymmetrize(matrix_a, matrix_b)
...
subroutine, public dbcsr_copy(matrix_b, matrix_a, name, keep_sparsity, keep_imaginary)
...
subroutine, public dbcsr_get_block_p(matrix, row, col, block, found, row_size, col_size)
...
subroutine, public dbcsr_get_info(matrix, nblkrows_total, nblkcols_total, nfullrows_total, nfullcols_total, nblkrows_local, nblkcols_local, nfullrows_local, nfullcols_local, my_prow, my_pcol, local_rows, local_cols, proc_row_dist, proc_col_dist, row_blk_size, col_blk_size, row_blk_offset, col_blk_offset, distribution, name, matrix_type, group)
...
subroutine, public dbcsr_csr_create_from_dbcsr(dbcsr_mat, csr_mat, dist_format, csr_sparsity, numnodes)
...
subroutine, public dbcsr_release(matrix)
...
Utility routines to open and close files. Tracking of preconnections.
subroutine, public open_file(file_name, file_status, file_form, file_action, file_position, file_pad, unit_number, debug, skip_get_unit_number, file_access)
Opens the requested file using a free unit number.
subroutine, public close_file(unit_number, file_status, keep_preconnection)
Close an open file given by its logical unit number. Optionally, keep the file and unit preconnected.
various routines to log and control the output. The idea is that decisions about where to log should ...
integer function, public cp_logger_get_default_io_unit(logger)
returns the unit nr for the ionode (-1 on all other processors) skips as well checks if the procs cal...
type(cp_logger_type) function, pointer, public cp_get_default_logger()
returns the default logger
routines to handle the output, The idea is to remove the decision of wheter to output and what to out...
integer function, public cp_print_key_unit_nr(logger, basis_section, print_key_path, extension, middle_name, local, log_filename, ignore_should_output, file_form, file_position, file_action, file_status, do_backup, on_file, is_new_file, mpi_io, fout)
...
subroutine, public cp_print_key_finished_output(unit_nr, logger, basis_section, print_key_path, local, ignore_should_output, on_file, mpi_io)
should be called after you finish working with a unit obtained with cp_print_key_unit_nr,...
integer, parameter, public cp_p_file
integer function, public cp_print_key_should_output(iteration_info, basis_section, print_key_path, used_print_key, first_time)
returns what should be done with the given property if btest(res,cp_p_store) then the property should...
Types needed for a linear scaling quickstep SCF run based on the density matrix.
Defines the basic variable types.
integer, parameter, public dp
integer, parameter, public default_string_length
integer, parameter, public default_path_length
Interface to the message passing library MPI.
Routines for reading and writing restart files.
subroutine, public pao_write_p_matrix_csr(qs_env, ls_scf_env)
writing the density matrix (NYA)
subroutine, public pao_write_hcore_matrix_csr(qs_env, ls_scf_env)
writing the core Hamiltonian matrix (NYA)
subroutine, public pao_kinds_ensure_equal(pao, qs_env, ikind, pao_kind)
Ensure that the kind read from the restart is equal to the kind curretly in use.
subroutine, public pao_write_restart(pao, qs_env, energy)
Writes restart file.
subroutine, public pao_write_ks_matrix_csr(qs_env, ls_scf_env)
writing the KS matrix (in terms of the PAO basis) in csr format into a file
subroutine, public pao_read_raw(filename, param, hmat, kinds, atom2kind, positions, xblocks, ml_range)
Reads a restart file into temporary datastructures.
subroutine, public pao_write_s_matrix_csr(qs_env, ls_scf_env)
writing the overlap matrix (in terms of the PAO basis) in csr format into a file
subroutine, public pao_read_restart(pao, qs_env)
Reads restart file.
Front-End for any PAO parametrization.
subroutine, public pao_param_count(pao, qs_env, ikind, nparams)
Returns the number of parameters for given atomic kind.
Factory routines for potentials used e.g. by pao_param_exp and pao_ml.
Types used by the PAO machinery.
Define the data structure for the particle information.
Definition of physical constants:
real(kind=dp), parameter, public angstrom
subroutine, public get_qs_env(qs_env, atomic_kind_set, qs_kind_set, cell, super_cell, cell_ref, use_ref_cell, kpoints, dft_control, mos, sab_orb, sab_all, qmmm, qmmm_periodic, mimic, sac_ae, sac_ppl, sac_lri, sap_ppnl, sab_vdw, sab_scp, sap_oce, sab_lrc, sab_se, sab_xtbe, sab_tbe, sab_core, sab_xb, sab_xtb_pp, sab_xtb_nonbond, sab_almo, sab_kp, sab_kp_nosym, sab_cneo, particle_set, energy, force, matrix_h, matrix_h_im, matrix_ks, matrix_ks_im, matrix_vxc, run_rtp, rtp, matrix_h_kp, matrix_h_im_kp, matrix_ks_kp, matrix_ks_im_kp, matrix_vxc_kp, kinetic_kp, matrix_s_kp, matrix_w_kp, matrix_s_ri_aux_kp, matrix_s, matrix_s_ri_aux, matrix_w, matrix_p_mp2, matrix_p_mp2_admm, matrix_vhxc, rho, rho_xc, pw_env, ewald_env, ewald_pw, active_space, mpools, input, para_env, blacs_env, scf_control, rel_control, kinetic, qs_charges, vppl, xcint_weights, rho_core, rho_nlcc, rho_nlcc_g, ks_env, ks_qmmm_env, wf_history, scf_env, local_particles, local_molecules, distribution_2d, dbcsr_dist, molecule_kind_set, molecule_set, subsys, cp_subsys, oce, local_rho_set, rho_atom_set, task_list, task_list_soft, rho0_atom_set, rho0_mpole, rhoz_set, rhoz_cneo_set, ecoul_1c, rho0_s_rs, rho0_s_gs, rhoz_cneo_s_rs, rhoz_cneo_s_gs, do_kpoints, has_unit_metric, requires_mo_derivs, mo_derivs, mo_loc_history, nkind, natom, nelectron_total, nelectron_spin, efield, neighbor_list_id, linres_control, xas_env, virial, cp_ddapc_env, cp_ddapc_ewald, outer_scf_history, outer_scf_ihistory, x_data, et_coupling, dftb_potential, results, se_taper, se_store_int_env, se_nddo_mpole, se_nonbond_env, admm_env, lri_env, lri_density, exstate_env, ec_env, harris_env, dispersion_env, gcp_env, vee, rho_external, external_vxc, mask, mp2_env, bs_env, kg_env, wanniercentres, atprop, ls_scf_env, do_transport, transport_env, v_hartree_rspace, s_mstruct_changed, rho_changed, potential_changed, forces_up_to_date, mscfg_env, almo_scf_env, gradient_history, variable_history, embed_pot, spin_embed_pot, polar_env, mos_last_converged, eeq, rhs, do_rixs, tb_tblite)
Get the QUICKSTEP environment.
Define the quickstep kind type and their sub types.
subroutine, public get_qs_kind(qs_kind, basis_set, basis_type, ncgf, nsgf, all_potential, tnadd_potential, gth_potential, sgp_potential, upf_potential, cneo_potential, se_parameter, dftb_parameter, xtb_parameter, dftb3_param, zatom, zeff, elec_conf, mao, lmax_dftb, alpha_core_charge, ccore_charge, core_charge, core_charge_radius, paw_proj_set, paw_atom, hard_radius, hard0_radius, max_rad_local, covalent_radius, vdw_radius, gpw_type_forced, harmonics, max_iso_not0, max_s_harm, grid_atom, ngrid_ang, ngrid_rad, lmax_rho0, dft_plus_u_atom, l_of_dft_plus_u, n_of_dft_plus_u, u_minus_j, hund_j, u_of_dft_plus_u, j_of_dft_plus_u, alpha_of_dft_plus_u, beta_of_dft_plus_u, j0_of_dft_plus_u, occupation_of_dft_plus_u, dispersion, bs_occupation, magnetization, no_optimize, addel, laddel, naddel, orbitals, max_scf, eps_scf, smear, u_ramping, u_minus_j_target, eps_u_ramping, proj_shell_charge, lr_atom, do_mtlr, u_j_loop, ao_coef, init_u_ramping_each_scf, reltmat, ghost, monovalent, floating, name, element_symbol, pao_basis_size, pao_model_file, pao_potentials, pao_descriptors, nelec)
Get attributes of an atomic kind.
Provides all information about an atomic kind.
Type defining parameters related to the simulation cell.
type of a logger, at the moment it contains just a print level starting at which level it should be l...
stores all the informations relevant to an mpi environment
Holds information about a PAO potential.
Provides all information about a quickstep kind.