17 USE dbcsr_api,
ONLY: dbcsr_p_type
34 #include "./base/base_uses.f90"
40 CHARACTER(len=*),
PARAMETER,
PRIVATE :: moduleN =
'kg_environment_types'
42 PUBLIC :: kg_environment_type,
kg_env_release, energy_correction_type
45 TYPE(neighbor_list_set_p_type),
DIMENSION(:),
POINTER :: sab_orb
46 TYPE(task_list_type),
POINTER :: task_list
55 TYPE energy_correction_type
56 CHARACTER(len=20) :: ec_name
57 INTEGER :: energy_functional
59 INTEGER :: factorization
60 REAL(KIND=
dp) :: eps_default
62 CHARACTER(len=20) :: basis
64 INTEGER :: mao_max_iter
65 REAL(KIND=
dp) :: mao_eps_grad
67 REAL(KIND=
dp) :: etotal
68 REAL(KIND=
dp) :: eband, exc, ehartree, vhxc
69 REAL(KIND=
dp) :: edispersion
71 TYPE(neighbor_list_set_p_type), &
72 DIMENSION(:),
POINTER :: sab_orb, sac_ppl, sap_ppnl
73 TYPE(task_list_type),
POINTER :: task_list
75 TYPE(section_vals_type),
POINTER :: xc_section
76 TYPE(qs_dispersion_type),
POINTER :: dispersion_env
79 TYPE(dbcsr_p_type),
DIMENSION(:, :),
POINTER :: matrix_ks
80 TYPE(dbcsr_p_type),
DIMENSION(:, :),
POINTER :: matrix_h
81 TYPE(dbcsr_p_type),
DIMENSION(:, :),
POINTER :: matrix_s
82 TYPE(dbcsr_p_type),
DIMENSION(:, :),
POINTER :: matrix_t
83 TYPE(dbcsr_p_type),
DIMENSION(:, :),
POINTER :: matrix_p
85 TYPE(dbcsr_p_type),
DIMENSION(:),
POINTER :: mao_coef
86 END TYPE energy_correction_type
102 TYPE kg_environment_type
105 TYPE(section_vals_type),
POINTER :: xc_section_kg
106 INTEGER,
ALLOCATABLE,
DIMENSION(:) :: atom_to_molecule
107 TYPE(molecule_type),
DIMENSION(:),
POINTER :: molecule_set
108 INTEGER :: tnadd_method
109 TYPE(neighbor_list_set_p_type), &
110 DIMENSION(:),
POINTER :: sab_orb_full, sac_kin
112 INTEGER,
DIMENSION(:),
POINTER :: subset_of_mol
113 TYPE(subset_type),
DIMENSION(:),
POINTER :: subset
116 INTEGER :: coloring_method
118 TYPE(dbcsr_p_type),
DIMENSION(:),
POINTER :: tnadd_mat
120 TYPE(lri_environment_type),
POINTER :: lri_env, lri_env1
121 TYPE(lri_density_type),
POINTER :: lri_density, lri_rho1
123 TYPE(atom_integration_grid_type),
POINTER :: int_grid_atom
124 TYPE(integration_grid_type),
POINTER :: int_grid_molecules
125 TYPE(integration_grid_type),
POINTER :: int_grid_full
126 END TYPE kg_environment_type
135 TYPE(kg_environment_type),
POINTER :: kg_env
137 CHARACTER(LEN=*),
PARAMETER :: routinen =
'kg_env_release'
139 INTEGER :: handle, isub
141 CALL timeset(routinen, handle)
143 cpassert(
ASSOCIATED(kg_env))
148 IF (
ASSOCIATED(kg_env%tnadd_mat))
THEN
152 DO isub = 1, kg_env%nsubsets
157 IF (
ASSOCIATED(kg_env%subset_of_mol))
DEALLOCATE (kg_env%subset_of_mol)
158 IF (
ASSOCIATED(kg_env%subset))
DEALLOCATE (kg_env%subset)
160 IF (
ALLOCATED(kg_env%atom_to_molecule))
DEALLOCATE (kg_env%atom_to_molecule)
163 IF (
ASSOCIATED(kg_env%lri_env))
THEN
165 DEALLOCATE (kg_env%lri_env)
167 IF (
ASSOCIATED(kg_env%lri_density))
THEN
169 DEALLOCATE (kg_env%lri_density)
171 IF (
ASSOCIATED(kg_env%lri_env1))
THEN
173 DEALLOCATE (kg_env%lri_env1)
175 IF (
ASSOCIATED(kg_env%lri_rho1))
THEN
177 DEALLOCATE (kg_env%lri_rho1)
180 IF (
ASSOCIATED(kg_env%int_grid_atom))
THEN
183 IF (
ASSOCIATED(kg_env%int_grid_molecules))
THEN
186 IF (
ASSOCIATED(kg_env%int_grid_full))
THEN
192 CALL timestop(handle)
DBCSR operations in CP2K.
subroutine, public deallocate_intgrid(int_grid)
Deallocate integration_grid_type.
Types needed for a Kim-Gordon-like partitioning into molecular subunits.
subroutine, public kg_env_release(kg_env)
...
Defines the basic variable types.
integer, parameter, public dp
contains the types and subroutines for dealing with the lri_env lri : local resolution of the identit...
subroutine, public lri_density_release(lri_density)
releases the given lri_density
subroutine, public lri_env_release(lri_env)
releases the given lri_env
Define the data structure for the molecule information.
Definition of disperson types for DFT calculations.
subroutine, public deallocate_atom_int_grid(int_grid)
...
Define the neighbor list data types and the corresponding functionality.
subroutine, public release_neighbor_list_sets(nlists)
releases an array of neighbor_list_sets
subroutine, public deallocate_task_list(task_list)
deallocates the components and the object itself