Line data Source code
1 : !--------------------------------------------------------------------------------------------------!
2 : ! CP2K: A general program to perform molecular dynamics simulations !
3 : ! Copyright 2000-2026 CP2K developers group <https://cp2k.org> !
4 : ! !
5 : ! SPDX-License-Identifier: GPL-2.0-or-later !
6 : !--------------------------------------------------------------------------------------------------!
7 :
8 : ! **************************************************************************************************
9 : !> \brief function that build the print section of the dft input
10 : !> \par History
11 : !> 10.2005 moved out of input_cp2k [fawzi]
12 : !> 07.2024 moved out of input_cp2k_dft [JGH]
13 : !> \author fawzi
14 : ! **************************************************************************************************
15 : MODULE input_cp2k_print_dft
16 : USE basis_set_types, ONLY: basis_sort_default, &
17 : basis_sort_zet
18 : USE bibliography, ONLY: &
19 : Andermatt2016, Andreussi2012, Avezac2005, BaniHashemian2016, Becke1988b, Bengtsson1999, &
20 : Blochl1995, Brehm2018, Brelaz1979, Dewar1977, Dewar1985, Dudarev1997, Dudarev1998, &
21 : Ehrhardt1985, Eriksen2020, Fattebert2002, Golze2017a, Golze2017b, Guidon2010, &
22 : Heinzmann1976, Holmberg2017, Holmberg2018, Iannuzzi2005, Iannuzzi2006, Iannuzzi2007, &
23 : Knizia2013, Kolafa2004, Krack2000, Krack2002, Kuhne2007, Kunert2003, Lippert1997, &
24 : Lippert1999, Lu2004, Merlot2014, Perdew1981, Repasky2002, Rocha2006, Schenter2008, Schiffmann2015, &
25 : Shigeta2001, Stewart1982, Stewart1989, Stewart2007, Thiel1992, VanVoorhis2015, &
26 : VandeVondele2003, VandeVondele2005a, VandeVondele2005b, VandeVondele2006, Weber2008, &
27 : Yin2017, Pracht2019, Caldeweyher2019, Caldeweyher2020
28 : USE cp_output_handling, ONLY: add_last_numeric, &
29 : cp_print_key_section_create, &
30 : debug_print_level, &
31 : high_print_level, &
32 : low_print_level, &
33 : medium_print_level, &
34 : silent_print_level
35 : USE cp_spline_utils, ONLY: pw_interp, &
36 : spline3_nopbc_interp, &
37 : spline3_pbc_interp
38 : USE cp_units, ONLY: cp_unit_to_cp2k
39 : USE input_constants, ONLY: &
40 : atomic_guess, becke_cutoff_element, becke_cutoff_global, bqb_opt_exhaustive, &
41 : bqb_opt_normal, bqb_opt_off, bqb_opt_patient, bqb_opt_quick, broyden_type_1, &
42 : broyden_type_1_explicit, broyden_type_1_explicit_ls, broyden_type_1_ls, broyden_type_2, &
43 : broyden_type_2_explicit, broyden_type_2_explicit_ls, broyden_type_2_ls, casci_canonical, &
44 : cdft_alpha_constraint, cdft_beta_constraint, cdft_charge_constraint, &
45 : cdft_magnetization_constraint, cholesky_dbcsr, cholesky_inverse, cholesky_off, &
46 : cholesky_reduce, cholesky_restore, core_guess, diag_block_davidson, diag_block_krylov, &
47 : diag_filter_matrix, diag_ot, diag_standard, do_admm_aux_exch_func_bee, &
48 : do_admm_aux_exch_func_bee_libxc, do_admm_aux_exch_func_default, &
49 : do_admm_aux_exch_func_default_libxc, do_admm_aux_exch_func_none, &
50 : do_admm_aux_exch_func_opt, do_admm_aux_exch_func_opt_libxc, do_admm_aux_exch_func_pbex, &
51 : do_admm_aux_exch_func_pbex_libxc, do_admm_aux_exch_func_sx_libxc, &
52 : do_admm_basis_projection, do_admm_blocked_projection, do_admm_blocking_purify_full, &
53 : do_admm_charge_constrained_projection, do_admm_exch_scaling_merlot, &
54 : do_admm_exch_scaling_none, do_admm_purify_cauchy, do_admm_purify_cauchy_subspace, &
55 : do_admm_purify_mcweeny, do_admm_purify_mo_diag, do_admm_purify_mo_no_diag, &
56 : do_admm_purify_none, do_admm_purify_none_dm, do_arnoldi, do_bch, do_cn, &
57 : do_ddapc_constraint, do_ddapc_restraint, do_em, do_etrs, do_full_density, do_gapw_gcs, &
58 : do_gapw_gct, do_gapw_log, do_iaoloc_energy, do_iaoloc_enone, do_iaoloc_l1, do_iaoloc_occ, &
59 : do_iaoloc_pm2, do_iaoloc_pm4, do_lri_inv, do_lri_inv_auto, do_lri_opt_all, &
60 : do_lri_opt_coeff, do_lri_opt_exps, do_lri_pseudoinv_diag, do_lri_pseudoinv_svd, &
61 : do_method_am1, do_method_dftb, do_method_gapw, do_method_gapw_xc, do_method_gpw, &
62 : do_method_lrigpw, do_method_mndo, do_method_mndod, do_method_ofgpw, do_method_pdg, &
63 : do_method_pm3, do_method_pm6, do_method_pm6fm, do_method_pnnl, do_method_rigpw, &
64 : do_method_rm1, do_method_xtb, do_pade, do_potential_coulomb, do_potential_id, &
65 : do_potential_short, do_potential_truncated, do_ppl_analytic, do_ppl_grid, &
66 : do_pwgrid_ns_fullspace, do_pwgrid_ns_halfspace, do_pwgrid_spherical, do_s2_constraint, &
67 : do_s2_restraint, do_se_is_kdso, do_se_is_kdso_d, do_se_is_slater, do_se_lr_ewald, &
68 : do_se_lr_ewald_gks, do_se_lr_ewald_r3, do_se_lr_none, do_spin_density, do_taylor, &
69 : ehrenfest, embed_diff, embed_fa, embed_grid_angstrom, embed_grid_bohr, embed_level_shift, &
70 : embed_none, embed_quasi_newton, embed_resp, embed_steep_desc, eri_method_full_gpw, &
71 : eri_method_gpw_ht, eri_operator_trunc, eri_operator_coulomb, eri_operator_erf, eri_operator_erfc, &
72 : eri_operator_gaussian, eri_operator_yukawa, gapw_1c_large, gapw_1c_medium, gapw_1c_orb, &
73 : gapw_1c_small, gapw_1c_very_large, gaussian, general_roks, gto_cartesian, gto_spherical, &
74 : high_spin_roks, history_guess, jacobian_fd1, jacobian_fd1_backward, &
75 : jacobian_fd1_central, jacobian_fd2, jacobian_fd2_backward, kg_color_dsatur, &
76 : kg_color_greedy, kg_tnadd_atomic, kg_tnadd_embed, kg_tnadd_embed_ri, kg_tnadd_none, &
77 : ls_2pnt, ls_3pnt, ls_gold, ls_none, manual_selection, mao_basis_ext, mao_basis_orb, &
78 : mao_basis_prim, mao_projection, mopac_guess, no_excitations, no_guess, no_solver, &
79 : numerical, oe_gllb, oe_lb, oe_none, oe_saop, oe_sic, orb_dx2, orb_dxy, orb_dy2, orb_dyz, &
80 : orb_dz2, orb_dzx, orb_px, orb_py, orb_pz, orb_s, ot_algo_irac, ot_algo_taylor_or_diag, &
81 : ot_chol_irac, ot_lwdn_irac, ot_mini_broyden, ot_mini_cg, ot_mini_diis, ot_mini_sd, &
82 : ot_poly_irac, ot_precond_full_all, ot_precond_full_kinetic, ot_precond_full_single, &
83 : ot_precond_full_single_inverse, ot_precond_none, ot_precond_s_inverse, &
84 : ot_precond_solver_default, ot_precond_solver_direct, ot_precond_solver_inv_chol, &
85 : ot_precond_solver_update, outer_scf_basis_center_opt, outer_scf_becke_constraint, &
86 : outer_scf_cdft_constraint, outer_scf_ddapc_constraint, outer_scf_hirshfeld_constraint, &
87 : outer_scf_none, outer_scf_optimizer_bisect, outer_scf_optimizer_broyden, &
88 : outer_scf_optimizer_diis, outer_scf_optimizer_newton, outer_scf_optimizer_newton_ls, &
89 : outer_scf_optimizer_none, outer_scf_optimizer_sd, outer_scf_optimizer_secant, &
90 : outer_scf_s2_constraint, plus_u_lowdin, plus_u_mulliken, plus_u_mulliken_charges, &
91 : qiskit_solver, radius_covalent, radius_default, radius_single, radius_user, radius_vdw, &
92 : random_guess, real_time_propagation, ref_charge_atomic, ref_charge_mulliken, rel_dkh, &
93 : rel_none, rel_pot_erfc, rel_pot_full, rel_sczora_mp, rel_trans_atom, rel_trans_full, &
94 : rel_trans_molecule, rel_zora, rel_zora_full, rel_zora_mp, restart_guess, &
95 : sccs_andreussi, sccs_derivative_cd3, sccs_derivative_cd5, sccs_derivative_cd7, &
96 : sccs_derivative_fft, sccs_fattebert_gygi, shape_function_density, shape_function_gaussian, &
97 : sic_ad, sic_eo, sic_list_all, sic_list_unpaired, sic_mauri_spz, sic_mauri_us, sic_none, &
98 : slater, smear_energy_window, smear_fermi_dirac, smear_list, sparse_guess, tddfpt_davidson, &
99 : tddfpt_excitations, tddfpt_lanczos, tddfpt_singlet, tddfpt_spin_cons, tddfpt_spin_flip, &
100 : tddfpt_triplet, use_mom_ref_coac, use_mom_ref_com, use_mom_ref_user, use_mom_ref_zero, &
101 : use_restart_wfn, use_rt_restart, use_scf_wfn, wannier_projection, weight_type_mass, &
102 : weight_type_unit, wfi_aspc_nr, wfi_gext_proj_nr, wfi_gext_proj_qtr_nr, wfi_frozen_method_nr, &
103 : wfi_linear_p_method_nr, wfi_linear_ps_method_nr, wfi_linear_wf_method_nr, wfi_ps_method_nr, &
104 : wfi_use_guess_method_nr, wfi_use_prev_p_method_nr, wfi_use_prev_rho_r_method_nr, &
105 : wfi_use_prev_wf_method_nr, wfn_mix_orig_external, wfn_mix_orig_occ, wfn_mix_orig_virtual, &
106 : xas_1s_type, xas_2p_type, xas_2s_type, xas_3d_type, xas_3p_type, xas_3s_type, xas_4d_type, &
107 : xas_4f_type, xas_4p_type, xas_4s_type, xas_dip_len, xas_dip_vel, xas_dscf, xas_none, &
108 : xas_not_excited, xas_tdp_by_index, xas_tdp_by_kind, xas_tp_fh, xas_tp_flex, xas_tp_hh, &
109 : xas_tp_xfh, xas_tp_xhh, xes_tp_val, &
110 : no_admm_type, admm1_type, admm2_type, admms_type, admmp_type, admmq_type, &
111 : e_dens_total_hard_approx, e_dens_total_density, e_dens_soft_density
112 : USE input_cp2k_almo, ONLY: create_almo_scf_section
113 : USE input_cp2k_distribution, ONLY: create_distribution_section
114 : USE input_cp2k_ec, ONLY: create_ec_section
115 : USE input_cp2k_exstate, ONLY: create_exstate_section
116 : USE input_cp2k_external, ONLY: create_ext_den_section, &
117 : create_ext_pot_section, &
118 : create_ext_vxc_section
119 : USE input_cp2k_field, ONLY: create_efield_section, &
120 : create_per_efield_section
121 : USE input_cp2k_kpoints, ONLY: create_kpoint_set_section, &
122 : create_kpoints_section
123 : USE input_cp2k_loc, ONLY: create_localize_section, &
124 : print_wanniers
125 : USE input_cp2k_ls, ONLY: create_ls_scf_section
126 : USE input_cp2k_mm, ONLY: create_dipoles_section, &
127 : create_neighbor_lists_section
128 : USE input_cp2k_poisson, ONLY: create_poisson_section
129 : USE input_cp2k_projection_rtp, ONLY: create_projection_rtp_section
130 : USE input_cp2k_rsgrid, ONLY: create_rsgrid_section
131 : USE input_cp2k_tb, ONLY: create_dftb_control_section, &
132 : create_xtb_control_section
133 : USE input_cp2k_transport, ONLY: create_transport_section
134 : USE input_cp2k_voronoi, ONLY: create_print_voronoi_section
135 : USE input_cp2k_scf, ONLY: create_scf_section, &
136 : create_cdft_control_section
137 : USE input_cp2k_xc, ONLY: create_xc_fun_section, &
138 : create_xc_section
139 : USE input_keyword_types, ONLY: keyword_create, &
140 : keyword_release, &
141 : keyword_type
142 : USE input_section_types, ONLY: section_add_keyword, &
143 : section_add_subsection, &
144 : section_create, &
145 : section_release, &
146 : section_type
147 : USE input_val_types, ONLY: char_t, &
148 : enum_t, &
149 : integer_t, &
150 : lchar_t, &
151 : logical_t, &
152 : real_t
153 : USE kinds, ONLY: dp
154 : USE kpoint_mo_dump, ONLY: mokp_ao_gto_basis, mokp_ao_overlap_matrix
155 : USE pw_grids, ONLY: do_pw_grid_blocked_false, &
156 : do_pw_grid_blocked_free, &
157 : do_pw_grid_blocked_true
158 : USE pw_spline_utils, ONLY: no_precond, &
159 : precond_spl3_1, &
160 : precond_spl3_2, &
161 : precond_spl3_3, &
162 : precond_spl3_aint, &
163 : precond_spl3_aint2
164 : USE qs_density_mixing_types, ONLY: create_mixing_section
165 : USE qs_fb_input, ONLY: create_filtermatrix_section
166 : USE qs_mom_types, ONLY: create_mom_section
167 : USE string_utilities, ONLY: s2a
168 :
169 : USE cp_output_handling_openpmd, ONLY: cp_openpmd_get_default_extension
170 :
171 : #include "./base/base_uses.f90"
172 :
173 : IMPLICIT NONE
174 : PRIVATE
175 :
176 : CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'input_cp2k_print_dft'
177 :
178 : PUBLIC :: add_dos_keywords, create_print_dft_section
179 :
180 : CONTAINS
181 :
182 : ! **************************************************************************************************
183 : !> \brief Create the print dft section
184 : !> \param section the section to create
185 : !> \author teo
186 : ! **************************************************************************************************
187 10278 : SUBROUTINE create_print_dft_section(section)
188 : TYPE(section_type), POINTER :: section
189 :
190 : TYPE(keyword_type), POINTER :: keyword
191 : TYPE(section_type), POINTER :: print_key, sub_print_key, subsection
192 :
193 10278 : CPASSERT(.NOT. ASSOCIATED(section))
194 : CALL section_create(section, __LOCATION__, name="PRINT", &
195 : description="Section of possible print options in DFT code.", &
196 10278 : n_keywords=0, n_subsections=1, repeats=.FALSE.)
197 :
198 10278 : NULLIFY (print_key, keyword, subsection)
199 :
200 : CALL cp_print_key_section_create(print_key, __LOCATION__, "PROGRAM_BANNER", &
201 : description="Controls the printing of the banner of the MM program", &
202 10278 : print_level=silent_print_level, filename="__STD_OUT__")
203 10278 : CALL section_add_subsection(section, print_key)
204 10278 : CALL section_release(print_key)
205 :
206 : CALL cp_print_key_section_create(print_key, __LOCATION__, "BASIS_SET_FILE", &
207 : description="Controls the printing of a file with all basis sets used.", &
208 10278 : print_level=high_print_level, filename="LOCAL_BASIS_SETS")
209 10278 : CALL section_add_subsection(section, print_key)
210 10278 : CALL section_release(print_key)
211 :
212 : CALL cp_print_key_section_create(print_key, __LOCATION__, "KINETIC_ENERGY", &
213 : description="Controls the printing of the kinetic energy", &
214 10278 : print_level=high_print_level, filename="__STD_OUT__")
215 10278 : CALL section_add_subsection(section, print_key)
216 10278 : CALL section_release(print_key)
217 :
218 : CALL cp_print_key_section_create(print_key, __LOCATION__, "DERIVATIVES", &
219 : description="Print all derivatives after the DFT calculation", &
220 10278 : print_level=high_print_level, filename="__STD_OUT__")
221 : CALL keyword_create(keyword, __LOCATION__, &
222 : name="ndigits", &
223 : description="Specify the number of digits used to print derivatives", &
224 10278 : default_i_val=6)
225 10278 : CALL section_add_keyword(print_key, keyword)
226 10278 : CALL keyword_release(keyword)
227 :
228 10278 : CALL section_add_subsection(section, print_key)
229 10278 : CALL section_release(print_key)
230 :
231 : CALL cp_print_key_section_create(print_key, __LOCATION__, name="neighbor_lists", &
232 : description="Controls the printing of the neighbor lists", &
233 10278 : print_level=debug_print_level, filename="", unit_str="angstrom")
234 : CALL keyword_create(keyword, __LOCATION__, &
235 : name="sab_orb", &
236 : description="Activates the printing of the orbital "// &
237 : "orbital neighbor lists, "// &
238 : "i.e. the overlap neighbor lists", &
239 : default_l_val=.FALSE., &
240 10278 : lone_keyword_l_val=.TRUE.)
241 10278 : CALL section_add_keyword(print_key, keyword)
242 10278 : CALL keyword_release(keyword)
243 :
244 : CALL keyword_create(keyword, __LOCATION__, &
245 : name="sab_aux_fit", &
246 : description="Activates the printing of the orbital "// &
247 : "orbital neighbor lists wavefunction fitting basis, "// &
248 : "i.e. the overlap neighbor lists", &
249 : default_l_val=.FALSE., &
250 10278 : lone_keyword_l_val=.TRUE.)
251 10278 : CALL section_add_keyword(print_key, keyword)
252 10278 : CALL keyword_release(keyword)
253 :
254 : CALL keyword_create(keyword, __LOCATION__, &
255 : name="sab_aux_fit_vs_orb", &
256 : description="Activates the printing of the orbital "// &
257 : "orbital mixed neighbor lists of wavefunction fitting basis, "// &
258 : "and the orbital basis, i.e. the overlap neighbor lists", &
259 : default_l_val=.FALSE., &
260 10278 : lone_keyword_l_val=.TRUE.)
261 10278 : CALL section_add_keyword(print_key, keyword)
262 10278 : CALL keyword_release(keyword)
263 :
264 : CALL keyword_create(keyword, __LOCATION__, &
265 : name="sab_scp", &
266 : description="Activates the printing of the vdW SCP "// &
267 : "neighbor lists ", &
268 : default_l_val=.FALSE., &
269 10278 : lone_keyword_l_val=.TRUE.)
270 10278 : CALL section_add_keyword(print_key, keyword)
271 10278 : CALL keyword_release(keyword)
272 :
273 : CALL keyword_create(keyword, __LOCATION__, &
274 : name="sab_vdw", &
275 : description="Activates the printing of the vdW "// &
276 : "neighbor lists (from DFT, DFTB, SE), "// &
277 : "i.e. the dispersion neighbor lists", &
278 : default_l_val=.FALSE., &
279 10278 : lone_keyword_l_val=.TRUE.)
280 10278 : CALL section_add_keyword(print_key, keyword)
281 10278 : CALL keyword_release(keyword)
282 :
283 : CALL keyword_create(keyword, __LOCATION__, &
284 : name="sab_cn", &
285 : description="Activates the printing of the "// &
286 : "neighbor lists used for coordination numbers in vdW DFT-D3", &
287 : default_l_val=.FALSE., &
288 10278 : lone_keyword_l_val=.TRUE.)
289 10278 : CALL section_add_keyword(print_key, keyword)
290 10278 : CALL keyword_release(keyword)
291 :
292 : CALL keyword_create(keyword, __LOCATION__, &
293 : name="sac_ae", &
294 : description="Activates the printing of the orbital "// &
295 : "nuclear attraction neighbor lists (erfc potential)", &
296 : default_l_val=.FALSE., &
297 10278 : lone_keyword_l_val=.TRUE.)
298 10278 : CALL section_add_keyword(print_key, keyword)
299 10278 : CALL keyword_release(keyword)
300 :
301 : CALL keyword_create(keyword, __LOCATION__, &
302 : name="sac_ppl", &
303 : description="Activates the printing of the orbital "// &
304 : "GTH-PPL neighbor lists (local part of the "// &
305 : "Goedecker-Teter-Hutter pseudo potentials)", &
306 : default_l_val=.FALSE., &
307 10278 : lone_keyword_l_val=.TRUE.)
308 10278 : CALL section_add_keyword(print_key, keyword)
309 10278 : CALL keyword_release(keyword)
310 :
311 : CALL keyword_create(keyword, __LOCATION__, &
312 : name="sap_ppnl", &
313 : description="Activates the printing of the orbital "// &
314 : "GTH-PPNL neighbor lists (non-local part of the "// &
315 : "Goedecker-Teter-Hutter pseudo potentials)", &
316 : default_l_val=.FALSE., &
317 10278 : lone_keyword_l_val=.TRUE.)
318 10278 : CALL section_add_keyword(print_key, keyword)
319 10278 : CALL keyword_release(keyword)
320 :
321 : CALL keyword_create(keyword, __LOCATION__, &
322 : name="sap_oce", &
323 : description="Activates the printing of the orbital "// &
324 : "PAW-projector neighbor lists (only GAPW)", &
325 : default_l_val=.FALSE., &
326 10278 : lone_keyword_l_val=.TRUE.)
327 10278 : CALL section_add_keyword(print_key, keyword)
328 10278 : CALL keyword_release(keyword)
329 :
330 : CALL keyword_create(keyword, __LOCATION__, &
331 : name="sab_se", &
332 : description="Activates the printing of the two-center "// &
333 : "neighbor lists for Coulomb type interactions in NDDO ", &
334 : default_l_val=.FALSE., &
335 10278 : lone_keyword_l_val=.TRUE.)
336 10278 : CALL section_add_keyword(print_key, keyword)
337 10278 : CALL keyword_release(keyword)
338 :
339 : CALL keyword_create(keyword, __LOCATION__, &
340 : name="sab_lrc", &
341 : description="Activates the printing of the long-range SE correction "// &
342 : "neighbor lists (only when doing long-range SE with integral scheme KDSO and KDSO-d)", &
343 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
344 10278 : CALL section_add_keyword(print_key, keyword)
345 10278 : CALL keyword_release(keyword)
346 :
347 : CALL keyword_create(keyword, __LOCATION__, &
348 : name="sab_tbe", &
349 : description="Activates the printing of the DFTB Ewald "// &
350 : "neighbor lists ", &
351 : default_l_val=.FALSE., &
352 10278 : lone_keyword_l_val=.TRUE.)
353 10278 : CALL section_add_keyword(print_key, keyword)
354 10278 : CALL keyword_release(keyword)
355 :
356 : CALL keyword_create(keyword, __LOCATION__, &
357 : name="sab_xtbe", &
358 : description="Activates the printing of the xTB sr-Coulomb "// &
359 : "neighbor lists ", &
360 : default_l_val=.FALSE., &
361 10278 : lone_keyword_l_val=.TRUE.)
362 10278 : CALL section_add_keyword(print_key, keyword)
363 10278 : CALL keyword_release(keyword)
364 :
365 : CALL keyword_create(keyword, __LOCATION__, &
366 : name="sab_core", &
367 : description="Activates the printing of core interaction "// &
368 : "neighbor lists ", &
369 : default_l_val=.FALSE., &
370 10278 : lone_keyword_l_val=.TRUE.)
371 10278 : CALL section_add_keyword(print_key, keyword)
372 10278 : CALL keyword_release(keyword)
373 :
374 : CALL keyword_create(keyword, __LOCATION__, &
375 : name="sab_xb", &
376 : description="Activates the printing of XB interaction from (xTB) "// &
377 : "neighbor lists ", &
378 : default_l_val=.FALSE., &
379 10278 : lone_keyword_l_val=.TRUE.)
380 10278 : CALL section_add_keyword(print_key, keyword)
381 10278 : CALL keyword_release(keyword)
382 :
383 : CALL keyword_create(keyword, __LOCATION__, &
384 : name="sab_xtb_nonbond", &
385 : description="Activates the printing of nonbonded interaction from (xTB) "// &
386 : "neighbor lists ", &
387 : default_l_val=.FALSE., &
388 10278 : lone_keyword_l_val=.TRUE.)
389 10278 : CALL section_add_keyword(print_key, keyword)
390 10278 : CALL keyword_release(keyword)
391 :
392 : CALL keyword_create(keyword, __LOCATION__, &
393 : name="soo_list", &
394 : description="Activates the printing of RI orbital-orbital "// &
395 : "neighbor lists ", &
396 : default_l_val=.FALSE., &
397 10278 : lone_keyword_l_val=.TRUE.)
398 10278 : CALL section_add_keyword(print_key, keyword)
399 10278 : CALL keyword_release(keyword)
400 :
401 : CALL keyword_create(keyword, __LOCATION__, &
402 : name="sip_list", &
403 : description="Activates the printing of RI basis-projector interaction "// &
404 : "neighbor lists ", &
405 : default_l_val=.FALSE., &
406 10278 : lone_keyword_l_val=.TRUE.)
407 10278 : CALL section_add_keyword(print_key, keyword)
408 10278 : CALL keyword_release(keyword)
409 :
410 : CALL keyword_create(keyword, __LOCATION__, &
411 : name="sab_cneo", &
412 : description="Activates the printing of the nuclear orbital "// &
413 : "nuclear repulsion neighbor lists (erfc potential)", &
414 : default_l_val=.FALSE., &
415 10278 : lone_keyword_l_val=.TRUE.)
416 10278 : CALL section_add_keyword(print_key, keyword)
417 10278 : CALL keyword_release(keyword)
418 :
419 10278 : CALL section_add_subsection(section, print_key)
420 10278 : CALL section_release(print_key)
421 :
422 : CALL cp_print_key_section_create(print_key, __LOCATION__, "SUBCELL", &
423 : description="Activates the printing of the subcells used for the "// &
424 : "generation of neighbor lists.", unit_str="angstrom", &
425 10278 : print_level=high_print_level, filename="__STD_OUT__")
426 10278 : CALL section_add_subsection(section, print_key)
427 10278 : CALL section_release(print_key)
428 :
429 : CALL cp_print_key_section_create(print_key, __LOCATION__, "AO_MATRICES", &
430 : description="Controls the printing of the ao (i.e. contracted gaussian) matrices (debug).", &
431 10278 : print_level=debug_print_level, filename="__STD_OUT__")
432 : CALL keyword_create(keyword, __LOCATION__, name="OMIT_HEADERS", &
433 : description="Print only the matrix data, not the row and column headers", &
434 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
435 10278 : CALL section_add_keyword(print_key, keyword)
436 10278 : CALL keyword_release(keyword)
437 :
438 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
439 : description="Specify the number of digits used to print the AO matrices", &
440 10278 : default_i_val=6)
441 10278 : CALL section_add_keyword(print_key, keyword)
442 10278 : CALL keyword_release(keyword)
443 : CALL keyword_create(keyword, __LOCATION__, name="CORE_HAMILTONIAN", &
444 : description="If the printkey is activated controls the printing of the hamiltonian matrix", &
445 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
446 10278 : CALL section_add_keyword(print_key, keyword)
447 10278 : CALL keyword_release(keyword)
448 : CALL keyword_create(keyword, __LOCATION__, name="DENSITY", &
449 : description="If the printkey is activated controls the printing of the density (P) matrix", &
450 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
451 10278 : CALL section_add_keyword(print_key, keyword)
452 10278 : CALL keyword_release(keyword)
453 :
454 : CALL keyword_create(keyword, __LOCATION__, name="KINETIC_ENERGY", &
455 : description="If the printkey is activated controls the printing of the kinetic energy matrix", &
456 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
457 10278 : CALL section_add_keyword(print_key, keyword)
458 10278 : CALL keyword_release(keyword)
459 : CALL keyword_create(keyword, __LOCATION__, name="KOHN_SHAM_MATRIX", &
460 : description="If the printkey is activated controls the printing of the Kohn-Sham matrix", &
461 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
462 10278 : CALL section_add_keyword(print_key, keyword)
463 10278 : CALL keyword_release(keyword)
464 : CALL keyword_create( &
465 : keyword, __LOCATION__, name="MATRIX_VXC", &
466 : description="If the printkey is activated compute and print the matrix of the exchange and correlation potential. "// &
467 : "Only the GGA part for GPW is printed", &
468 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
469 10278 : CALL section_add_keyword(print_key, keyword)
470 10278 : CALL keyword_release(keyword)
471 : CALL keyword_create(keyword, __LOCATION__, name="ORTHO", &
472 : description="If the printkey is activated controls the printing of the orthogonalization matrix", &
473 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
474 10278 : CALL section_add_keyword(print_key, keyword)
475 10278 : CALL keyword_release(keyword)
476 : CALL keyword_create(keyword, __LOCATION__, name="OVERLAP", &
477 : description="If the printkey is activated controls the printing of the overlap matrix", &
478 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
479 10278 : CALL section_add_keyword(print_key, keyword)
480 10278 : CALL keyword_release(keyword)
481 :
482 : CALL keyword_create(keyword, __LOCATION__, name="COMMUTATOR_HR", &
483 : description="Controls the printing of the [H,r] commutator matrix", &
484 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
485 10278 : CALL section_add_keyword(print_key, keyword)
486 10278 : CALL keyword_release(keyword)
487 :
488 : CALL keyword_create(keyword, __LOCATION__, name="FERMI_CONTACT", &
489 : description="If the printkey is activated controls the printing of the Fermi contact matrix", &
490 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
491 10278 : CALL section_add_keyword(print_key, keyword)
492 10278 : CALL keyword_release(keyword)
493 : CALL keyword_create( &
494 : keyword, __LOCATION__, name="PSO", &
495 : description="If the printkey is activated controls the printing of the paramagnetic spin-orbit matrices", &
496 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
497 10278 : CALL section_add_keyword(print_key, keyword)
498 10278 : CALL keyword_release(keyword)
499 : CALL keyword_create( &
500 : keyword, __LOCATION__, name="EFG", &
501 : description="If the printkey is activated controls the printing of the electric field gradient matrices", &
502 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
503 10278 : CALL section_add_keyword(print_key, keyword)
504 10278 : CALL keyword_release(keyword)
505 : CALL keyword_create(keyword, __LOCATION__, name="POTENTIAL_ENERGY", &
506 : description="If the printkey is activated controls the printing of the potential energy matrix", &
507 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
508 10278 : CALL section_add_keyword(print_key, keyword)
509 10278 : CALL keyword_release(keyword)
510 : CALL keyword_create(keyword, __LOCATION__, name="OCE_HARD", &
511 : description="If the printkey is activated controls the printing of the OCE HARD matrix", &
512 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
513 10278 : CALL section_add_keyword(print_key, keyword)
514 10278 : CALL keyword_release(keyword)
515 : CALL keyword_create(keyword, __LOCATION__, name="OCE_SOFT", &
516 : description="If the printkey is activated controls the printing of the OCE SOFT matrix", &
517 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
518 10278 : CALL section_add_keyword(print_key, keyword)
519 10278 : CALL keyword_release(keyword)
520 : CALL keyword_create(keyword, __LOCATION__, name="W_MATRIX", &
521 : description="If the printkey is activated controls the printing of the w matrix", &
522 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
523 10278 : CALL section_add_keyword(print_key, keyword)
524 10278 : CALL keyword_release(keyword)
525 : CALL keyword_create(keyword, __LOCATION__, name="W_MATRIX_AUX_FIT", &
526 : description="If the printkey is activated controls the printing of the w matrix", &
527 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
528 10278 : CALL section_add_keyword(print_key, keyword)
529 10278 : CALL keyword_release(keyword)
530 : CALL keyword_create(keyword, __LOCATION__, name="DERIVATIVES", &
531 : description="If the printkey is activated controls the printing "// &
532 : "of derivatives (for the matrixes that support this)", &
533 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
534 10278 : CALL section_add_keyword(print_key, keyword)
535 10278 : CALL keyword_release(keyword)
536 10278 : CALL section_add_subsection(section, print_key)
537 10278 : CALL section_release(print_key)
538 :
539 : CALL cp_print_key_section_create( &
540 : print_key, __LOCATION__, "MO", &
541 : description="Controls the printing of the molecular orbital (MO) information. The requested MO information "// &
542 : "is printed for all occupied MOs by default. Use the MO_INDEX_RANGE keyword to restrict the number "// &
543 : "of the MOs or to print the MO information for unoccupied MOs. With diagonalization, additional MOs "// &
544 : "have to be made available for printout using the ADDED_MOS keyword in the SCF section. With OT, "// &
545 : "it is sufficient to specify the desired MO_INDEX_RANGE. The OT eigensolver can be controlled with "// &
546 : "the EPS_LUMO and MAX_ITER_LUMO keywords in the SCF section.", &
547 10278 : print_level=high_print_level, filename="__STD_OUT__")
548 : CALL keyword_create(keyword, __LOCATION__, name="CARTESIAN", &
549 : description="Print the MOs in the Cartesian basis instead of the default spherical basis.", &
550 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
551 10278 : CALL section_add_keyword(print_key, keyword)
552 10278 : CALL keyword_release(keyword)
553 : CALL keyword_create(keyword, __LOCATION__, name="CARTESIAN_OVERLAP", &
554 : description="Print the Cartesian overlap matrix in line with Cartesian MO coefficients.", &
555 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
556 10278 : CALL section_add_keyword(print_key, keyword)
557 10278 : CALL keyword_release(keyword)
558 : CALL keyword_create(keyword, __LOCATION__, name="ENERGIES", &
559 : variants=s2a("EIGENVALUES", "EIGVALS"), &
560 : description="Print the MO energies (eigenvalues).", &
561 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
562 10278 : CALL section_add_keyword(print_key, keyword)
563 10278 : CALL keyword_release(keyword)
564 : CALL keyword_create(keyword, __LOCATION__, name="COEFFICIENTS", &
565 : variants=s2a("EIGENVECTORS", "EIGVECS"), &
566 : description="Print the MO coefficients (eigenvectors).", &
567 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
568 10278 : CALL section_add_keyword(print_key, keyword)
569 10278 : CALL keyword_release(keyword)
570 : CALL keyword_create(keyword, __LOCATION__, name="OCCUPATION_NUMBERS", &
571 : variants=s2a("OCCNUMS"), &
572 : description="Print the MO occupation numbers.", &
573 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
574 10278 : CALL section_add_keyword(print_key, keyword)
575 10278 : CALL keyword_release(keyword)
576 : CALL keyword_create(keyword, __LOCATION__, name="OCCUPATION_NUMBERS_STATS", &
577 : variants=s2a("OCCNUMSTATS"), &
578 : description="Print some stats (max number of occupied MOs, etc.) of the MO occupation numbers."// &
579 : " First logical toggles stats printing, first real is the occupied threshold.", &
580 : type_of_var=char_t, n_var=-1, &
581 : default_c_vals=[".FALSE.", "1.0E-6 "], &
582 : lone_keyword_c_vals=[".TRUE."], &
583 41112 : usage="OCCUPATION_NUMBERS_STATS {Logical} [{Real}]")
584 10278 : CALL section_add_keyword(print_key, keyword)
585 10278 : CALL keyword_release(keyword)
586 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
587 : description="Specify the number of digits used to print the MO information.", &
588 10278 : default_i_val=6)
589 10278 : CALL section_add_keyword(print_key, keyword)
590 10278 : CALL keyword_release(keyword)
591 : CALL keyword_create(keyword, __LOCATION__, &
592 : name="MO_INDEX_RANGE", &
593 : variants=s2a("MO_RANGE", "RANGE"), &
594 : description="Print only the requested subset of MOs. The indices of the first and "// &
595 : "the last MO have to be specified to define the range. -1 as the last MO index "// &
596 : "prints all available orbitals with diagonalisation (ADDED_MOS) and all orbitals with OT.", &
597 : repeats=.FALSE., &
598 : n_var=2, &
599 : type_of_var=integer_t, &
600 : default_i_vals=[0, 0], &
601 10278 : usage="MO_INDEX_RANGE 10 15")
602 10278 : CALL section_add_keyword(print_key, keyword)
603 10278 : CALL keyword_release(keyword)
604 10278 : CALL section_add_subsection(section, print_key)
605 10278 : CALL section_release(print_key)
606 :
607 : CALL cp_print_key_section_create(print_key, __LOCATION__, "MO_MOLDEN", &
608 : description="Write the molecular orbitals in Molden file format, for visualisation.", &
609 10278 : print_level=debug_print_level + 1, add_last=add_last_numeric, filename="MOS")
610 : CALL keyword_create(keyword, __LOCATION__, name="UNIT", &
611 : description="Unit for coordinates and cell in the MOLDEN file.", &
612 : usage="UNIT ANGSTROM", &
613 : enum_c_vals=s2a("BOHR", "ANGSTROM"), &
614 : enum_desc=s2a("Write in Bohr (AU)", "Write in Angstrom"), &
615 : enum_i_vals=[1, 2], &
616 10278 : default_i_val=1)
617 10278 : CALL section_add_keyword(print_key, keyword)
618 10278 : CALL keyword_release(keyword)
619 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_CELL", &
620 : description="Controls whether the [Cell] block is written to the MOLDEN file.", &
621 : usage="WRITE_CELL T", &
622 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
623 10278 : CALL section_add_keyword(print_key, keyword)
624 10278 : CALL keyword_release(keyword)
625 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_PSEUDO", &
626 : description="Controls whether the [Pseudo] block is written to the MOLDEN file.", &
627 : usage="WRITE_PSEUDO T", &
628 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
629 10278 : CALL section_add_keyword(print_key, keyword)
630 10278 : CALL keyword_release(keyword)
631 : CALL keyword_create(keyword, __LOCATION__, name="MARK_GHOST", &
632 : description="Controls whether ghost atoms are marked in the [Atoms] block by "// &
633 : "setting their atomic number to zero.", &
634 : usage="MARK_GHOST T", &
635 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
636 10278 : CALL section_add_keyword(print_key, keyword)
637 10278 : CALL keyword_release(keyword)
638 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
639 : description="Specifies the number of significant digits retained. 3 is OK for visualization.", &
640 : usage="NDIGITS {int}", &
641 10278 : default_i_val=3)
642 10278 : CALL section_add_keyword(print_key, keyword)
643 10278 : CALL keyword_release(keyword)
644 : CALL keyword_create(keyword, __LOCATION__, name="GTO_KIND", &
645 : description="Representation of Gaussian-type orbitals", &
646 : default_i_val=gto_spherical, &
647 : enum_c_vals=s2a("CARTESIAN", "SPHERICAL"), &
648 : enum_desc=s2a( &
649 : "Cartesian Gaussian orbitals. Use with caution", &
650 : "Spherical Gaussian orbitals. Incompatible with VMD"), &
651 10278 : enum_i_vals=[gto_cartesian, gto_spherical])
652 10278 : CALL section_add_keyword(print_key, keyword)
653 10278 : CALL keyword_release(keyword)
654 : CALL keyword_create(keyword, __LOCATION__, name="NLUMO", &
655 : description="Number of unoccupied orbitals to include in the Molden file. "// &
656 : "For OT calculations, the requested virtual orbitals are generated after "// &
657 : "SCF using the OT eigensolver. For diagonalization calculations, "// &
658 : "SCF%ADDED_MOS is increased if needed to make the requested unoccupied "// &
659 : "orbitals available. 0 means no virtual orbitals, -1 means all available.", &
660 : usage="NLUMO integer", &
661 10278 : default_i_val=0)
662 10278 : CALL section_add_keyword(print_key, keyword)
663 10278 : CALL keyword_release(keyword)
664 10278 : CALL section_add_subsection(section, print_key)
665 10278 : CALL section_release(print_key)
666 :
667 : CALL cp_print_key_section_create(print_key, __LOCATION__, "MO_KP", &
668 : description="Write k-point MO information to `.mokp` file. "// &
669 : "The information of cell and k-points is given at first. Then, "// &
670 : "the coefficients of molecular orbitals are always written, "// &
671 : "while users can choose whether to write GTO basis information "// &
672 : "or explicit overlap matrices through the `AO_EXPORT_TYPE` keyword.", &
673 10278 : print_level=debug_print_level + 1, add_last=add_last_numeric, filename="")
674 : CALL keyword_create(keyword, __LOCATION__, name="UNIT", &
675 : description="Unit for coordinates and cell in the .mokp file.", &
676 : usage="UNIT ANGSTROM", &
677 : enum_c_vals=s2a("BOHR", "ANGSTROM"), &
678 : enum_desc=s2a("Write in Bohr (AU)", "Write in Angstrom"), &
679 : enum_i_vals=[1, 2], &
680 10278 : default_i_val=1)
681 10278 : CALL section_add_keyword(print_key, keyword)
682 10278 : CALL keyword_release(keyword)
683 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
684 : description="Specifies the number of significant digits retained.", &
685 : usage="NDIGITS {int}", &
686 10278 : default_i_val=9)
687 10278 : CALL section_add_keyword(print_key, keyword)
688 10278 : CALL keyword_release(keyword)
689 : CALL keyword_create(keyword, __LOCATION__, name="AO_EXPORT_TYPE", &
690 : description="How AO information is provided for interpreting MO coefficients. "// &
691 : "GTO_BASIS writes basis set exponents/coefficients (compact, post-processing reconstructs S(k)). "// &
692 : "OVERLAP_MATRIX writes S(k) directly (larger file, ready to use).", &
693 : default_i_val=mokp_ao_gto_basis, &
694 : enum_c_vals=s2a("GTO_BASIS", "OVERLAP_MATRIX"), &
695 : enum_desc=s2a("Write GTO basis set definition (MOLDEN denormalization convention)", &
696 : "Write explicit overlap matrices S(k) for all k-points"), &
697 10278 : enum_i_vals=[mokp_ao_gto_basis, mokp_ao_overlap_matrix])
698 10278 : CALL section_add_keyword(print_key, keyword)
699 10278 : CALL keyword_release(keyword)
700 10278 : CALL section_add_subsection(section, print_key)
701 10278 : CALL section_release(print_key)
702 :
703 10278 : CALL create_mo_section(print_key, "MO_CUBES", "cube", [2, 2, 2], "STRIDE 1 1 1", high_print_level, "write_cube")
704 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
705 : description="append the cube files when they already exist", &
706 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
707 10278 : CALL section_add_keyword(print_key, keyword)
708 10278 : CALL keyword_release(keyword)
709 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
710 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
711 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
712 10278 : CALL section_add_keyword(print_key, keyword)
713 10278 : CALL keyword_release(keyword)
714 10278 : CALL section_add_subsection(section, print_key)
715 10278 : CALL section_release(print_key)
716 :
717 : CALL create_mo_section( &
718 10278 : print_key, "MO_OPENPMD", "openPMD", [1, 1, 1], "STRIDE 2 2 2", debug_print_level + 1, "write_openpmd")
719 10278 : CALL add_generic_openpmd_arguments(print_key)
720 10278 : CALL section_add_subsection(section, print_key)
721 10278 : CALL section_release(print_key)
722 :
723 10278 : CALL create_stm_section(print_key)
724 10278 : CALL section_add_subsection(section, print_key)
725 10278 : CALL section_release(print_key)
726 :
727 10278 : CALL create_wfn_mix_section(subsection)
728 10278 : CALL section_add_subsection(section, subsection)
729 10278 : CALL section_release(subsection)
730 :
731 : CALL section_create(subsection, __LOCATION__, name="TREXIO", &
732 : description="Write a TREXIO file to disk.", &
733 10278 : n_keywords=4, n_subsections=0, repeats=.FALSE.)
734 : CALL keyword_create(keyword, __LOCATION__, name="FILENAME", &
735 : description="Body of Filename for the trexio file.", &
736 : usage="FILENAME {name}", default_c_val="TREXIO", &
737 10278 : type_of_var=char_t)
738 10278 : CALL section_add_keyword(subsection, keyword)
739 10278 : CALL keyword_release(keyword)
740 : CALL keyword_create(keyword, __LOCATION__, name="CARTESIAN", &
741 : description="Store the MOs in the Cartesian basis instead of the default spherical basis.", &
742 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
743 10278 : CALL section_add_keyword(subsection, keyword)
744 10278 : CALL keyword_release(keyword)
745 : CALL keyword_create(keyword, __LOCATION__, name="FULL_KPOINT_GRID", &
746 : description="For symmetry-reduced k-point SCF calculations, export MOs on the "// &
747 : "full unreduced k-point grid instead of the irreducible grid.", &
748 : usage="FULL_KPOINT_GRID <LOGICAL>", default_l_val=.FALSE., &
749 10278 : lone_keyword_l_val=.TRUE.)
750 10278 : CALL section_add_keyword(subsection, keyword)
751 10278 : CALL keyword_release(keyword)
752 : CALL keyword_create(keyword, __LOCATION__, name="REUSE_SCF_MOS", &
753 : description="When FULL_KPOINT_GRID is active, try to reconstruct the full-grid "// &
754 : "MO coefficients from the symmetry-reduced SCF orbitals before falling back to "// &
755 : "a full-grid diagonalization.", &
756 10278 : usage="REUSE_SCF_MOS T", default_l_val=.TRUE.)
757 10278 : CALL section_add_keyword(subsection, keyword)
758 10278 : CALL keyword_release(keyword)
759 10278 : CALL section_add_subsection(section, subsection)
760 10278 : CALL section_release(subsection)
761 :
762 : CALL section_create(subsection, __LOCATION__, name="CASINO", &
763 : description="Write a CASINO gwfn.data file to disk.", &
764 10278 : n_keywords=5, n_subsections=0, repeats=.FALSE.)
765 : CALL keyword_create(keyword, __LOCATION__, name="FILENAME", &
766 : description="Filename for the CASINO gwfn.data file.", &
767 : usage="FILENAME {name}", default_c_val="gwfn.data", &
768 10278 : type_of_var=char_t)
769 10278 : CALL section_add_keyword(subsection, keyword)
770 10278 : CALL keyword_release(keyword)
771 : CALL keyword_create(keyword, __LOCATION__, name="EPS_KPOINT_REAL", &
772 : description="Tolerance for detecting Gamma/BZ-edge k-points with real orbitals.", &
773 10278 : usage="EPS_KPOINT_REAL 1.0E-10", default_r_val=1.0E-10_dp)
774 10278 : CALL section_add_keyword(subsection, keyword)
775 10278 : CALL keyword_release(keyword)
776 : CALL keyword_create(keyword, __LOCATION__, name="FULL_KPOINT_GRID", &
777 : description="For symmetry-reduced k-point SCF calculations, export orbitals on the "// &
778 : "full unreduced k-point grid required by CASINO.", &
779 : usage="FULL_KPOINT_GRID <LOGICAL>", default_l_val=.TRUE., &
780 10278 : lone_keyword_l_val=.TRUE.)
781 10278 : CALL section_add_keyword(subsection, keyword)
782 10278 : CALL keyword_release(keyword)
783 : CALL keyword_create(keyword, __LOCATION__, name="REUSE_SCF_MOS", &
784 : description="When FULL_KPOINT_GRID is active, try to reconstruct the full-grid "// &
785 : "MO coefficients from the symmetry-reduced SCF orbitals before falling back to "// &
786 : "a full-grid diagonalization.", &
787 10278 : usage="REUSE_SCF_MOS T", default_l_val=.TRUE.)
788 10278 : CALL section_add_keyword(subsection, keyword)
789 10278 : CALL keyword_release(keyword)
790 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_PSEUDOPOTENTIALS", &
791 : description="Write CASINO *_pp.data files for CP2K semilocal ECP potentials. "// &
792 : "GTH pseudopotentials are marked in gwfn.data, but require externally supplied "// &
793 : "CASINO pseudopotential files.", &
794 : usage="WRITE_PSEUDOPOTENTIALS T", default_l_val=.TRUE., &
795 10278 : lone_keyword_l_val=.TRUE.)
796 10278 : CALL section_add_keyword(subsection, keyword)
797 10278 : CALL keyword_release(keyword)
798 10278 : CALL section_add_subsection(section, subsection)
799 10278 : CALL section_release(subsection)
800 :
801 : CALL section_create(subsection, __LOCATION__, name="GAPW", &
802 : description="Controls the printing of some gapw related information (debug).", &
803 10278 : n_keywords=0, n_subsections=1, repeats=.FALSE.)
804 : CALL cp_print_key_section_create(print_key, __LOCATION__, "projectors", &
805 : description="If the printkey is activated controls if information on"// &
806 : " the projectors is printed.", &
807 10278 : print_level=debug_print_level, filename="__STD_OUT__")
808 10278 : CALL section_add_subsection(subsection, print_key)
809 10278 : CALL section_release(print_key)
810 : CALL cp_print_key_section_create(print_key, __LOCATION__, "rho0_information", &
811 : description="If the printkey is activated controls if information on rho0 is printed.", &
812 10278 : print_level=debug_print_level, filename="__STD_OUT__", unit_str="angstrom")
813 10278 : CALL section_add_subsection(subsection, print_key)
814 10278 : CALL section_release(print_key)
815 10278 : CALL section_add_subsection(section, subsection)
816 10278 : CALL section_release(subsection)
817 :
818 : CALL cp_print_key_section_create(print_key, __LOCATION__, "dft_control_parameters", &
819 : description="Controls the printing of dft control parameters.", &
820 10278 : print_level=medium_print_level, filename="__STD_OUT__")
821 10278 : CALL section_add_subsection(section, print_key)
822 10278 : CALL section_release(print_key)
823 :
824 : CALL cp_print_key_section_create(print_key, __LOCATION__, "KPOINTS", &
825 : description="Controls the printing of kpoint information.", &
826 10278 : print_level=medium_print_level, filename="__STD_OUT__")
827 10278 : CALL section_add_subsection(section, print_key)
828 10278 : CALL section_release(print_key)
829 :
830 10278 : NULLIFY (subsection)
831 10278 : CALL create_bandstructure_section(subsection)
832 10278 : CALL section_add_subsection(section, subsection)
833 10278 : CALL section_release(subsection)
834 :
835 : CALL cp_print_key_section_create(print_key, __LOCATION__, "OVERLAP_CONDITION", &
836 : description="Controls the checking and printing of an estimate "// &
837 : "of the overlap matrix condition number", &
838 10278 : print_level=debug_print_level, filename="__STD_OUT__")
839 : CALL keyword_create(keyword, __LOCATION__, name="1-NORM", &
840 : description="Calculate an estimate of the 1-norm condition number", &
841 10278 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
842 10278 : CALL section_add_keyword(print_key, keyword)
843 10278 : CALL keyword_release(keyword)
844 : CALL keyword_create(keyword, __LOCATION__, name="DIAGONALIZATION", &
845 : description="Calculate the 1- and 2-norm condition numbers using diagonalization", &
846 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
847 10278 : CALL section_add_keyword(print_key, keyword)
848 10278 : CALL keyword_release(keyword)
849 : CALL keyword_create(keyword, __LOCATION__, name="ARNOLDI", &
850 : description="Calculate the 2-norm condition number using the Arnoldi code (may not be reliable)", &
851 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
852 10278 : CALL section_add_keyword(print_key, keyword)
853 10278 : CALL keyword_release(keyword)
854 10278 : CALL section_add_subsection(section, print_key)
855 10278 : CALL section_release(print_key)
856 :
857 : CALL create_e_density_section( &
858 : print_key, &
859 : "E_DENSITY_OPENPMD", &
860 : "openPMD", &
861 : [1, 1, 1], &
862 : "STRIDE 1 1 1", &
863 10278 : debug_print_level + 1)
864 10278 : CALL add_generic_openpmd_arguments(print_key)
865 10278 : CALL section_add_subsection(section, print_key)
866 10278 : CALL section_release(print_key)
867 :
868 10278 : CALL create_e_density_section(print_key, "E_DENSITY_CUBE", "cube", [2, 2, 2], "STRIDE 2 2 2", high_print_level)
869 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
870 : description="append the cube files when they already exist", &
871 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
872 10278 : CALL section_add_keyword(print_key, keyword)
873 10278 : CALL keyword_release(keyword)
874 :
875 : CALL keyword_create(keyword, __LOCATION__, name="XRD_INTERFACE", &
876 : description="It activates the print out of exponents and coefficients for the"// &
877 : " Gaussian expansion of the core densities, based on atom calculations for each kind."// &
878 : " The resulting core dansities are needed to compute the form factors."// &
879 : " If GAPW the local densities are also given in terms of a Gaussian expansion,"// &
880 : " by fitting the difference between local-fhard and local-soft density for each atom."// &
881 : " In this case the keyword SOFT_DENSITY is enabled.", &
882 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
883 10278 : CALL section_add_keyword(print_key, keyword)
884 10278 : CALL keyword_release(keyword)
885 :
886 : CALL keyword_create(keyword, __LOCATION__, name="NGAUSS", &
887 : description="Number of Gaussian functions used in the expansion of atomic (core) density", &
888 10278 : usage="NGAUSS 10", n_var=1, default_i_val=12, type_of_var=integer_t)
889 10278 : CALL section_add_keyword(print_key, keyword)
890 10278 : CALL keyword_release(keyword)
891 :
892 10278 : CALL section_add_subsection(section, print_key)
893 10278 : CALL section_release(print_key)
894 :
895 : CALL cp_print_key_section_create(print_key, __LOCATION__, "tot_density_cube", &
896 : description="Controls printing of cube files with "// &
897 : "the total density (electrons+atomic core). Note that "// &
898 : "the value of the total density is positive where the "// &
899 : "electron density dominates and negative where the core is. "// &
900 : "When GPW is enabled this will simply print the combined density "// &
901 : "of the valence electrons and charge-balanced core. In GAPW the "// &
902 : "electronic density (hard+soft plus a correction term) is printed "// &
903 : "together with the charge-balanced core density to produce a complete "// &
904 : "representation of the total density.", &
905 10278 : print_level=high_print_level, filename="")
906 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
907 : description="The stride (X,Y,Z) used to write the cube file "// &
908 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
909 : " 1 number valid for all components.", &
910 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
911 10278 : CALL section_add_keyword(print_key, keyword)
912 10278 : CALL keyword_release(keyword)
913 :
914 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
915 : description="append the cube files when they already exist", &
916 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
917 10278 : CALL section_add_keyword(print_key, keyword)
918 10278 : CALL keyword_release(keyword)
919 :
920 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
921 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
922 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
923 10278 : CALL section_add_keyword(print_key, keyword)
924 10278 : CALL keyword_release(keyword)
925 :
926 10278 : CALL section_add_subsection(section, print_key)
927 10278 : CALL section_release(print_key)
928 :
929 : CALL cp_print_key_section_create(print_key, __LOCATION__, "v_hartree_cube", &
930 : description="Controls the printing of a cube file with eletrostatic"// &
931 : " potential generated by the total density (electrons+ions). It is"// &
932 : " valid only for QS with GPW formalism."// &
933 : " Note that by convention the potential has opposite sign than the expected physical one.", &
934 10278 : print_level=high_print_level, filename="")
935 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
936 : description="The stride (X,Y,Z) used to write the cube file "// &
937 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
938 : " 1 number valid for all components.", &
939 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
940 10278 : CALL section_add_keyword(print_key, keyword)
941 10278 : CALL keyword_release(keyword)
942 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
943 : description="append the cube files when they already exist", &
944 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
945 10278 : CALL section_add_keyword(print_key, keyword)
946 10278 : CALL keyword_release(keyword)
947 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
948 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
949 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
950 10278 : CALL section_add_keyword(print_key, keyword)
951 10278 : CALL keyword_release(keyword)
952 :
953 10278 : CALL section_add_subsection(section, print_key)
954 10278 : CALL section_release(print_key)
955 :
956 : CALL cp_print_key_section_create(print_key, __LOCATION__, "external_potential_cube", &
957 : description="Controls the printing of a cube file with external"// &
958 : " potential from the DFT%EXTERNAL_POTENTIAL section only.", &
959 10278 : print_level=high_print_level, filename="")
960 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
961 : description="The stride (X,Y,Z) used to write the cube file "// &
962 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
963 : " 1 number valid for all components.", &
964 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
965 10278 : CALL section_add_keyword(print_key, keyword)
966 10278 : CALL keyword_release(keyword)
967 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
968 : description="append the cube files when they already exist", &
969 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
970 10278 : CALL section_add_keyword(print_key, keyword)
971 10278 : CALL keyword_release(keyword)
972 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
973 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
974 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
975 10278 : CALL section_add_keyword(print_key, keyword)
976 10278 : CALL keyword_release(keyword)
977 10278 : CALL section_add_subsection(section, print_key)
978 10278 : CALL section_release(print_key)
979 :
980 : ! Output of BQB volumetric files
981 : CALL cp_print_key_section_create(print_key, __LOCATION__, name="E_DENSITY_BQB", &
982 : description="Controls the output of the electron density to the losslessly"// &
983 : " compressed BQB file format, see [Brehm2018]"// &
984 : " (via LibBQB see <https://brehm-research.de/bqb>)."// &
985 : " Currently does not work with changing cell vector (NpT ensemble).", &
986 : print_level=debug_print_level + 1, filename="", &
987 20556 : citations=[Brehm2018])
988 :
989 : CALL keyword_create(keyword, __LOCATION__, name="SKIP_FIRST", &
990 : description="Skips the first step of a MD run (avoids duplicate step if restarted).", &
991 10278 : usage="SKIP_FIRST T", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
992 10278 : CALL section_add_keyword(print_key, keyword)
993 10278 : CALL keyword_release(keyword)
994 :
995 : CALL keyword_create(keyword, __LOCATION__, name="STORE_STEP_NUMBER", &
996 : description="Stores the step number and simulation time in the comment line of each BQB"// &
997 : " frame. Switch it off for binary compatibility with original CP2k CUBE files.", &
998 10278 : usage="STORE_STEP_NUMBER F", default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
999 10278 : CALL section_add_keyword(print_key, keyword)
1000 10278 : CALL keyword_release(keyword)
1001 :
1002 : CALL keyword_create(keyword, __LOCATION__, name="CHECK", &
1003 : description="Performs an on-the-fly decompression of each compressed BQB frame to check"// &
1004 : " whether the volumetric data exactly matches, and aborts the run if not so.", &
1005 10278 : usage="CHECK T", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1006 10278 : CALL section_add_keyword(print_key, keyword)
1007 10278 : CALL keyword_release(keyword)
1008 :
1009 : CALL keyword_create(keyword, __LOCATION__, name="OVERWRITE", &
1010 : description="Specify this keyword to overwrite the output BQB file if"// &
1011 : " it already exists. By default, the data is appended to an existing file.", &
1012 10278 : usage="OVERWRITE T", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1013 10278 : CALL section_add_keyword(print_key, keyword)
1014 10278 : CALL keyword_release(keyword)
1015 :
1016 : CALL keyword_create(keyword, __LOCATION__, name="HISTORY", &
1017 : description="Controls how many previous steps are taken into account for extrapolation in"// &
1018 : " compression. Use a value of 1 to compress the frames independently.", &
1019 10278 : usage="HISTORY 10", n_var=1, default_i_val=10, type_of_var=integer_t)
1020 10278 : CALL section_add_keyword(print_key, keyword)
1021 10278 : CALL keyword_release(keyword)
1022 :
1023 : CALL keyword_create(keyword, __LOCATION__, name="PARAMETER_KEY", &
1024 : description="Allows to supply previously optimized compression parameters via a"// &
1025 : " parameter key (alphanumeric character sequence starting with 'at')."// &
1026 : " Just leave away the 'at' sign here, because CP2k will otherwise"// &
1027 : " assume it is a variable name in the input", &
1028 10278 : usage="PARAMETER_KEY <KEY>", n_var=1, default_c_val="", type_of_var=char_t)
1029 10278 : CALL section_add_keyword(print_key, keyword)
1030 10278 : CALL keyword_release(keyword)
1031 :
1032 : CALL keyword_create(keyword, __LOCATION__, name="OPTIMIZE", &
1033 : description="Controls the time spent to optimize the parameters for compression efficiency.", &
1034 : usage="OPTIMIZE {OFF,QUICK,NORMAL,PATIENT,EXHAUSTIVE}", repeats=.FALSE., n_var=1, &
1035 : default_i_val=bqb_opt_quick, &
1036 : enum_c_vals=s2a("OFF", "QUICK", "NORMAL", "PATIENT", "EXHAUSTIVE"), &
1037 : enum_desc=s2a("No optimization (use defaults)", "Quick optimization", &
1038 : "Standard optimization", "Precise optimization", "Exhaustive optimization"), &
1039 10278 : enum_i_vals=[bqb_opt_off, bqb_opt_quick, bqb_opt_normal, bqb_opt_patient, bqb_opt_exhaustive])
1040 10278 : CALL section_add_keyword(print_key, keyword)
1041 10278 : CALL keyword_release(keyword)
1042 :
1043 10278 : CALL section_add_subsection(section, print_key)
1044 10278 : CALL section_release(print_key)
1045 :
1046 : ! Voronoi Integration via LibVori
1047 10278 : CALL create_print_voronoi_section(print_key)
1048 10278 : CALL section_add_subsection(section, print_key)
1049 10278 : CALL section_release(print_key)
1050 :
1051 : ! cube files for data generated by the implicit (generalized) Poisson solver
1052 10278 : CALL create_implicit_psolver_section(subsection)
1053 10278 : CALL section_add_subsection(section, subsection)
1054 10278 : CALL section_release(subsection)
1055 :
1056 : ! ZMP adding the print section for the v_xc cube
1057 : CALL cp_print_key_section_create(print_key, __LOCATION__, "v_xc_cube", &
1058 : description="Controls the printing of a cube file with xc"// &
1059 : " potential generated by the ZMP method (for the moment). It is"// &
1060 : " valid only for QS with GPW formalism .", &
1061 10278 : print_level=high_print_level, filename="")
1062 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
1063 : description="The stride (X,Y,Z) used to write the cube file "// &
1064 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1065 : " 1 number valid for all components.", &
1066 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1067 10278 : CALL section_add_keyword(print_key, keyword)
1068 10278 : CALL keyword_release(keyword)
1069 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1070 : description="append the cube files when they already exist", &
1071 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1072 10278 : CALL section_add_keyword(print_key, keyword)
1073 10278 : CALL keyword_release(keyword)
1074 :
1075 10278 : CALL section_add_subsection(section, print_key)
1076 10278 : CALL section_release(print_key)
1077 :
1078 : CALL cp_print_key_section_create(print_key, __LOCATION__, "efield_cube", &
1079 : description="Controls the printing of cube files with electric"// &
1080 : " field generated by the total density (electrons+ions). It is"// &
1081 : " valid only for QS with GPW formalism.", &
1082 10278 : print_level=high_print_level, filename="")
1083 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
1084 : description="The stride (X,Y,Z) used to write the cube file "// &
1085 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1086 : " 1 number valid for all components.", &
1087 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1088 10278 : CALL section_add_keyword(print_key, keyword)
1089 10278 : CALL keyword_release(keyword)
1090 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1091 : description="append the cube files when they already exist", &
1092 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1093 10278 : CALL section_add_keyword(print_key, keyword)
1094 10278 : CALL keyword_release(keyword)
1095 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
1096 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
1097 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
1098 10278 : CALL section_add_keyword(print_key, keyword)
1099 10278 : CALL keyword_release(keyword)
1100 :
1101 10278 : CALL section_add_subsection(section, print_key)
1102 10278 : CALL section_release(print_key)
1103 :
1104 : CALL create_elf_print_section(print_key, "ELF_CUBE", &
1105 : "cube", &
1106 10278 : [2, 2, 2], "STRIDE 2 2 2", high_print_level, "")
1107 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1108 : description="append the cube files when they already exist", &
1109 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1110 10278 : CALL section_add_keyword(print_key, keyword)
1111 10278 : CALL keyword_release(keyword)
1112 :
1113 10278 : CALL section_add_subsection(section, print_key)
1114 10278 : CALL section_release(print_key)
1115 :
1116 : CALL create_elf_print_section(print_key, "ELF_OPENPMD", &
1117 : "openPMD", &
1118 10278 : [1, 1, 1], "STRIDE 1 1 1", debug_print_level + 1, "")
1119 10278 : CALL add_generic_openpmd_arguments(print_key)
1120 10278 : CALL section_add_subsection(section, print_key)
1121 10278 : CALL section_release(print_key)
1122 :
1123 : CALL cp_print_key_section_create(print_key, __LOCATION__, "LOCAL_ENERGY_CUBE", &
1124 : description="Controls the printing of cube files with the local"// &
1125 : " energy. It is valid only for QS with GPW/GAPW formalism."// &
1126 : " Meta and hybrid functionals are not possible. For GAPW/GAPW_XC"// &
1127 : " and ADMM-GAPW this regular-grid cube keeps the existing soft-grid"// &
1128 : " semantics; atom-centered hard one-center terms are not projected"// &
1129 : " onto the cube grid.", &
1130 10278 : print_level=debug_print_level, filename="")
1131 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
1132 : description="The stride (X,Y,Z) used to write the cube file "// &
1133 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1134 : " 1 number valid for all components.", &
1135 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1136 10278 : CALL section_add_keyword(print_key, keyword)
1137 10278 : CALL keyword_release(keyword)
1138 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1139 : description="append the cube files when they already exist", &
1140 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1141 10278 : CALL section_add_keyword(print_key, keyword)
1142 10278 : CALL keyword_release(keyword)
1143 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
1144 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
1145 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
1146 10278 : CALL section_add_keyword(print_key, keyword)
1147 10278 : CALL keyword_release(keyword)
1148 :
1149 10278 : CALL section_add_subsection(section, print_key)
1150 10278 : CALL section_release(print_key)
1151 :
1152 : CALL cp_print_key_section_create(print_key, __LOCATION__, "LOCAL_STRESS_CUBE", &
1153 : description="Controls the printing of cube files with the local"// &
1154 : " stress. It is valid only for QS with GPW/GAPW formalism."// &
1155 : " Meta and hybrid functionals are not possible. For GAPW/GAPW_XC"// &
1156 : " and ADMM-GAPW this regular-grid cube keeps the existing soft-grid"// &
1157 : " semantics; atom-centered hard one-center terms are not projected"// &
1158 : " onto the cube grid.", &
1159 10278 : print_level=debug_print_level, filename="")
1160 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
1161 : description="The stride (X,Y,Z) used to write the cube file "// &
1162 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1163 : " 1 number valid for all components.", &
1164 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1165 10278 : CALL section_add_keyword(print_key, keyword)
1166 10278 : CALL keyword_release(keyword)
1167 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1168 : description="append the cube files when they already exist", &
1169 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1170 10278 : CALL section_add_keyword(print_key, keyword)
1171 10278 : CALL keyword_release(keyword)
1172 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
1173 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
1174 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
1175 10278 : CALL section_add_keyword(print_key, keyword)
1176 10278 : CALL keyword_release(keyword)
1177 :
1178 10278 : CALL section_add_subsection(section, print_key)
1179 10278 : CALL section_release(print_key)
1180 :
1181 : CALL cp_print_key_section_create(print_key, __LOCATION__, "DOS", &
1182 : description="Print density of states (DOS). "// &
1183 : "Projected DOS output can be enabled with PDOS.", &
1184 10278 : print_level=debug_print_level, common_iter_levels=1, filename="")
1185 :
1186 10278 : CALL add_dos_keywords(print_key, xas_mode=.FALSE.)
1187 :
1188 : CALL keyword_create(keyword, __LOCATION__, name="MP_GRID", &
1189 : description="Specify a Monkhorst-Pack grid with which to compute the density of states. "// &
1190 : "Works only for a k-point calculation", &
1191 : usage="MP_GRID {integer} {integer} {integer}", default_i_vals=[-1], &
1192 10278 : n_var=3, type_of_var=integer_t)
1193 10278 : CALL section_add_keyword(print_key, keyword)
1194 10278 : CALL keyword_release(keyword)
1195 :
1196 10278 : CALL section_add_subsection(section, print_key)
1197 10278 : CALL section_release(print_key)
1198 :
1199 10278 : CALL create_wannier_section(print_key)
1200 10278 : CALL section_add_subsection(section, print_key)
1201 10278 : CALL section_release(print_key)
1202 :
1203 : !Printing of Moments
1204 10278 : CALL create_dipoles_section(print_key, "MOMENTS", high_print_level)
1205 : CALL keyword_create( &
1206 : keyword, __LOCATION__, &
1207 : name="MAX_MOMENT", &
1208 : description="Maximum moment to be calculated. Values higher than 1 not implemented under periodic boundaries.", &
1209 : usage="MAX_MOMENT {integer}", &
1210 : repeats=.FALSE., &
1211 : n_var=1, &
1212 : type_of_var=integer_t, &
1213 10278 : default_i_val=1)
1214 10278 : CALL section_add_keyword(print_key, keyword)
1215 10278 : CALL keyword_release(keyword)
1216 : CALL keyword_create(keyword, __LOCATION__, &
1217 : name="MAGNETIC", &
1218 : description="Calculate also magnetic moments, only implemented without periodic boundaries", &
1219 : usage="MAGNETIC yes", &
1220 : repeats=.FALSE., &
1221 : n_var=1, &
1222 : default_l_val=.FALSE., &
1223 10278 : lone_keyword_l_val=.TRUE.)
1224 10278 : CALL section_add_keyword(print_key, keyword)
1225 10278 : CALL keyword_release(keyword)
1226 : CALL keyword_create(keyword, __LOCATION__, &
1227 : name="VEL_REPRS", &
1228 : description="Calculate expectation values of the el. multipole moments in their velocity "// &
1229 : "representation during RTP. Implemented up to el. quadrupole moment.", &
1230 : usage="VEL_REPRS yes", &
1231 : repeats=.FALSE., &
1232 : n_var=1, &
1233 : default_l_val=.FALSE., &
1234 10278 : lone_keyword_l_val=.TRUE.)
1235 10278 : CALL section_add_keyword(print_key, keyword)
1236 10278 : CALL keyword_release(keyword)
1237 : CALL keyword_create(keyword, __LOCATION__, &
1238 : name="COM_NL", &
1239 : description="Include non local commutator for velocity representations. "// &
1240 : "Necessary for origin independent results.", &
1241 : usage="COM_NL yes", &
1242 : repeats=.FALSE., &
1243 : n_var=1, &
1244 : default_l_val=.FALSE., &
1245 10278 : lone_keyword_l_val=.TRUE.)
1246 10278 : CALL section_add_keyword(print_key, keyword)
1247 10278 : CALL keyword_release(keyword)
1248 : CALL keyword_create(keyword, __LOCATION__, &
1249 : name="SECOND_REFERENCE_POINT", &
1250 : description="Use second reference point", &
1251 : usage="SECOND_REFERENCE_POINT .TRUE.", &
1252 : repeats=.FALSE., &
1253 : n_var=1, &
1254 : default_l_val=.FALSE., &
1255 10278 : lone_keyword_l_val=.TRUE.)
1256 10278 : CALL section_add_keyword(print_key, keyword)
1257 10278 : CALL keyword_release(keyword)
1258 : CALL keyword_create(keyword, __LOCATION__, name="REFERENCE_2", &
1259 : variants=s2a("REF_2"), &
1260 : description="Define a second reference point for the calculation of the electrostatic moment.", &
1261 : usage="REFERENCE_2 COM", &
1262 : enum_c_vals=s2a("COM", "COAC", "USER_DEFINED", "ZERO"), &
1263 : enum_desc=s2a("Use Center of Mass", &
1264 : "Use Center of Atomic Charges", &
1265 : "Use User Defined Point (Keyword:REF_POINT)", &
1266 : "Use Origin of Coordinate System"), &
1267 : enum_i_vals=[use_mom_ref_com, &
1268 : use_mom_ref_coac, &
1269 : use_mom_ref_user, &
1270 : use_mom_ref_zero], &
1271 10278 : default_i_val=use_mom_ref_zero)
1272 10278 : CALL section_add_keyword(print_key, keyword)
1273 10278 : CALL keyword_release(keyword)
1274 : CALL keyword_create(keyword, __LOCATION__, name="REFERENCE_POINT_2", &
1275 : variants=s2a("REF_POINT_2"), &
1276 : description="Fixed second reference point for the calculations of the electrostatic moment.", &
1277 : usage="REFERENCE_POINT_2 x y z", &
1278 : repeats=.FALSE., &
1279 : n_var=3, default_r_vals=[0._dp, 0._dp, 0._dp], &
1280 : type_of_var=real_t, &
1281 10278 : unit_str='bohr')
1282 10278 : CALL section_add_keyword(print_key, keyword)
1283 10278 : CALL keyword_release(keyword)
1284 : CALL keyword_create(keyword, __LOCATION__, name="MAX_NMO", &
1285 : description="Maximum number of molecular orbitals closest to the Fermi "// &
1286 : "level for which dipole matrix elements and Berry curvatures are printed "// &
1287 : "per k-point. 0 for all orbitals. Ignored if not a KPOINT calculation.", &
1288 : usage="MAX_NMO {integer}", &
1289 : repeats=.FALSE., &
1290 : n_var=1, default_i_val=10, &
1291 10278 : type_of_var=integer_t)
1292 10278 : CALL section_add_keyword(print_key, keyword)
1293 10278 : CALL keyword_release(keyword)
1294 10278 : CALL create_kpoint_set_section(subsection)
1295 10278 : CALL section_add_subsection(print_key, subsection)
1296 10278 : CALL section_release(subsection)
1297 10278 : CALL create_kpoints_section(subsection)
1298 10278 : CALL section_add_subsection(print_key, subsection)
1299 10278 : CALL section_release(subsection)
1300 : CALL keyword_create(keyword, __LOCATION__, name="KG", &
1301 : description="Print the electronic moments separately for KG subsystems", &
1302 : usage="KG .TRUE.", &
1303 : repeats=.FALSE., &
1304 : n_var=1, &
1305 : default_l_val=.FALSE., &
1306 10278 : lone_keyword_l_val=.TRUE.)
1307 10278 : CALL section_add_keyword(print_key, keyword)
1308 10278 : CALL keyword_release(keyword)
1309 10278 : CALL section_add_subsection(section, print_key)
1310 10278 : CALL section_release(print_key)
1311 :
1312 : ! Mulliken population analysis
1313 : CALL cp_print_key_section_create(print_key, __LOCATION__, "MULLIKEN", &
1314 : description="Controls the printing of the Mulliken (spin) population analysis", &
1315 : print_level=medium_print_level, filename="__STD_OUT__", &
1316 10278 : common_iter_levels=1)
1317 : CALL keyword_create( &
1318 : keyword, __LOCATION__, &
1319 : name="PRINT_GOP", &
1320 : description="Print the gross orbital populations (GOP) in addition to the gross atomic populations (GAP) "// &
1321 : "and net charges", &
1322 : usage="PRINT_GOP yes", &
1323 : repeats=.FALSE., &
1324 : n_var=1, &
1325 : default_l_val=.FALSE., &
1326 10278 : lone_keyword_l_val=.TRUE.)
1327 10278 : CALL section_add_keyword(print_key, keyword)
1328 10278 : CALL keyword_release(keyword)
1329 : CALL keyword_create( &
1330 : keyword, __LOCATION__, &
1331 : name="PRINT_ALL", &
1332 : description="Print all information including the full net AO and overlap population matrix", &
1333 : usage="PRINT_ALL yes", &
1334 : repeats=.FALSE., &
1335 : n_var=1, &
1336 : default_l_val=.FALSE., &
1337 10278 : lone_keyword_l_val=.TRUE.)
1338 10278 : CALL section_add_keyword(print_key, keyword)
1339 10278 : CALL keyword_release(keyword)
1340 10278 : CALL section_add_subsection(section, print_key)
1341 10278 : CALL section_release(print_key)
1342 :
1343 : ! Lowdin population analysis (fairly expensive to compute, so only at high)
1344 : CALL cp_print_key_section_create(print_key, __LOCATION__, "LOWDIN", &
1345 : description="Controls the printing of the Lowdin (spin) population analysis", &
1346 : print_level=high_print_level, filename="__STD_OUT__", &
1347 10278 : common_iter_levels=1)
1348 : CALL keyword_create( &
1349 : keyword, __LOCATION__, &
1350 : name="PRINT_GOP", &
1351 : description="Print the orbital populations in addition to the atomic populations and net charges", &
1352 : usage="PRINT_GOP yes", &
1353 : repeats=.FALSE., &
1354 : n_var=1, &
1355 : default_l_val=.FALSE., &
1356 10278 : lone_keyword_l_val=.TRUE.)
1357 10278 : CALL section_add_keyword(print_key, keyword)
1358 10278 : CALL keyword_release(keyword)
1359 : CALL keyword_create( &
1360 : keyword, __LOCATION__, &
1361 : name="PRINT_ALL", &
1362 : description="Print all information including the full symmetrically orthogonalised density matrix", &
1363 : usage="PRINT_ALL yes", &
1364 : repeats=.FALSE., &
1365 : n_var=1, &
1366 : default_l_val=.FALSE., &
1367 10278 : lone_keyword_l_val=.TRUE.)
1368 10278 : CALL section_add_keyword(print_key, keyword)
1369 10278 : CALL keyword_release(keyword)
1370 10278 : CALL section_add_subsection(section, print_key)
1371 10278 : CALL section_release(print_key)
1372 :
1373 : ! Hirshfeld population analysis
1374 : CALL cp_print_key_section_create(print_key, __LOCATION__, "HIRSHFELD", &
1375 : description="Controls the printing of the Hirshfeld (spin) population analysis", &
1376 : print_level=medium_print_level, filename="__STD_OUT__", &
1377 10278 : common_iter_levels=1)
1378 : CALL keyword_create(keyword, __LOCATION__, name="SELF_CONSISTENT", &
1379 : description="Calculate charges from the Hirscheld-I (self_consistent) method."// &
1380 : " This scales only the full shape function, not the added charge as in the original scheme.", &
1381 : usage="SELF_CONSISTENT yes", repeats=.FALSE., n_var=1, &
1382 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1383 10278 : CALL section_add_keyword(print_key, keyword)
1384 10278 : CALL keyword_release(keyword)
1385 : CALL keyword_create(keyword, __LOCATION__, name="SHAPE_FUNCTION", &
1386 : description="Type of shape function used for Hirshfeld partitioning.", &
1387 : usage="SHAPE_FUNCTION {Gaussian,Density}", repeats=.FALSE., n_var=1, &
1388 : default_i_val=shape_function_gaussian, &
1389 : enum_c_vals=s2a("GAUSSIAN", "DENSITY"), &
1390 : enum_desc=s2a("Single Gaussian with Colvalent radius", &
1391 : "Atomic density expanded in multiple Gaussians"), &
1392 10278 : enum_i_vals=[shape_function_gaussian, shape_function_density])
1393 10278 : CALL section_add_keyword(print_key, keyword)
1394 10278 : CALL keyword_release(keyword)
1395 : CALL keyword_create(keyword, __LOCATION__, name="REFERENCE_CHARGE", &
1396 : description="Charge of atomic partitioning function for Hirshfeld method.", &
1397 : usage="REFERENCE_CHARGE {Atomic,Mulliken}", repeats=.FALSE., n_var=1, &
1398 : default_i_val=ref_charge_atomic, &
1399 : enum_c_vals=s2a("ATOMIC", "MULLIKEN"), &
1400 : enum_desc=s2a("Use atomic core charges", "Calculate Mulliken charges"), &
1401 10278 : enum_i_vals=[ref_charge_atomic, ref_charge_mulliken])
1402 10278 : CALL section_add_keyword(print_key, keyword)
1403 10278 : CALL keyword_release(keyword)
1404 : CALL keyword_create(keyword, __LOCATION__, name="USER_RADIUS", &
1405 : description="Use user defined radii to generate Gaussians."// &
1406 : " These radii are defined by the keyword ATOMIC_RADII", &
1407 : usage="USER_RADIUS yes", repeats=.FALSE., n_var=1, &
1408 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1409 10278 : CALL section_add_keyword(print_key, keyword)
1410 10278 : CALL keyword_release(keyword)
1411 : CALL keyword_create(keyword, __LOCATION__, name="ATOMIC_RADII", &
1412 : description="Defines custom radii to setup the spherical Gaussians.", &
1413 : usage="ATOMIC_RADII {real} {real} {real}", repeats=.FALSE., &
1414 : unit_str="angstrom", &
1415 10278 : type_of_var=real_t, n_var=-1)
1416 10278 : CALL section_add_keyword(print_key, keyword)
1417 10278 : CALL keyword_release(keyword)
1418 10278 : CALL section_add_subsection(section, print_key)
1419 10278 : CALL section_release(print_key)
1420 :
1421 : ! Print EEQ Charges
1422 : CALL cp_print_key_section_create(print_key, __LOCATION__, "EEQ_CHARGES", &
1423 : description="Controls the printing of the EEQ charges", &
1424 : print_level=debug_print_level, filename="__STD_OUT__", &
1425 : common_iter_levels=1, &
1426 41112 : citations=[Pracht2019, Caldeweyher2019, Caldeweyher2020])
1427 10278 : CALL section_add_subsection(section, print_key)
1428 10278 : CALL section_release(print_key)
1429 :
1430 : ! MAO (modified atomic orbital) analysis
1431 : CALL cp_print_key_section_create(print_key, __LOCATION__, "MAO_ANALYSIS", &
1432 : description="Controls the printing of the MAO (modified atomic orbital) analysis", &
1433 : print_level=debug_print_level, filename="__STD_OUT__", &
1434 : common_iter_levels=1, &
1435 30834 : citations=[Heinzmann1976, Ehrhardt1985])
1436 : CALL keyword_create(keyword, __LOCATION__, name="EPS_FILTER", &
1437 : description="Threshold for matrix elements in MAO determination.", &
1438 : usage="EPS_FILTER reps", repeats=.FALSE., n_var=1, &
1439 10278 : default_r_val=1.e-8_dp, type_of_var=real_t)
1440 10278 : CALL section_add_keyword(print_key, keyword)
1441 10278 : CALL keyword_release(keyword)
1442 : CALL keyword_create(keyword, __LOCATION__, name="REFERENCE_BASIS", &
1443 : description="Basis set used to construct MAO's.", &
1444 : usage="REFERENCE_BASIS {ORBITAL,PRIMITIVE,EXTERNAL}", repeats=.FALSE., n_var=1, &
1445 : default_i_val=mao_basis_orb, &
1446 : enum_c_vals=s2a("ORBITAL", "PRIMITIVE", "EXTERNAL"), &
1447 : enum_desc=s2a("Use standard orbital basis set", "Construct basis from primitives of the orbital basis", &
1448 : "Read external basis (MAO)"), &
1449 10278 : enum_i_vals=[mao_basis_orb, mao_basis_prim, mao_basis_ext])
1450 10278 : CALL section_add_keyword(print_key, keyword)
1451 10278 : CALL keyword_release(keyword)
1452 : CALL keyword_create(keyword, __LOCATION__, name="PRINT_BASIS", &
1453 : description="Print out MAO reference basis.", &
1454 : usage="PRINT_BASIS {logical}", repeats=.FALSE., n_var=1, &
1455 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1456 10278 : CALL section_add_keyword(print_key, keyword)
1457 10278 : CALL keyword_release(keyword)
1458 : CALL keyword_create(keyword, __LOCATION__, name="EPS_GRAD", &
1459 : description="Threshold for gradient in MAO optimization.", &
1460 : usage="EPS_GRAD reps", repeats=.FALSE., n_var=1, &
1461 10278 : default_r_val=1.e-4_dp, type_of_var=real_t)
1462 10278 : CALL section_add_keyword(print_key, keyword)
1463 10278 : CALL keyword_release(keyword)
1464 : CALL keyword_create(keyword, __LOCATION__, name="EPS_FUNCTION", &
1465 : description="Threshold for electron defect in MAO optimization.", &
1466 : usage="EPS_FUNCTION feps", repeats=.FALSE., n_var=1, &
1467 10278 : default_r_val=1.e-3_dp, type_of_var=real_t)
1468 10278 : CALL section_add_keyword(print_key, keyword)
1469 10278 : CALL keyword_release(keyword)
1470 : CALL keyword_create(keyword, __LOCATION__, name="MAX_ITER", &
1471 : description="Maximum allowed iterations for MAO optimization.", &
1472 : usage="MAX_ITER iter", repeats=.FALSE., n_var=1, &
1473 10278 : default_i_val=0, type_of_var=integer_t)
1474 10278 : CALL section_add_keyword(print_key, keyword)
1475 10278 : CALL keyword_release(keyword)
1476 : CALL keyword_create(keyword, __LOCATION__, name="NEGLECT_ABC", &
1477 : description="Neglect 3 atom terms in MAO analysis.", &
1478 : usage="NEGLECT_ABC {logical}", repeats=.FALSE., n_var=1, &
1479 10278 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1480 10278 : CALL section_add_keyword(print_key, keyword)
1481 10278 : CALL keyword_release(keyword)
1482 : CALL keyword_create(keyword, __LOCATION__, name="AB_THRESHOLD", &
1483 : description="Threshold for printing of AB shared electron numbers.", &
1484 : usage="AB_THRESHOLD thr", repeats=.FALSE., n_var=1, &
1485 10278 : default_r_val=1.e-2_dp, type_of_var=real_t)
1486 10278 : CALL section_add_keyword(print_key, keyword)
1487 10278 : CALL keyword_release(keyword)
1488 : CALL keyword_create(keyword, __LOCATION__, name="ABC_THRESHOLD", &
1489 : description="Threshold for printing of ABC shared electron numbers.", &
1490 : usage="ABC_THRESHOLD thr", repeats=.FALSE., n_var=1, &
1491 10278 : default_r_val=1.e-5_dp, type_of_var=real_t)
1492 10278 : CALL section_add_keyword(print_key, keyword)
1493 10278 : CALL keyword_release(keyword)
1494 : CALL keyword_create(keyword, __LOCATION__, name="ANALYZE_UNASSIGNED_CHARGE", &
1495 : description="Calculate atomic contributions to the unassigned charge.", &
1496 : usage="ANALYZE_UNASSIGNED_CHARGE {logical}", repeats=.FALSE., n_var=1, &
1497 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1498 10278 : CALL section_add_keyword(print_key, keyword)
1499 10278 : CALL keyword_release(keyword)
1500 10278 : CALL section_add_subsection(section, print_key)
1501 10278 : CALL section_release(print_key)
1502 :
1503 : !Minimal localized basis analysis
1504 : CALL cp_print_key_section_create(print_key, __LOCATION__, "MINBAS_ANALYSIS", &
1505 : description="Controls the printing of the minimal localized basis analysis", &
1506 : print_level=debug_print_level, filename="__STD_OUT__", &
1507 : common_iter_levels=1, &
1508 20556 : citations=[Lu2004])
1509 : CALL keyword_create(keyword, __LOCATION__, name="EPS_FILTER", &
1510 : description="Threshold for matrix elements in basis determination.", &
1511 : usage="EPS_FILTER reps", repeats=.FALSE., n_var=1, &
1512 10278 : default_r_val=1.e-8_dp, type_of_var=real_t)
1513 10278 : CALL section_add_keyword(print_key, keyword)
1514 10278 : CALL keyword_release(keyword)
1515 : CALL keyword_create(keyword, __LOCATION__, name="FULL_ORTHOGONALIZATION", &
1516 : description="Orthogonalize the localized minimal basis.", &
1517 : usage="FULL_ORTHOGONALIZATION {logical}", repeats=.FALSE., n_var=1, &
1518 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1519 10278 : CALL section_add_keyword(print_key, keyword)
1520 10278 : CALL keyword_release(keyword)
1521 : CALL keyword_create(keyword, __LOCATION__, name="BOND_ORDER", &
1522 : description="Calculate Mayer Bond Orders.", &
1523 : usage="BOND_ORDER {logical}", repeats=.FALSE., n_var=1, &
1524 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1525 10278 : CALL section_add_keyword(print_key, keyword)
1526 10278 : CALL keyword_release(keyword)
1527 :
1528 10278 : NULLIFY (sub_print_key)
1529 : CALL cp_print_key_section_create(sub_print_key, __LOCATION__, "MINBAS_CUBE", &
1530 : description="Write the minimal basis on Cube files.", &
1531 10278 : print_level=debug_print_level + 1, add_last=add_last_numeric, filename="MINBAS")
1532 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
1533 : description="The stride (X,Y,Z) used to write the cube file "// &
1534 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1535 : " 1 number valid for all components.", &
1536 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1537 10278 : CALL section_add_keyword(sub_print_key, keyword)
1538 10278 : CALL keyword_release(keyword)
1539 : CALL keyword_create(keyword, __LOCATION__, name="ATOM_LIST", &
1540 : description="Indexes of the atoms minimal basis to be printed as cube files "// &
1541 : "This keyword can be repeated several times "// &
1542 : "(useful if you have to specify many indexes).", &
1543 : usage="ATOM_LIST 1 2", &
1544 10278 : n_var=-1, type_of_var=integer_t, repeats=.TRUE.)
1545 10278 : CALL section_add_keyword(sub_print_key, keyword)
1546 10278 : CALL keyword_release(keyword)
1547 10278 : CALL section_add_subsection(print_key, sub_print_key)
1548 10278 : CALL section_release(sub_print_key)
1549 :
1550 10278 : NULLIFY (sub_print_key)
1551 : CALL cp_print_key_section_create(sub_print_key, __LOCATION__, "MINBAS_MOLDEN", &
1552 : description="Write the minimal basis in Molden file format, for visualisation.", &
1553 10278 : print_level=debug_print_level + 1, add_last=add_last_numeric, filename="MINBAS")
1554 : CALL keyword_create(keyword, __LOCATION__, name="UNIT", &
1555 : description="Unit for coordinates and cell in the MOLDEN file.", &
1556 : usage="UNIT ANGSTROM", &
1557 : enum_c_vals=s2a("BOHR", "ANGSTROM"), &
1558 : enum_desc=s2a("Write in Bohr (AU)", "Write in Angstrom"), &
1559 : enum_i_vals=[1, 2], &
1560 10278 : default_i_val=1)
1561 10278 : CALL section_add_keyword(sub_print_key, keyword)
1562 10278 : CALL keyword_release(keyword)
1563 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_CELL", &
1564 : description="Controls whether the [Cell] block is written to the MOLDEN file.", &
1565 : usage="WRITE_CELL T", &
1566 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1567 10278 : CALL section_add_keyword(sub_print_key, keyword)
1568 10278 : CALL keyword_release(keyword)
1569 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_PSEUDO", &
1570 : description="Controls whether the [Pseudo] block is written to the MOLDEN file.", &
1571 : usage="WRITE_PSEUDO T", &
1572 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1573 10278 : CALL section_add_keyword(sub_print_key, keyword)
1574 10278 : CALL keyword_release(keyword)
1575 : CALL keyword_create(keyword, __LOCATION__, name="MARK_GHOST", &
1576 : description="Controls whether ghost atoms are marked in the [Atoms] block by "// &
1577 : "setting their atomic number to zero.", &
1578 : usage="MARK_GHOST T", &
1579 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1580 10278 : CALL section_add_keyword(sub_print_key, keyword)
1581 10278 : CALL keyword_release(keyword)
1582 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
1583 : description="Specifies the number of significant digits retained. 3 is OK for visualization.", &
1584 : usage="NDIGITS {int}", &
1585 10278 : default_i_val=3)
1586 10278 : CALL section_add_keyword(sub_print_key, keyword)
1587 10278 : CALL keyword_release(keyword)
1588 : CALL keyword_create(keyword, __LOCATION__, name="GTO_KIND", &
1589 : description="Representation of Gaussian-type orbitals", &
1590 : default_i_val=gto_spherical, &
1591 : enum_c_vals=s2a("CARTESIAN", "SPHERICAL"), &
1592 : enum_desc=s2a( &
1593 : "Cartesian Gaussian orbitals. Use with caution", &
1594 : "Spherical Gaussian orbitals. Incompatible with VMD"), &
1595 10278 : enum_i_vals=[gto_cartesian, gto_spherical])
1596 10278 : CALL section_add_keyword(sub_print_key, keyword)
1597 10278 : CALL keyword_release(keyword)
1598 10278 : CALL section_add_subsection(print_key, sub_print_key)
1599 10278 : CALL section_release(sub_print_key)
1600 :
1601 10278 : CALL section_add_subsection(section, print_key)
1602 10278 : CALL section_release(print_key)
1603 :
1604 : !Energy Decomposition Analysis
1605 : CALL cp_print_key_section_create(print_key, __LOCATION__, "ENERGY_DECOMPOSITION_ANALYSIS", &
1606 : description="Controls energy decomposition analysis", &
1607 : print_level=debug_print_level, filename="__STD_OUT__", &
1608 : common_iter_levels=1, &
1609 20556 : citations=[Eriksen2020])
1610 : CALL keyword_create(keyword, __LOCATION__, name="REFERENCE_ORB_CANONICAL", &
1611 : description="Use reference orbitals in canonical form.", &
1612 : usage="REFERENCE_ORB_CANONICAL {logical}", repeats=.FALSE., n_var=1, &
1613 10278 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1614 10278 : CALL section_add_keyword(print_key, keyword)
1615 10278 : CALL keyword_release(keyword)
1616 : CALL keyword_create(keyword, __LOCATION__, name="SKIP_LOCALIZATION", &
1617 : description="Don't localize the MOs.", &
1618 : usage="SKIP_LOCALIZATION {logical}", repeats=.FALSE., n_var=1, &
1619 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1620 10278 : CALL section_add_keyword(print_key, keyword)
1621 10278 : CALL keyword_release(keyword)
1622 : CALL keyword_create(keyword, __LOCATION__, name="DETAILED_ENERGY", &
1623 : description="Calculate detailed atomic decomposition energies.", &
1624 : usage="DETAILED_ENERGY {logical}", repeats=.FALSE., n_var=1, &
1625 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1626 10278 : CALL section_add_keyword(print_key, keyword)
1627 10278 : CALL keyword_release(keyword)
1628 : CALL keyword_create(keyword, __LOCATION__, name="EWALD_ALPHA_PARAMETER", &
1629 : description="Calculate Energy Decomposition for a specific alpha value. "// &
1630 : "alpha = 1/(2*rc**2), see GTH pseudopotentials.", &
1631 : usage="EWALD_ALPHA_PARAMETER alpha", repeats=.FALSE., n_var=1, &
1632 10278 : default_r_val=0.0_dp, type_of_var=real_t)
1633 10278 : CALL section_add_keyword(print_key, keyword)
1634 10278 : CALL keyword_release(keyword)
1635 :
1636 10278 : CALL section_add_subsection(section, print_key)
1637 10278 : CALL section_release(print_key)
1638 :
1639 : ! IAO (Intrinsic atomic orbital) analysis
1640 : CALL cp_print_key_section_create(print_key, __LOCATION__, "IAO_ANALYSIS", &
1641 : description="Controls the printing of the IAO (intrinsic atomic orbital) analysis", &
1642 : print_level=debug_print_level, filename="__STD_OUT__", &
1643 : common_iter_levels=1, &
1644 20556 : citations=[Knizia2013])
1645 : CALL keyword_create(keyword, __LOCATION__, name="EPS_SVD", &
1646 : description="Threshold for matrix inversion eigenvalues.", &
1647 : usage="EPS_SVD reps", repeats=.FALSE., n_var=1, &
1648 10278 : default_r_val=0.0_dp, type_of_var=real_t)
1649 10278 : CALL section_add_keyword(print_key, keyword)
1650 10278 : CALL keyword_release(keyword)
1651 : CALL keyword_create(keyword, __LOCATION__, name="EPS_OCC", &
1652 : description="Threshold in occupation for vectors included.", &
1653 : usage="EPS_OCC reps", repeats=.FALSE., n_var=1, &
1654 10278 : default_r_val=0.0_dp, type_of_var=real_t)
1655 10278 : CALL section_add_keyword(print_key, keyword)
1656 10278 : CALL keyword_release(keyword)
1657 : CALL keyword_create(keyword, __LOCATION__, name="ATOMIC_CHARGES", &
1658 : description="Calculate atomic charges from IAO.", &
1659 : usage="ATOMIC_CHARGES {logical}", repeats=.FALSE., n_var=1, &
1660 10278 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE., type_of_var=logical_t)
1661 10278 : CALL section_add_keyword(print_key, keyword)
1662 10278 : CALL keyword_release(keyword)
1663 : ! IAO_MOLDEN
1664 10278 : NULLIFY (sub_print_key)
1665 : CALL cp_print_key_section_create(sub_print_key, __LOCATION__, "IAO_MOLDEN", &
1666 : description="Write the IAO basis in Molden file format, for visualisation.", &
1667 10278 : print_level=debug_print_level + 1, add_last=add_last_numeric, filename="IAOBAS")
1668 : CALL keyword_create(keyword, __LOCATION__, name="UNIT", &
1669 : description="Unit for coordinates and cell in the MOLDEN file.", &
1670 : usage="UNIT ANGSTROM", &
1671 : enum_c_vals=s2a("BOHR", "ANGSTROM"), &
1672 : enum_desc=s2a("Write in Bohr (AU)", "Write in Angstrom"), &
1673 : enum_i_vals=[1, 2], &
1674 10278 : default_i_val=1)
1675 10278 : CALL section_add_keyword(sub_print_key, keyword)
1676 10278 : CALL keyword_release(keyword)
1677 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_CELL", &
1678 : description="Controls whether the [Cell] block is written to the MOLDEN file.", &
1679 : usage="WRITE_CELL T", &
1680 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1681 10278 : CALL section_add_keyword(sub_print_key, keyword)
1682 10278 : CALL keyword_release(keyword)
1683 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_PSEUDO", &
1684 : description="Controls whether the [Pseudo] block is written to the MOLDEN file.", &
1685 : usage="WRITE_PSEUDO T", &
1686 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1687 10278 : CALL section_add_keyword(sub_print_key, keyword)
1688 10278 : CALL keyword_release(keyword)
1689 : CALL keyword_create(keyword, __LOCATION__, name="MARK_GHOST", &
1690 : description="Controls whether ghost atoms are marked in the [Atoms] block by "// &
1691 : "setting their atomic number to zero.", &
1692 : usage="MARK_GHOST T", &
1693 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1694 10278 : CALL section_add_keyword(sub_print_key, keyword)
1695 10278 : CALL keyword_release(keyword)
1696 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
1697 : description="Specifies the number of significant digits retained. 3 is OK for visualization.", &
1698 : usage="NDIGITS {int}", &
1699 10278 : default_i_val=3)
1700 10278 : CALL section_add_keyword(sub_print_key, keyword)
1701 10278 : CALL keyword_release(keyword)
1702 : CALL keyword_create(keyword, __LOCATION__, name="GTO_KIND", &
1703 : description="Representation of Gaussian-type orbitals", &
1704 : default_i_val=gto_spherical, &
1705 : enum_c_vals=s2a("CARTESIAN", "SPHERICAL"), &
1706 : enum_desc=s2a( &
1707 : "Cartesian Gaussian orbitals. Use with caution", &
1708 : "Spherical Gaussian orbitals. Incompatible with VMD"), &
1709 10278 : enum_i_vals=[gto_cartesian, gto_spherical])
1710 10278 : CALL section_add_keyword(sub_print_key, keyword)
1711 10278 : CALL keyword_release(keyword)
1712 10278 : CALL section_add_subsection(print_key, sub_print_key)
1713 10278 : CALL section_release(sub_print_key)
1714 : ! IAO_CUBES
1715 10278 : NULLIFY (sub_print_key)
1716 : CALL cp_print_key_section_create(sub_print_key, __LOCATION__, "IAO_CUBES", &
1717 : description="Controls the printing of the IAO basis "// &
1718 : "as *.cube files.", &
1719 : print_level=high_print_level, common_iter_levels=1, &
1720 10278 : add_last=add_last_numeric, filename="")
1721 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
1722 : description="The stride (X,Y,Z) used to write the cube file "// &
1723 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1724 : " 1 number valid for all components.", &
1725 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1726 10278 : CALL section_add_keyword(sub_print_key, keyword)
1727 10278 : CALL keyword_release(keyword)
1728 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1729 : description="append the cube files when they already exist", &
1730 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1731 10278 : CALL section_add_keyword(sub_print_key, keyword)
1732 10278 : CALL keyword_release(keyword)
1733 : CALL keyword_create(keyword, __LOCATION__, name="ATOM_LIST", &
1734 : description="Indices of the atoms to be included in basis CUBE file printing. ", &
1735 : usage="ATOM_LIST {integer} {integer} .. {integer} ", &
1736 10278 : n_var=-1, type_of_var=integer_t, repeats=.TRUE.)
1737 10278 : CALL section_add_keyword(sub_print_key, keyword)
1738 10278 : CALL keyword_release(keyword)
1739 10278 : CALL section_add_subsection(print_key, sub_print_key)
1740 10278 : CALL section_release(sub_print_key)
1741 : ! One Center Expansion of IAO
1742 10278 : NULLIFY (sub_print_key)
1743 : CALL cp_print_key_section_create(sub_print_key, __LOCATION__, "ONE_CENTER_EXPANSION", &
1744 : description="Calculates single center expansion of IAOs ", &
1745 : print_level=high_print_level, common_iter_levels=1, &
1746 10278 : add_last=add_last_numeric, filename="")
1747 : CALL keyword_create(keyword, __LOCATION__, name="LMAX", &
1748 : description="Maximum l quantum number used in the expansion.", &
1749 10278 : usage="LMAX 2", n_var=1, default_i_val=3, type_of_var=integer_t)
1750 10278 : CALL section_add_keyword(sub_print_key, keyword)
1751 10278 : CALL keyword_release(keyword)
1752 : CALL keyword_create(keyword, __LOCATION__, name="NBAS", &
1753 : description="Max number of basis functions used in the expansion."// &
1754 : " Default is determined by the orbital basis set.", &
1755 10278 : usage="NBAS 10", n_var=1, default_i_val=-1, type_of_var=integer_t)
1756 10278 : CALL section_add_keyword(sub_print_key, keyword)
1757 10278 : CALL keyword_release(keyword)
1758 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1759 : description="Append the OCE basis files when it already exists", &
1760 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1761 10278 : CALL section_add_keyword(sub_print_key, keyword)
1762 10278 : CALL keyword_release(keyword)
1763 10278 : CALL section_add_subsection(print_key, sub_print_key)
1764 10278 : CALL section_release(sub_print_key)
1765 : ! Intrinsic Bond orbitals
1766 10278 : NULLIFY (sub_print_key)
1767 : CALL cp_print_key_section_create(sub_print_key, __LOCATION__, "BOND_ORBITALS", &
1768 : description="Calculate intrinsic bond orbitals using "// &
1769 : "localized MOs in IAO basis.", &
1770 : print_level=high_print_level, common_iter_levels=1, &
1771 10278 : add_last=add_last_numeric, filename="")
1772 :
1773 : CALL keyword_create(keyword, __LOCATION__, name="LOCALIZATION_OPERATOR", &
1774 : description="Operator to be optimized for orbital localization", &
1775 : enum_c_vals=s2a("PIPEK_MEZEY", "PIPEK_MEZEY_4", "L1NORM"), &
1776 : enum_i_vals=[do_iaoloc_pm2, do_iaoloc_pm4, do_iaoloc_l1], &
1777 : enum_desc=s2a("Use Pipek-Mezey operator (order 2)", &
1778 : "Use Pipek-Mezey operator (order 4)", &
1779 : "Use L1 norm"), &
1780 10278 : default_i_val=do_iaoloc_pm2)
1781 10278 : CALL section_add_keyword(sub_print_key, keyword)
1782 10278 : CALL keyword_release(keyword)
1783 : CALL keyword_create(keyword, __LOCATION__, name="ENERGY_LOCALIZATION_FUNCTION", &
1784 : description="Function for energy localization: f(e_i), e_i orbital energy", &
1785 : enum_c_vals=s2a("NONE", "ENERGY", "OCCUPATION"), &
1786 : enum_i_vals=[do_iaoloc_enone, do_iaoloc_energy, do_iaoloc_occ], &
1787 : enum_desc=s2a("Don't use energy localization.", &
1788 : "Use orbital energies for localization.", &
1789 : "Use occupation numbers for localization."), &
1790 10278 : default_i_val=do_iaoloc_enone)
1791 10278 : CALL section_add_keyword(sub_print_key, keyword)
1792 10278 : CALL keyword_release(keyword)
1793 : CALL keyword_create(keyword, __LOCATION__, name="ENERGY_LOCALIZATION_WEIGHT", &
1794 : description="Weight given to energy localization, using f(e_i) function", &
1795 : usage="ENERGY_LOCALIZATION_WEIGHT 0.1", n_var=1, &
1796 10278 : default_r_val=0.0_dp, type_of_var=real_t)
1797 10278 : CALL section_add_keyword(sub_print_key, keyword)
1798 10278 : CALL keyword_release(keyword)
1799 :
1800 : ! CHARGE CENTER AND SPREAD
1801 10278 : NULLIFY (subsection)
1802 : CALL cp_print_key_section_create(subsection, __LOCATION__, "CHARGE_CENTER", &
1803 : description="Calculation and printing of centers and spreads "// &
1804 : "of localized orbitals.", &
1805 : print_level=high_print_level, common_iter_levels=1, &
1806 10278 : add_last=add_last_numeric, filename="")
1807 : CALL keyword_create(keyword, __LOCATION__, name="POSITION_OPERATOR_BERRY", &
1808 : description="Use Berry phase position operator.", &
1809 : usage="POSITION_OPERATOR_BERRY T", n_var=1, &
1810 10278 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
1811 10278 : CALL section_add_keyword(subsection, keyword)
1812 10278 : CALL keyword_release(keyword)
1813 10278 : CALL section_add_subsection(sub_print_key, subsection)
1814 10278 : CALL section_release(subsection)
1815 : ! IBO_MOLDEN
1816 10278 : NULLIFY (subsection)
1817 : CALL cp_print_key_section_create(subsection, __LOCATION__, "IBO_MOLDEN", &
1818 : description="Write the IBO orbitals in Molden file format, for visualisation.", &
1819 10278 : print_level=debug_print_level + 1, add_last=add_last_numeric, filename="IBOBAS")
1820 : CALL keyword_create(keyword, __LOCATION__, name="UNIT", &
1821 : description="Unit for coordinates and cell in the MOLDEN file.", &
1822 : usage="UNIT ANGSTROM", &
1823 : enum_c_vals=s2a("BOHR", "ANGSTROM"), &
1824 : enum_desc=s2a("Write in Bohr (AU)", "Write in Angstrom"), &
1825 : enum_i_vals=[1, 2], &
1826 10278 : default_i_val=1)
1827 10278 : CALL section_add_keyword(subsection, keyword)
1828 10278 : CALL keyword_release(keyword)
1829 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_CELL", &
1830 : description="Controls whether the [Cell] block is written to the MOLDEN file.", &
1831 : usage="WRITE_CELL T", &
1832 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1833 10278 : CALL section_add_keyword(subsection, keyword)
1834 10278 : CALL keyword_release(keyword)
1835 : CALL keyword_create(keyword, __LOCATION__, name="WRITE_PSEUDO", &
1836 : description="Controls whether the [Pseudo] block is written to the MOLDEN file.", &
1837 : usage="WRITE_PSEUDO T", &
1838 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1839 10278 : CALL section_add_keyword(subsection, keyword)
1840 10278 : CALL keyword_release(keyword)
1841 : CALL keyword_create(keyword, __LOCATION__, name="MARK_GHOST", &
1842 : description="Controls whether ghost atoms are marked in the [Atoms] block by "// &
1843 : "setting their atomic number to zero.", &
1844 : usage="MARK_GHOST T", &
1845 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1846 10278 : CALL section_add_keyword(subsection, keyword)
1847 10278 : CALL keyword_release(keyword)
1848 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
1849 : description="Specifies the number of significant digits retained. 3 is OK for visualization.", &
1850 : usage="NDIGITS {int}", &
1851 10278 : default_i_val=3)
1852 10278 : CALL section_add_keyword(subsection, keyword)
1853 10278 : CALL keyword_release(keyword)
1854 : CALL keyword_create(keyword, __LOCATION__, name="GTO_KIND", &
1855 : description="Representation of Gaussian-type orbitals", &
1856 : default_i_val=gto_spherical, &
1857 : enum_c_vals=s2a("CARTESIAN", "SPHERICAL"), &
1858 : enum_desc=s2a( &
1859 : "Cartesian Gaussian orbitals. Use with caution", &
1860 : "Spherical Gaussian orbitals. Incompatible with VMD"), &
1861 10278 : enum_i_vals=[gto_cartesian, gto_spherical])
1862 10278 : CALL section_add_keyword(subsection, keyword)
1863 10278 : CALL keyword_release(keyword)
1864 10278 : CALL section_add_subsection(sub_print_key, subsection)
1865 10278 : CALL section_release(subsection)
1866 : ! IAO_CUBES
1867 10278 : NULLIFY (subsection)
1868 : CALL cp_print_key_section_create(subsection, __LOCATION__, "IBO_CUBES", &
1869 : description="Controls the printing of the IBO orbitals "// &
1870 : "as *.cube files.", &
1871 : print_level=high_print_level, common_iter_levels=1, &
1872 10278 : add_last=add_last_numeric, filename="")
1873 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
1874 : description="The stride (X,Y,Z) used to write the cube file "// &
1875 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1876 : " 1 number valid for all components.", &
1877 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1878 10278 : CALL section_add_keyword(subsection, keyword)
1879 10278 : CALL keyword_release(keyword)
1880 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
1881 : description="append the cube files when they already exist", &
1882 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1883 10278 : CALL section_add_keyword(subsection, keyword)
1884 10278 : CALL keyword_release(keyword)
1885 : CALL keyword_create(keyword, __LOCATION__, name="STATE_LIST", &
1886 : description="Indices of the orbitals to be included in IBO CUBE file printing. ", &
1887 : usage="STATE_LIST {integer} {integer} .. {integer} ", &
1888 10278 : n_var=-1, type_of_var=integer_t, repeats=.TRUE.)
1889 10278 : CALL section_add_keyword(subsection, keyword)
1890 10278 : CALL keyword_release(keyword)
1891 :
1892 10278 : CALL section_add_subsection(sub_print_key, subsection)
1893 10278 : CALL section_release(subsection)
1894 10278 : CALL section_add_subsection(print_key, sub_print_key)
1895 10278 : CALL section_release(sub_print_key)
1896 :
1897 10278 : NULLIFY (sub_print_key)
1898 : CALL cp_print_key_section_create(sub_print_key, __LOCATION__, name="IAO_OVERLAP", &
1899 : description="Controls the printout required for ROSE.", &
1900 10278 : print_level=debug_print_level, filename="CP2K_ROSE")
1901 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
1902 : description="Specify the number of digits used to print the MO information.", &
1903 10278 : default_i_val=6)
1904 10278 : CALL section_add_keyword(sub_print_key, keyword)
1905 10278 : CALL keyword_release(keyword)
1906 10278 : CALL section_add_subsection(print_key, sub_print_key)
1907 10278 : CALL section_release(sub_print_key)
1908 :
1909 10278 : CALL section_add_subsection(section, print_key)
1910 10278 : CALL section_release(print_key)
1911 : ! END OF IAO_ANALYSIS SECTION
1912 :
1913 : !DOS from density matrix
1914 : CALL cp_print_key_section_create(print_key, __LOCATION__, "ENERGY_WINDOWS", &
1915 : description="Controls the printing of the DOS from the density matrix. "// &
1916 : "This allows the calculation of the DOS even in density matrix based "// &
1917 : "REAL_TIME_PROPAGATION and LS_SCF. "// &
1918 : "However, it requires a cubically scaling diagonalization of the Hamiltonian. "// &
1919 : "Hartree-Fock NYI, values will be wrong. "// &
1920 : "Careful, the orbitals in rtp/emd are not actually eigenstates of the Hamiltonian. "// &
1921 : "Assumes absence of spin polarization (so far).", &
1922 : print_level=high_print_level, common_iter_levels=3, &
1923 : each_iter_names=s2a("MD"), each_iter_values=[100], &
1924 10278 : add_last=add_last_numeric, filename="energy-windows")
1925 : CALL keyword_create(keyword, __LOCATION__, name="N_WINDOWS", &
1926 : description="The number of energy windows.", &
1927 : usage="N_WINDOWS 200", &
1928 10278 : default_i_val=100)
1929 10278 : CALL section_add_keyword(print_key, keyword)
1930 10278 : CALL keyword_release(keyword)
1931 : CALL keyword_create(keyword, __LOCATION__, name="EPS_FILTER", &
1932 : description="Filtering threshold for sparse matrix operations.", &
1933 : usage="EPS_FILTER 1.0E-6", &
1934 10278 : default_r_val=1.0E-14_dp)
1935 10278 : CALL section_add_keyword(print_key, keyword)
1936 10278 : CALL keyword_release(keyword)
1937 : CALL keyword_create(keyword, __LOCATION__, name="RESTRICT_RANGE", &
1938 : description="Restricts the energy windows to states close to the fermi level", &
1939 : usage="RESTRICT_RANGE .TRUE.", &
1940 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1941 10278 : CALL section_add_keyword(print_key, keyword)
1942 10278 : CALL keyword_release(keyword)
1943 : CALL keyword_create(keyword, __LOCATION__, name="RANGE", &
1944 : description="If the RESTRICT_RANGE keyword is set, then all energy widnows will"// &
1945 : " be placed in an interval from from the fermi level minus to the fermi level plus this keyword", &
1946 : usage="RANGE 1", &
1947 10278 : default_r_val=1.0_dp)
1948 10278 : CALL section_add_keyword(print_key, keyword)
1949 10278 : CALL keyword_release(keyword)
1950 : CALL keyword_create(keyword, __LOCATION__, name="PRINT_CUBES", &
1951 : description="Print the energy windows to cube files", &
1952 : usage="PRINT_CUBES .TRUE.", &
1953 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1954 10278 : CALL section_add_keyword(print_key, keyword)
1955 10278 : CALL keyword_release(keyword)
1956 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
1957 : description="The stride (X,Y,Z) used to write the energy windows cube files (if enabled) "// &
1958 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1959 : " 1 number valid for all components.", &
1960 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
1961 10278 : CALL section_add_keyword(print_key, keyword)
1962 10278 : CALL keyword_release(keyword)
1963 10278 : CALL section_add_subsection(section, print_key)
1964 10278 : CALL section_release(print_key)
1965 :
1966 : ! Hamiltonian in CSR format
1967 : CALL cp_print_key_section_create(print_key, __LOCATION__, "KS_CSR_WRITE", &
1968 : description="Write the KS matrix in CSR format into a file.", &
1969 10278 : print_level=debug_print_level, filename="")
1970 : CALL keyword_create(keyword, __LOCATION__, name="Threshold", &
1971 : description="Threshold on the absolute value of the elements to be printed out. "// &
1972 : "In CP2K all the elements in a (atomic) matrix block are considered non-zero, "// &
1973 : "if the block contains at least one non-zero element.", &
1974 : usage="THRESHOLD {real}", &
1975 : repeats=.FALSE., &
1976 10278 : default_r_val=0.0_dp)
1977 10278 : CALL section_add_keyword(print_key, keyword)
1978 10278 : CALL keyword_release(keyword)
1979 : CALL keyword_create(keyword, __LOCATION__, name="Upper_triangular", &
1980 : description="Print only the upper triangular part of the matrix. ", &
1981 : usage="UPPER_TRIANGULAR {logical}", &
1982 : repeats=.FALSE., &
1983 : default_l_val=.FALSE., &
1984 10278 : lone_keyword_l_val=.TRUE.)
1985 10278 : CALL section_add_keyword(print_key, keyword)
1986 10278 : CALL keyword_release(keyword)
1987 : CALL keyword_create(keyword, __LOCATION__, name="Binary", &
1988 : description="Whether or not to generate the file in a binary format. ", &
1989 : usage="BINARY {logical}", &
1990 : repeats=.FALSE., &
1991 : default_l_val=.FALSE., &
1992 10278 : lone_keyword_l_val=.TRUE.)
1993 10278 : CALL section_add_keyword(print_key, keyword)
1994 10278 : CALL keyword_release(keyword)
1995 : CALL keyword_create(keyword, __LOCATION__, name="Real_space", &
1996 : description="Print the KS matrix in real-space instead of k-space.. ", &
1997 : usage="REAL_SPACE {logical}", &
1998 : repeats=.FALSE., &
1999 : default_l_val=.FALSE., &
2000 10278 : lone_keyword_l_val=.TRUE.)
2001 10278 : CALL section_add_keyword(print_key, keyword)
2002 10278 : CALL keyword_release(keyword)
2003 10278 : CALL section_add_subsection(section, print_key)
2004 10278 : CALL section_release(print_key)
2005 :
2006 : ! Overlap in CSR format
2007 : CALL cp_print_key_section_create(print_key, __LOCATION__, "S_CSR_WRITE", &
2008 : description="Write the overlap matrix in CSR format into a file.", &
2009 10278 : print_level=debug_print_level, filename="")
2010 : CALL keyword_create(keyword, __LOCATION__, name="Threshold", &
2011 : description="Threshold on the absolute value of the elements to be printed out. "// &
2012 : "In CP2K all the elements in a (atomic) matrix block are considered non-zero, "// &
2013 : "if the block contains at least one non-zero element.", &
2014 : usage="THRESHOLD {real}", &
2015 : repeats=.FALSE., &
2016 10278 : default_r_val=0.0_dp)
2017 10278 : CALL section_add_keyword(print_key, keyword)
2018 10278 : CALL keyword_release(keyword)
2019 : CALL keyword_create(keyword, __LOCATION__, name="Upper_triangular", &
2020 : description="Print only the upper triangular part of the matrix. ", &
2021 : usage="UPPER_TRIANGULAR {logical}", &
2022 : repeats=.FALSE., &
2023 : default_l_val=.FALSE., &
2024 10278 : lone_keyword_l_val=.TRUE.)
2025 10278 : CALL section_add_keyword(print_key, keyword)
2026 10278 : CALL keyword_release(keyword)
2027 : CALL keyword_create(keyword, __LOCATION__, name="Binary", &
2028 : description="Whether or not to generate the file in a binary format. ", &
2029 : usage="BINARY {logical}", &
2030 : repeats=.FALSE., &
2031 : default_l_val=.FALSE., &
2032 10278 : lone_keyword_l_val=.TRUE.)
2033 10278 : CALL section_add_keyword(print_key, keyword)
2034 10278 : CALL keyword_release(keyword)
2035 : CALL keyword_create(keyword, __LOCATION__, name="Real_space", &
2036 : description="Print the overlap matrix in real-space instead of k-space.. ", &
2037 : usage="REAL_SPACE {logical}", &
2038 : repeats=.FALSE., &
2039 : default_l_val=.FALSE., &
2040 10278 : lone_keyword_l_val=.TRUE.)
2041 10278 : CALL section_add_keyword(print_key, keyword)
2042 10278 : CALL keyword_release(keyword)
2043 10278 : CALL section_add_subsection(section, print_key)
2044 10278 : CALL section_release(print_key)
2045 :
2046 : ! Core Hamiltonian in CSR format
2047 : CALL cp_print_key_section_create(print_key, __LOCATION__, "HCORE_CSR_WRITE", &
2048 : description="Write the core Hamiltonian matrix in CSR format into a file.", &
2049 10278 : print_level=debug_print_level, filename="")
2050 : CALL keyword_create(keyword, __LOCATION__, name="Threshold", &
2051 : description="Threshold on the absolute value of the elements to be printed out. "// &
2052 : "In CP2K all the elements in a (atomic) matrix block are considered non-zero, "// &
2053 : "if the block contains at least one non-zero element.", &
2054 : usage="THRESHOLD {real}", &
2055 : repeats=.FALSE., &
2056 10278 : default_r_val=0.0_dp)
2057 10278 : CALL section_add_keyword(print_key, keyword)
2058 10278 : CALL keyword_release(keyword)
2059 : CALL keyword_create(keyword, __LOCATION__, name="Upper_triangular", &
2060 : description="Print only the upper triangular part of the matrix. ", &
2061 : usage="UPPER_TRIANGULAR {logical}", &
2062 : repeats=.FALSE., &
2063 : default_l_val=.FALSE., &
2064 10278 : lone_keyword_l_val=.TRUE.)
2065 10278 : CALL section_add_keyword(print_key, keyword)
2066 10278 : CALL keyword_release(keyword)
2067 : CALL keyword_create(keyword, __LOCATION__, name="Binary", &
2068 : description="Whether or not to generate the file in a binary format. ", &
2069 : usage="BINARY {logical}", &
2070 : repeats=.FALSE., &
2071 : default_l_val=.FALSE., &
2072 10278 : lone_keyword_l_val=.TRUE.)
2073 10278 : CALL section_add_keyword(print_key, keyword)
2074 10278 : CALL keyword_release(keyword)
2075 : CALL keyword_create(keyword, __LOCATION__, name="Real_space", &
2076 : description="Print the core Hamiltonian matrix in real-space instead of k-space.. ", &
2077 : usage="REAL_SPACE {logical}", &
2078 : repeats=.FALSE., &
2079 : default_l_val=.FALSE., &
2080 10278 : lone_keyword_l_val=.TRUE.)
2081 10278 : CALL section_add_keyword(print_key, keyword)
2082 10278 : CALL keyword_release(keyword)
2083 10278 : CALL section_add_subsection(section, print_key)
2084 10278 : CALL section_release(print_key)
2085 :
2086 : ! Density Matrix in CSR format
2087 : CALL cp_print_key_section_create(print_key, __LOCATION__, "P_CSR_WRITE", &
2088 : description="Write the density matrix in CSR format into a file.", &
2089 10278 : print_level=debug_print_level, filename="")
2090 : CALL keyword_create(keyword, __LOCATION__, name="Threshold", &
2091 : description="Threshold on the absolute value of the elements to be printed out. "// &
2092 : "In CP2K all the elements in a (atomic) matrix block are considered non-zero, "// &
2093 : "if the block contains at least one non-zero element.", &
2094 : usage="THRESHOLD {real}", &
2095 : repeats=.FALSE., &
2096 10278 : default_r_val=0.0_dp)
2097 10278 : CALL section_add_keyword(print_key, keyword)
2098 10278 : CALL keyword_release(keyword)
2099 : CALL keyword_create(keyword, __LOCATION__, name="Upper_triangular", &
2100 : description="Print only the upper triangular part of the matrix. ", &
2101 : usage="UPPER_TRIANGULAR {logical}", &
2102 : repeats=.FALSE., &
2103 : default_l_val=.FALSE., &
2104 10278 : lone_keyword_l_val=.TRUE.)
2105 10278 : CALL section_add_keyword(print_key, keyword)
2106 10278 : CALL keyword_release(keyword)
2107 : CALL keyword_create(keyword, __LOCATION__, name="Binary", &
2108 : description="Whether or not to generate the file in a binary format. ", &
2109 : usage="BINARY {logical}", &
2110 : repeats=.FALSE., &
2111 : default_l_val=.FALSE., &
2112 10278 : lone_keyword_l_val=.TRUE.)
2113 10278 : CALL section_add_keyword(print_key, keyword)
2114 10278 : CALL keyword_release(keyword)
2115 : CALL keyword_create(keyword, __LOCATION__, name="Real_space", &
2116 : description="Print the density matrix in real-space instead of k-space.. ", &
2117 : usage="REAL_SPACE {logical}", &
2118 : repeats=.FALSE., &
2119 : default_l_val=.FALSE., &
2120 10278 : lone_keyword_l_val=.TRUE.)
2121 10278 : CALL section_add_keyword(print_key, keyword)
2122 10278 : CALL keyword_release(keyword)
2123 10278 : CALL section_add_subsection(section, print_key)
2124 10278 : CALL section_release(print_key)
2125 :
2126 : ! interaction adjacency matrix
2127 : CALL cp_print_key_section_create(print_key, __LOCATION__, "ADJMAT_WRITE", &
2128 : description="Writes an (upper-triangular) adjacency matrix indicating the "// &
2129 : "interaction between atoms (according to overlapping basis functions). The "// &
2130 : "columns are: iatom, jatom, ikind, jkind; where iatom and jatom are the atom "// &
2131 : "indices (based on the coordinate file), ikind and jkind are the atomic kinds "// &
2132 : "(indeces as shown in the ATOMIC KIND INFORMATION section of a CP2K output). ", &
2133 10278 : print_level=debug_print_level, filename="")
2134 10278 : CALL section_add_subsection(section, print_key)
2135 10278 : CALL section_release(print_key)
2136 :
2137 : ! Xray diffraction
2138 : CALL cp_print_key_section_create( &
2139 : print_key, __LOCATION__, name="XRAY_DIFFRACTION_SPECTRUM", &
2140 : description="Calculate and print the coherent X-ray "// &
2141 : "diffraction spectrum", &
2142 : print_level=debug_print_level, &
2143 : filename="", &
2144 30834 : citations=[Krack2000, Krack2002])
2145 : CALL keyword_create( &
2146 : keyword, __LOCATION__, &
2147 : name="Q_MAX", &
2148 : variants=["Q_MAXIMUM"], &
2149 : description="Maximum Q value calculated for the spectrum", &
2150 : usage="Q_MAX {real}", &
2151 : repeats=.FALSE., &
2152 : n_var=1, &
2153 : type_of_var=real_t, &
2154 : default_r_val=cp_unit_to_cp2k(value=20.0_dp, &
2155 : unit_str="angstrom^-1"), &
2156 20556 : unit_str="angstrom^-1")
2157 10278 : CALL section_add_keyword(print_key, keyword)
2158 10278 : CALL keyword_release(keyword)
2159 10278 : CALL section_add_subsection(section, print_key)
2160 10278 : CALL section_release(print_key)
2161 :
2162 : CALL cp_print_key_section_create(print_key, __LOCATION__, name="ELECTRIC_FIELD_GRADIENT", &
2163 : description="Calculate and print the electric field gradients "// &
2164 : "at atomic positions", &
2165 : print_level=debug_print_level, &
2166 10278 : filename="__STD_OUT__")
2167 :
2168 : CALL keyword_create(keyword, __LOCATION__, &
2169 : name="INTERPOLATION", &
2170 : description="Use interpolation method from real space grid", &
2171 : usage="INTERPOLATION {logical}", &
2172 : repeats=.FALSE., &
2173 : n_var=1, &
2174 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2175 10278 : CALL section_add_keyword(print_key, keyword)
2176 10278 : CALL keyword_release(keyword)
2177 :
2178 : CALL keyword_create(keyword, __LOCATION__, &
2179 : name="GSPACE_SMOOTHING", &
2180 : description="Use a G-space smoothing function", &
2181 : usage="GSPACE_SMOOTHING cutoff {real}, width {real}", &
2182 : repeats=.FALSE., &
2183 : n_var=2, default_r_vals=[-1._dp, -1._dp], &
2184 10278 : type_of_var=real_t)
2185 10278 : CALL section_add_keyword(print_key, keyword)
2186 10278 : CALL keyword_release(keyword)
2187 :
2188 : CALL keyword_create(keyword, __LOCATION__, &
2189 : name="DEBUG", &
2190 : description="Print additional debug output", &
2191 : usage="DEBUG {logical}", &
2192 : repeats=.FALSE., &
2193 : n_var=1, &
2194 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2195 10278 : CALL section_add_keyword(print_key, keyword)
2196 10278 : CALL keyword_release(keyword)
2197 :
2198 10278 : CALL create_gspace_interp_section(subsection)
2199 10278 : CALL section_add_subsection(print_key, subsection)
2200 10278 : CALL section_release(subsection)
2201 :
2202 10278 : CALL section_add_subsection(section, print_key)
2203 10278 : CALL section_release(print_key)
2204 :
2205 : CALL cp_print_key_section_create(print_key, __LOCATION__, name="BASIS_MOLOPT_QUANTITIES", &
2206 : description="Print the two quantities needed in the basis molopt generation:"// &
2207 : " total energy and condition number of the overlap matrix (S matrix)", &
2208 : print_level=debug_print_level, &
2209 10278 : filename="__STD_OUT__")
2210 10278 : CALL section_add_subsection(section, print_key)
2211 10278 : CALL section_release(print_key)
2212 :
2213 : CALL cp_print_key_section_create(print_key, __LOCATION__, name="HYPERFINE_COUPLING_TENSOR", &
2214 : description="Calculate and print the EPR hyperfine coupling tensor"// &
2215 : " at atomic positions", &
2216 : print_level=debug_print_level, &
2217 10278 : filename="__STD_OUT__")
2218 :
2219 : CALL keyword_create(keyword, __LOCATION__, &
2220 : name="INTERACTION_RADIUS", &
2221 : description="Radius of interaction for EPR hyperfine tensor calculation", &
2222 : usage="INTERACTION_RADIUS radius {real}", &
2223 : repeats=.FALSE., &
2224 : n_var=1, default_r_val=10._dp, &
2225 10278 : type_of_var=real_t)
2226 10278 : CALL section_add_keyword(print_key, keyword)
2227 10278 : CALL keyword_release(keyword)
2228 :
2229 10278 : CALL section_add_subsection(section, print_key)
2230 10278 : CALL section_release(print_key)
2231 :
2232 : CALL cp_print_key_section_create(print_key, __LOCATION__, name="OPTIMIZE_LRI_BASIS", &
2233 : description="Optimize the exponents of the LRI basis set", &
2234 : print_level=low_print_level, &
2235 10278 : filename="OPTIMIZED_LRI_BASIS")
2236 10278 : CALL section_add_subsection(section, print_key)
2237 10278 : CALL section_release(print_key)
2238 :
2239 : CALL cp_print_key_section_create( &
2240 : print_key, __LOCATION__, name="PLUS_U", &
2241 : description="Controls the printing for the DFT+U methods", &
2242 : print_level=high_print_level, &
2243 : filename="__STD_OUT__", &
2244 : each_iter_names=s2a("QS_SCF"), &
2245 : each_iter_values=[0], &
2246 30834 : citations=[Dudarev1997, Dudarev1998])
2247 10278 : CALL section_add_subsection(section, print_key)
2248 10278 : CALL section_release(print_key)
2249 :
2250 : CALL cp_print_key_section_create( &
2251 : print_key, __LOCATION__, name="CHARGEMOL", &
2252 : description="Write .wfx input file for Chargemol", &
2253 : print_level=debug_print_level + 1, &
2254 : filename="CHARGEMOL", &
2255 10278 : add_last=add_last_numeric)
2256 : CALL keyword_create(keyword, __LOCATION__, name="BACKUP_COPIES", &
2257 : description="Specifies the maximum number of backup copies.", &
2258 : usage="BACKUP_COPIES {int}", &
2259 10278 : default_i_val=1)
2260 10278 : CALL section_add_keyword(print_key, keyword)
2261 10278 : CALL keyword_release(keyword)
2262 : CALL keyword_create(keyword, __LOCATION__, name="PERIODIC", &
2263 : description="Write information about cell periodicity.", &
2264 : usage="PERIODIC {LOGICAL}", &
2265 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2266 10278 : CALL section_add_keyword(print_key, keyword)
2267 10278 : CALL keyword_release(keyword)
2268 10278 : CALL section_add_subsection(section, print_key)
2269 10278 : CALL section_release(print_key)
2270 :
2271 : CALL cp_print_key_section_create( &
2272 : print_key, __LOCATION__, name="SCCS", &
2273 : description="Controls the printing for the SCCS models", &
2274 : print_level=high_print_level, &
2275 : filename="__STD_OUT__", &
2276 : each_iter_names=s2a("QS_SCF"), &
2277 : each_iter_values=[0], &
2278 41112 : citations=[Fattebert2002, Andreussi2012, Yin2017])
2279 :
2280 10278 : NULLIFY (sub_print_key)
2281 :
2282 : CALL cp_print_key_section_create( &
2283 : sub_print_key, __LOCATION__, name="DENSITY_GRADIENT", &
2284 : description="Controls the printing of the cube files with "// &
2285 : "the norm of the density gradient |∇ρ| "// &
2286 : "used by the SCCS model.", &
2287 : print_level=debug_print_level, &
2288 : filename="", &
2289 : each_iter_names=s2a("QS_SCF"), &
2290 10278 : each_iter_values=[0])
2291 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
2292 : description="The stride (X,Y,Z) used to write the cube file "// &
2293 : "(larger values result in smaller cube files). You can provide 3 "// &
2294 : "numbers (for X,Y,Z) or 1 number valid for all components.", &
2295 : n_var=-1, &
2296 : default_i_vals=[2, 2, 2], &
2297 : type_of_var=integer_t, &
2298 10278 : repeats=.FALSE.)
2299 10278 : CALL section_add_keyword(sub_print_key, keyword)
2300 10278 : CALL keyword_release(keyword)
2301 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
2302 : description="Append the cube files when they already exist", &
2303 : default_l_val=.FALSE., &
2304 : lone_keyword_l_val=.TRUE., &
2305 10278 : repeats=.FALSE.)
2306 10278 : CALL section_add_keyword(sub_print_key, keyword)
2307 10278 : CALL keyword_release(keyword)
2308 10278 : CALL section_add_subsection(print_key, sub_print_key)
2309 10278 : CALL section_release(sub_print_key)
2310 :
2311 : CALL cp_print_key_section_create( &
2312 : sub_print_key, __LOCATION__, name="DIELECTRIC_FUNCTION", &
2313 : description="Controls the printing of the cube files with "// &
2314 : "the dielectric function used by the SCCS model. "// &
2315 : "This function determines the cavity formed by a solute in "// &
2316 : "a solvent and thus it can be used for the visualisaton of the cavity.", &
2317 : print_level=debug_print_level, &
2318 : filename="", &
2319 : each_iter_names=s2a("QS_SCF"), &
2320 : each_iter_values=[0], &
2321 41112 : citations=[Fattebert2002, Andreussi2012, Yin2017])
2322 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
2323 : description="The stride (X,Y,Z) used to write the cube file "// &
2324 : "(larger values result in smaller cube files). You can provide 3 "// &
2325 : "numbers (for X,Y,Z) or 1 number valid for all components.", &
2326 : n_var=-1, &
2327 : default_i_vals=[2, 2, 2], &
2328 : type_of_var=integer_t, &
2329 10278 : repeats=.FALSE.)
2330 10278 : CALL section_add_keyword(sub_print_key, keyword)
2331 10278 : CALL keyword_release(keyword)
2332 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
2333 : description="Append the cube files when they already exist", &
2334 : default_l_val=.FALSE., &
2335 : lone_keyword_l_val=.TRUE., &
2336 10278 : repeats=.FALSE.)
2337 10278 : CALL section_add_keyword(sub_print_key, keyword)
2338 10278 : CALL keyword_release(keyword)
2339 10278 : CALL section_add_subsection(print_key, sub_print_key)
2340 10278 : CALL section_release(sub_print_key)
2341 :
2342 : CALL cp_print_key_section_create( &
2343 : sub_print_key, __LOCATION__, name="TOTAL_CHARGE_DENSITY", &
2344 : description="Controls the printing of the cube files with the "// &
2345 : "total charge density $\rho^\text{tot}$ used by the SCCS model.", &
2346 : print_level=debug_print_level, &
2347 : filename="", &
2348 : each_iter_names=s2a("QS_SCF"), &
2349 : each_iter_values=[0], &
2350 41112 : citations=[Fattebert2002, Andreussi2012, Yin2017])
2351 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
2352 : description="The stride (X,Y,Z) used to write the cube file "// &
2353 : "(larger values result in smaller cube files). You can provide 3 "// &
2354 : "numbers (for X,Y,Z) or 1 number valid for all components.", &
2355 : n_var=-1, &
2356 : default_i_vals=[2, 2, 2], &
2357 : type_of_var=integer_t, &
2358 10278 : repeats=.FALSE.)
2359 10278 : CALL section_add_keyword(sub_print_key, keyword)
2360 10278 : CALL keyword_release(keyword)
2361 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
2362 : description="Append the cube files when they already exist", &
2363 : default_l_val=.FALSE., &
2364 : lone_keyword_l_val=.TRUE., &
2365 10278 : repeats=.FALSE.)
2366 10278 : CALL section_add_keyword(sub_print_key, keyword)
2367 10278 : CALL keyword_release(keyword)
2368 10278 : CALL section_add_subsection(print_key, sub_print_key)
2369 10278 : CALL section_release(sub_print_key)
2370 :
2371 : CALL cp_print_key_section_create( &
2372 : sub_print_key, __LOCATION__, name="POLARISATION_CHARGE_DENSITY", &
2373 : description="Controls the printing of the cube files with the "// &
2374 : "polarisation charge density $\rho^\text{pol}$ used by the SCCS model with the "// &
2375 : "total charge density $\rho^\text{tot} = \rho^\text{sol} + \rho^\text{pol}", &
2376 : print_level=debug_print_level, &
2377 : filename="", &
2378 : each_iter_names=s2a("QS_SCF"), &
2379 : each_iter_values=[0], &
2380 41112 : citations=[Fattebert2002, Andreussi2012, Yin2017])
2381 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
2382 : description="The stride (X,Y,Z) used to write the cube file "// &
2383 : "(larger values result in smaller cube files). You can provide 3 "// &
2384 : "numbers (for X,Y,Z) or 1 number valid for all components.", &
2385 : n_var=-1, &
2386 : default_i_vals=[2, 2, 2], &
2387 : type_of_var=integer_t, &
2388 10278 : repeats=.FALSE.)
2389 10278 : CALL section_add_keyword(sub_print_key, keyword)
2390 10278 : CALL keyword_release(keyword)
2391 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
2392 : description="Append the cube files when they already exist", &
2393 : default_l_val=.FALSE., &
2394 : lone_keyword_l_val=.TRUE., &
2395 10278 : repeats=.FALSE.)
2396 10278 : CALL section_add_keyword(sub_print_key, keyword)
2397 10278 : CALL keyword_release(keyword)
2398 10278 : CALL section_add_subsection(print_key, sub_print_key)
2399 10278 : CALL section_release(sub_print_key)
2400 :
2401 : CALL cp_print_key_section_create( &
2402 : sub_print_key, __LOCATION__, name="POLARISATION_POTENTIAL", &
2403 : description="Controls the printing of the cube files with the "// &
2404 : "polarisation potential $\phi^\text{pol}$ used by the SCCS model with the "// &
2405 : "total potential $\phi^\text{tot} = \phi^\text{sol} + \phi^\text{pol}$", &
2406 : print_level=debug_print_level, &
2407 : filename="", &
2408 : each_iter_names=s2a("QS_SCF"), &
2409 : each_iter_values=[0], &
2410 41112 : citations=[Fattebert2002, Andreussi2012, Yin2017])
2411 : CALL keyword_create(keyword, __LOCATION__, name="STRIDE", &
2412 : description="The stride (X,Y,Z) used to write the cube file "// &
2413 : "(larger values result in smaller cube files). You can provide 3 "// &
2414 : "numbers (for X,Y,Z) or 1 number valid for all components.", &
2415 : n_var=-1, &
2416 : default_i_vals=[2, 2, 2], &
2417 : type_of_var=integer_t, &
2418 10278 : repeats=.FALSE.)
2419 10278 : CALL section_add_keyword(sub_print_key, keyword)
2420 10278 : CALL keyword_release(keyword)
2421 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
2422 : description="Append the cube files when they already exist", &
2423 : default_l_val=.FALSE., &
2424 : lone_keyword_l_val=.TRUE., &
2425 10278 : repeats=.FALSE.)
2426 10278 : CALL section_add_keyword(sub_print_key, keyword)
2427 10278 : CALL keyword_release(keyword)
2428 10278 : CALL section_add_subsection(print_key, sub_print_key)
2429 10278 : CALL section_release(sub_print_key)
2430 :
2431 10278 : CALL section_add_subsection(section, print_key)
2432 10278 : CALL section_release(print_key)
2433 :
2434 10278 : END SUBROUTINE create_print_dft_section
2435 :
2436 : ! **************************************************************************************************
2437 : !> \brief ...
2438 : !> \param section ...
2439 : !> \author JGH
2440 : ! **************************************************************************************************
2441 10278 : SUBROUTINE create_bandstructure_section(section)
2442 : TYPE(section_type), POINTER :: section
2443 :
2444 : TYPE(keyword_type), POINTER :: keyword
2445 : TYPE(section_type), POINTER :: subsection
2446 :
2447 10278 : CPASSERT(.NOT. ASSOCIATED(section))
2448 : CALL section_create(section, __LOCATION__, name="BAND_STRUCTURE", &
2449 : description="Specifies the k-points used in band structure calculation.", &
2450 10278 : n_keywords=0, n_subsections=0, repeats=.FALSE.)
2451 :
2452 10278 : NULLIFY (keyword)
2453 : CALL keyword_create(keyword, __LOCATION__, name="FILE_NAME", &
2454 : description="File name used for band structure", &
2455 : usage="FILE_NAME <filename>", default_c_val="", &
2456 10278 : type_of_var=char_t, n_var=1)
2457 10278 : CALL section_add_keyword(section, keyword)
2458 10278 : CALL keyword_release(keyword)
2459 :
2460 : CALL keyword_create(keyword, __LOCATION__, name="ADDED_MOS", &
2461 : variants=["ADDED_BANDS"], &
2462 : description="Number of MOs/Bands added to the Band Structure calculation.", &
2463 20556 : default_i_val=0)
2464 10278 : CALL section_add_keyword(section, keyword)
2465 10278 : CALL keyword_release(keyword)
2466 :
2467 10278 : NULLIFY (subsection)
2468 10278 : CALL create_kpoint_set_section(subsection)
2469 10278 : CALL section_add_subsection(section, subsection)
2470 10278 : CALL section_release(subsection)
2471 :
2472 10278 : END SUBROUTINE create_bandstructure_section
2473 :
2474 30834 : SUBROUTINE add_generic_openpmd_arguments(print_key)
2475 : TYPE(section_type), POINTER :: print_key
2476 :
2477 : TYPE(keyword_type), POINTER :: keyword
2478 30834 : NULLIFY (keyword)
2479 :
2480 : CALL keyword_create(keyword, __LOCATION__, name="OPENPMD_EXTENSION", &
2481 : description="Filename extension for openPMD files, including the dot and "// &
2482 : "(for optionally activating file encoding) a file expansion pattern.", &
2483 : default_c_val="_%06T."//cp_openpmd_get_default_extension(), &
2484 30834 : type_of_var=char_t)
2485 30834 : CALL section_add_keyword(print_key, keyword)
2486 30834 : CALL keyword_release(keyword)
2487 :
2488 : CALL keyword_create(keyword, __LOCATION__, name="OPENPMD_CFG", &
2489 : description="Inline runtime config for openPMD output. Note that inline "// &
2490 : "specifications are subject to restrictions imposed by the input "// &
2491 : "file format, making this option useful only for very simple use cases. "// &
2492 : "Refer to OPENPMD_CFG_FILE for anything else.", &
2493 30834 : default_c_val="{}", type_of_var=char_t)
2494 30834 : CALL section_add_keyword(print_key, keyword)
2495 30834 : CALL keyword_release(keyword)
2496 :
2497 : CALL keyword_create(keyword, __LOCATION__, name="OPENPMD_CFG_FILE", &
2498 : description="Runtime config file for openPMD output. This parameter takes precedence over OPENPMD_CFG.", default_c_val="", &
2499 30834 : type_of_var=char_t)
2500 30834 : CALL section_add_keyword(print_key, keyword)
2501 30834 : CALL keyword_release(keyword)
2502 :
2503 30834 : END SUBROUTINE add_generic_openpmd_arguments
2504 :
2505 : ! **************************************************************************************************
2506 : !> \brief creates the input section for dealing with homo lumos, including dumping cubes
2507 : !> \param print_key ...
2508 : ! **************************************************************************************************
2509 20556 : SUBROUTINE create_mo_section( &
2510 : print_key, section_name, description, stride_default, stride_usage, &
2511 : print_level, do_write_keyname)
2512 :
2513 : TYPE(section_type), POINTER :: print_key
2514 : CHARACTER(len=*), INTENT(IN) :: section_name, description, stride_usage, do_write_keyname
2515 : INTEGER, DIMENSION(3), INTENT(IN) :: stride_default
2516 : INTEGER, INTENT(IN) :: print_level
2517 :
2518 : TYPE(keyword_type), POINTER :: keyword
2519 :
2520 20556 : NULLIFY (keyword)
2521 :
2522 : CALL cp_print_key_section_create(print_key, __LOCATION__, section_name, &
2523 : description="Controls the printing of the molecular orbitals (MOs) as " &
2524 : //TRIM(ADJUSTL(description))// &
2525 : " files."// &
2526 : " It can be used during a Real Time calculation to print the MOs."// &
2527 : " In this case, the density corresponding to the time dependent MO is printed"// &
2528 : " instead of the wave-function.", &
2529 20556 : print_level=print_level, filename="")
2530 :
2531 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
2532 : description="The stride (X,Y,Z) used to write the "//TRIM(ADJUSTL(description))//" file "// &
2533 : "(larger values result in smaller "// &
2534 : TRIM(ADJUSTL(description))// &
2535 : " files). You can provide 3 numbers (for X,Y,Z) or"// &
2536 : " 1 number valid for all components.", &
2537 20556 : usage=stride_usage, n_var=-1, default_i_vals=stride_default, type_of_var=integer_t)
2538 20556 : CALL section_add_keyword(print_key, keyword)
2539 20556 : CALL keyword_release(keyword)
2540 :
2541 : CALL keyword_create(keyword, __LOCATION__, name=do_write_keyname, &
2542 : description="If the MO " &
2543 : //TRIM(ADJUSTL(description)) &
2544 : //" file should be written. If false, the eigenvalues are still computed."// &
2545 : " Can also be useful in combination with STM calculations", &
2546 20556 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
2547 20556 : CALL section_add_keyword(print_key, keyword)
2548 20556 : CALL keyword_release(keyword)
2549 :
2550 : CALL keyword_create(keyword, __LOCATION__, name="nlumo", &
2551 : description="If the printkey is activated controls the number of lumos"// &
2552 : " that are printed and dumped as "//TRIM(ADJUSTL(description))//" (-1=all)", &
2553 20556 : default_i_val=0)
2554 20556 : CALL section_add_keyword(print_key, keyword)
2555 20556 : CALL keyword_release(keyword)
2556 :
2557 : CALL keyword_create( &
2558 : keyword, __LOCATION__, name="nhomo", &
2559 : description="If the printkey is activated controls the number of homos that dumped as "// &
2560 : TRIM(ADJUSTL(description))// &
2561 : " (-1=all),"// &
2562 : " eigenvalues are always all dumped", &
2563 20556 : default_i_val=1)
2564 20556 : CALL section_add_keyword(print_key, keyword)
2565 20556 : CALL keyword_release(keyword)
2566 :
2567 : CALL keyword_create( &
2568 : keyword, __LOCATION__, name="homo_list", &
2569 : description="If the printkey is activated controls the index of homos dumped as openPMD,"// &
2570 : " eigenvalues are always all dumped. It overrides nhomo.", &
2571 : usage="HOMO_LIST {integer} {integer} .. {integer} ", type_of_var=integer_t, &
2572 20556 : n_var=-1, repeats=.TRUE.)
2573 20556 : CALL section_add_keyword(print_key, keyword)
2574 20556 : CALL keyword_release(keyword)
2575 :
2576 20556 : END SUBROUTINE create_mo_section
2577 :
2578 20556 : SUBROUTINE create_e_density_section( &
2579 : print_key, section_name, description, stride_default, &
2580 : stride_usage, print_level)
2581 :
2582 : TYPE(section_type), POINTER :: print_key
2583 : CHARACTER(len=*), INTENT(IN) :: section_name, description, stride_usage
2584 : INTEGER, DIMENSION(3), INTENT(IN) :: stride_default
2585 : INTEGER, INTENT(IN) :: print_level
2586 :
2587 : TYPE(keyword_type), POINTER :: keyword
2588 :
2589 20556 : NULLIFY (keyword)
2590 :
2591 : CALL cp_print_key_section_create(print_key, __LOCATION__, name=section_name, &
2592 : description="Controls the printing of "//TRIM(ADJUSTL(description))//" files with "// &
2593 : "the electronic density and, for LSD calculations, the spin density.", &
2594 20556 : print_level=print_level, filename="")
2595 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
2596 : description="The stride (X,Y,Z) used to write the "//TRIM(ADJUSTL(description))//" file "// &
2597 : "(larger values result in smaller "// &
2598 : TRIM(ADJUSTL(description))// &
2599 : " files). You can provide 3 numbers (for X,Y,Z) or"// &
2600 : " 1 number valid for all components.", &
2601 20556 : usage=stride_usage, n_var=-1, default_i_vals=stride_default, type_of_var=integer_t)
2602 20556 : CALL section_add_keyword(print_key, keyword)
2603 20556 : CALL keyword_release(keyword)
2604 :
2605 : CALL keyword_create(keyword, __LOCATION__, name="DENSITY_INCLUDE", &
2606 : description="Which parts of the density to include. In GAPW the electronic density "// &
2607 : "is divided into a hard and a soft component, and the default (TOTAL_HARD_APPROX) "// &
2608 : "is to approximate the hard density as a spherical gaussian and to print the smooth "// &
2609 : "density accurately. This avoids potential artefacts originating from the hard density. "// &
2610 : "If the TOTAL_DENSITY keyword is used the hard density will be computed more accurately "// &
2611 : "but may introduce non-physical features. The SOFT_DENSITY keyword will lead to only the "// &
2612 : "soft density being printed. In GPW these options have no effect and the cube file will "// &
2613 : "only contain the valence electron density.", &
2614 : usage="DENSITY_INCLUDE TOTAL_HARD_APPROX", &
2615 : enum_c_vals=s2a("TOTAL_HARD_APPROX", "TOTAL_DENSITY", "SOFT_DENSITY"), &
2616 : enum_desc=s2a("Print (hard+soft) density where the hard components shape is approximated", &
2617 : "Print (hard+soft) density. Only has an effect "// &
2618 : "if PAW atoms are present. NOTE: The total "// &
2619 : "in real space might exhibit unphysical features "// &
2620 : "like spikes due to the finite and thus "// &
2621 : "truncated g vector", &
2622 : "Print only the soft density"), &
2623 : enum_i_vals=[e_dens_total_hard_approx, &
2624 : e_dens_total_density, &
2625 : e_dens_soft_density], &
2626 20556 : default_i_val=e_dens_total_hard_approx)
2627 20556 : CALL section_add_keyword(print_key, keyword)
2628 20556 : CALL keyword_release(keyword)
2629 :
2630 20556 : END SUBROUTINE create_e_density_section
2631 :
2632 : ! **************************************************************************************************
2633 : !> \brief Helper to create ELF print sections (cube or openPMD)
2634 : !> \param print_key section handle (output)
2635 : !> \param section_name name of the section (e.g. "ELF_CUBE" or "ELF_OPENPMD")
2636 : !> \param description Either "cube" or "openPMD", for the descriptions.
2637 : !> \param stride_default default stride values
2638 : !> \param stride_usage usage string for stride
2639 : !> \param print_level print level
2640 : !> \param filename output filename (empty string for default)
2641 20556 : SUBROUTINE create_elf_print_section( &
2642 : print_key, section_name, description, stride_default, stride_usage, print_level, filename)
2643 :
2644 : TYPE(section_type), POINTER :: print_key
2645 : CHARACTER(len=*), INTENT(IN) :: section_name, description, stride_usage, filename
2646 : INTEGER, DIMENSION(3), INTENT(IN) :: stride_default
2647 : INTEGER, INTENT(IN) :: print_level
2648 : TYPE(keyword_type), POINTER :: keyword
2649 :
2650 20556 : NULLIFY (keyword)
2651 :
2652 : CALL cp_print_key_section_create(print_key, __LOCATION__, section_name, &
2653 : description="Controls printing of "//TRIM(ADJUSTL(description))// &
2654 : " files with the electron localization function (ELF). "// &
2655 : "Note that the value of ELF is defined between 0 and 1: "// &
2656 : "Pauli kinetic energy density normalized by the kinetic energy density "// &
2657 20556 : "of a uniform el. gas of same density.", print_level=print_level, filename=filename)
2658 :
2659 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
2660 : description="The stride (X,Y,Z) used to write the file (larger values result in smaller files). "// &
2661 : "You can provide 3 numbers (for X,Y,Z) or 1 number valid for all components.", &
2662 20556 : usage=stride_usage, n_var=-1, default_i_vals=stride_default, type_of_var=integer_t)
2663 20556 : CALL section_add_keyword(print_key, keyword)
2664 20556 : CALL keyword_release(keyword)
2665 :
2666 : CALL keyword_create(keyword, __LOCATION__, name="density_cutoff", &
2667 : description=" ", usage="density_cutoff 0.0001", repeats=.FALSE., n_var=1, &
2668 20556 : type_of_var=real_t, default_r_val=1.0e-10_dp)
2669 20556 : CALL section_add_keyword(print_key, keyword)
2670 20556 : CALL keyword_release(keyword)
2671 20556 : END SUBROUTINE create_elf_print_section
2672 :
2673 : ! **************************************************************************************************
2674 : !> \brief Add projected-DOS related keywords to a DOS or XAS PDOS print section.
2675 : !> \param print_key print key section to add keywords to
2676 : !> \param xas_mode if true, add keywords for the XAS-specific standalone PDOS section
2677 : ! **************************************************************************************************
2678 41096 : SUBROUTINE add_dos_keywords(print_key, xas_mode)
2679 :
2680 : TYPE(section_type), POINTER :: print_key
2681 : LOGICAL, INTENT(IN) :: xas_mode
2682 :
2683 : TYPE(keyword_type), POINTER :: keyword
2684 : TYPE(section_type), POINTER :: subsection
2685 :
2686 41096 : NULLIFY (subsection)
2687 41096 : NULLIFY (keyword)
2688 :
2689 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
2690 : description="Append the DOS/PDOS obtained at different iterations to the output file. "// &
2691 : "By default the file is overwritten", &
2692 41096 : usage="APPEND", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2693 41096 : CALL section_add_keyword(print_key, keyword)
2694 41096 : CALL keyword_release(keyword)
2695 :
2696 : CALL keyword_create(keyword, __LOCATION__, name="DELTA_E", &
2697 : description="Energy spacing of the broadened DOS/PDOS output grid.", &
2698 41096 : usage="DELTA_E 0.0005", type_of_var=real_t, default_r_val=0.001_dp)
2699 41096 : CALL section_add_keyword(print_key, keyword)
2700 41096 : CALL keyword_release(keyword)
2701 :
2702 : CALL keyword_create(keyword, __LOCATION__, name="ENERGY_UNIT", &
2703 : description="Energy unit used for the printed DOS/PDOS energy axis. "// &
2704 : "For broadened spectra, intensities are converted consistently to the selected energy unit.", &
2705 : usage="ENERGY_UNIT HARTREE", type_of_var=enum_t, &
2706 : enum_c_vals=s2a("HARTREE", "EV"), &
2707 : enum_i_vals=[1, 2], &
2708 : enum_desc=s2a("Print energies in Hartree (a.u.).", &
2709 : "Print energies in electronvolt."), &
2710 41096 : default_i_val=1)
2711 41096 : CALL section_add_keyword(print_key, keyword)
2712 41096 : CALL keyword_release(keyword)
2713 :
2714 : CALL keyword_create(keyword, __LOCATION__, name="ENERGY_ZERO", &
2715 : description="Reference energy used for the printed DOS/PDOS energy axis. "// &
2716 : "With AUTO, the Fermi energy is used if smearing is enabled or fractional "// &
2717 : "occupations are found; otherwise the highest occupied crystal orbital is used.", &
2718 : usage="ENERGY_ZERO AUTO", type_of_var=enum_t, &
2719 : enum_c_vals=s2a("AUTO", "ABSOLUTE", "FERMI", "HOCO"), &
2720 : enum_i_vals=[1, 2, 3, 4], &
2721 : enum_desc=s2a("Choose FERMI for smeared or fractionally occupied systems, otherwise HOCO.", &
2722 : "Print absolute orbital energies.", &
2723 : "Shift orbital energies by the Fermi energy.", &
2724 : "Shift orbital energies by the highest occupied crystal orbital."), &
2725 41096 : default_i_val=1)
2726 41096 : CALL section_add_keyword(print_key, keyword)
2727 41096 : CALL keyword_release(keyword)
2728 :
2729 : CALL keyword_create(keyword, __LOCATION__, name="BROADEN_TYPE", &
2730 : description="Type of broadening function used to produce the DOS/PDOS curve.", &
2731 : usage="BROADEN_TYPE GAUSSIAN", type_of_var=enum_t, &
2732 : enum_c_vals=s2a("GAUSSIAN", "LORENTZIAN", "PSEUDO_VOIGT"), &
2733 : enum_i_vals=[1, 2, 3], &
2734 : enum_desc=s2a("Use a Gaussian broadening function.", &
2735 : "Use a Lorentzian broadening function.", &
2736 : "Use a pseudo-Voigt mixture of Lorentzian and Gaussian functions."), &
2737 41096 : default_i_val=1)
2738 41096 : CALL section_add_keyword(print_key, keyword)
2739 41096 : CALL keyword_release(keyword)
2740 :
2741 : CALL keyword_create(keyword, __LOCATION__, name="BROADEN_WIDTH", &
2742 : description="Full width at half maximum (FWHM) of the DOS/PDOS broadening function.", &
2743 : usage="BROADEN_WIDTH [eV] 0.1", type_of_var=real_t, &
2744 41096 : default_r_val=cp_unit_to_cp2k(value=0.1_dp, unit_str="eV"), unit_str="eV")
2745 41096 : CALL section_add_keyword(print_key, keyword)
2746 41096 : CALL keyword_release(keyword)
2747 :
2748 : CALL keyword_create(keyword, __LOCATION__, name="VOIGT_MIXING", &
2749 : description="Lorentzian fraction of the pseudo-Voigt broadening function.", &
2750 41096 : usage="VOIGT_MIXING 0.5", type_of_var=real_t, default_r_val=0.5_dp)
2751 41096 : CALL section_add_keyword(print_key, keyword)
2752 41096 : CALL keyword_release(keyword)
2753 :
2754 : CALL keyword_create(keyword, __LOCATION__, name="NDIGITS", &
2755 : description="Specify the number of digits used to print DOS/PDOS values.", &
2756 41096 : default_i_val=6)
2757 41096 : CALL section_add_keyword(print_key, keyword)
2758 41096 : CALL keyword_release(keyword)
2759 :
2760 : CALL keyword_create(keyword, __LOCATION__, name="NLUMO", &
2761 : description="Number of unoccupied orbitals to include in the DOS/PDOS (-1=all). "// &
2762 : "For OT calculations, the requested virtual orbitals are generated after SCF using the "// &
2763 : "OT eigensolver. For diagonalization calculations, SCF%ADDED_MOS is increased if needed "// &
2764 : "to make the requested unoccupied orbitals available.", &
2765 41096 : usage="NLUMO integer", default_i_val=0)
2766 41096 : CALL section_add_keyword(print_key, keyword)
2767 41096 : CALL keyword_release(keyword)
2768 :
2769 41096 : IF (.NOT. xas_mode) THEN
2770 : CALL section_create(subsection, __LOCATION__, name="PDOS", &
2771 : description="Controls the printing of kind-resolved projected DOS.", &
2772 10278 : n_keywords=2, n_subsections=0)
2773 : CALL keyword_create(keyword, __LOCATION__, name="COMPONENTS", &
2774 : description="Print out PDOS distinguishing all angular momentum components.", &
2775 10278 : usage="COMPONENTS", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2776 10278 : CALL section_add_keyword(subsection, keyword)
2777 10278 : CALL keyword_release(keyword)
2778 :
2779 : CALL keyword_create(keyword, __LOCATION__, name="RAW", &
2780 : description="Print MO-resolved projected DOS weights to *.pdos_raw.", &
2781 10278 : usage="RAW", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2782 10278 : CALL section_add_keyword(subsection, keyword)
2783 10278 : CALL keyword_release(keyword)
2784 10278 : CALL section_add_subsection(print_key, subsection)
2785 10278 : CALL section_release(subsection)
2786 : ELSE
2787 : CALL keyword_create(keyword, __LOCATION__, name="COMPONENTS", &
2788 : description="Print out PDOS distinguishing all angular momentum components.", &
2789 30818 : usage="COMPONENTS", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2790 30818 : CALL section_add_keyword(print_key, keyword)
2791 30818 : CALL keyword_release(keyword)
2792 : END IF
2793 :
2794 : CALL keyword_create(keyword, __LOCATION__, name="OUT_EACH_STATE", &
2795 : variants=["OUT_EACH_MO"], &
2796 : description="Output on the status of the calculation every OUT_EACH_MO states. If -1 no output", &
2797 82192 : usage="OUT_EACH_STATE integer", default_i_val=-1)
2798 41096 : CALL section_add_keyword(print_key, keyword)
2799 41096 : CALL keyword_release(keyword)
2800 :
2801 : CALL section_create(subsection, __LOCATION__, name="LDOS", &
2802 : description="Controls the printing of local PDOS, projected on subsets"// &
2803 : " of atoms given through lists", &
2804 41096 : n_keywords=4, n_subsections=0, repeats=.TRUE.)
2805 : CALL keyword_create(keyword, __LOCATION__, name="COMPONENTS", &
2806 : description="Print out PDOS distinguishing all angular momentum components.", &
2807 41096 : usage="COMPONENTS", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2808 41096 : CALL section_add_keyword(subsection, keyword)
2809 41096 : CALL keyword_release(keyword)
2810 : CALL keyword_create(keyword, __LOCATION__, name="LIST", &
2811 : description="Specifies a list of indexes of atoms where to project the DOS", &
2812 : usage="LIST {integer} {integer} .. {integer}", type_of_var=integer_t, &
2813 41096 : n_var=-1, repeats=.TRUE.)
2814 41096 : CALL section_add_keyword(subsection, keyword)
2815 41096 : CALL keyword_release(keyword)
2816 41096 : CALL section_add_subsection(print_key, subsection)
2817 41096 : CALL section_release(subsection)
2818 :
2819 : CALL section_create(subsection, __LOCATION__, name="R_LDOS", &
2820 : description="Controls the printing of local PDOS, projected on 3D volume in real space, "// &
2821 : "the volume is defined in terms of position with respect to atoms in the lists", &
2822 41096 : n_keywords=4, n_subsections=0, repeats=.TRUE.)
2823 : CALL keyword_create(keyword, __LOCATION__, name="LIST", &
2824 : description="Specifies a list of indexes of atoms used to define the real space volume", &
2825 : usage="LIST {integer} {integer} .. {integer}", type_of_var=integer_t, &
2826 41096 : n_var=-1, repeats=.TRUE.)
2827 41096 : CALL section_add_keyword(subsection, keyword)
2828 41096 : CALL keyword_release(keyword)
2829 : CALL keyword_create(keyword, __LOCATION__, name="XRANGE", &
2830 : description="range of positions in Cartesian direction x: all grid points within "// &
2831 : "this range from at least one atom of the list are considered", &
2832 41096 : usage="XRANGE -10.0 10.0", unit_str="angstrom", n_var=2, type_of_var=real_t)
2833 41096 : CALL section_add_keyword(subsection, keyword)
2834 41096 : CALL keyword_release(keyword)
2835 : CALL keyword_create(keyword, __LOCATION__, name="YRANGE", &
2836 : description="range of positions in Cartesian direction y: all grid points within "// &
2837 : "this range from at least one atom of the list are considered", &
2838 41096 : usage="YRANGE -10.0 10.0", unit_str="angstrom", n_var=2, type_of_var=real_t)
2839 41096 : CALL section_add_keyword(subsection, keyword)
2840 41096 : CALL keyword_release(keyword)
2841 : CALL keyword_create(keyword, __LOCATION__, name="ZRANGE", &
2842 : description="range of positions in Cartesian direction z: all grid points within "// &
2843 : "this range from at least one atom of the list are considered", &
2844 41096 : usage="ZRANGE -10.0 10.0", unit_str="angstrom", n_var=2, type_of_var=real_t)
2845 41096 : CALL section_add_keyword(subsection, keyword)
2846 41096 : CALL keyword_release(keyword)
2847 : CALL keyword_create(keyword, __LOCATION__, name="ERANGE", &
2848 : description="Only project states with the energy values in the given interval. "// &
2849 : "Default is all states.", &
2850 41096 : usage="ERANGE -1.0 1.0", unit_str="hartree", n_var=2, type_of_var=real_t)
2851 41096 : CALL section_add_keyword(subsection, keyword)
2852 41096 : CALL keyword_release(keyword)
2853 41096 : CALL section_add_subsection(print_key, subsection)
2854 41096 : CALL section_release(subsection)
2855 :
2856 41096 : END SUBROUTINE add_dos_keywords
2857 :
2858 : ! **************************************************************************************************
2859 : !> \brief Create WANNIER90 print section.
2860 : !> \param print_key print key section to create
2861 : ! **************************************************************************************************
2862 10278 : SUBROUTINE create_wannier_section(print_key)
2863 :
2864 : TYPE(section_type), POINTER :: print_key
2865 :
2866 : TYPE(keyword_type), POINTER :: keyword
2867 :
2868 10278 : NULLIFY (keyword)
2869 :
2870 : CALL cp_print_key_section_create(print_key, __LOCATION__, "WANNIER90", &
2871 : description="Interface to Wannier90 code. (EXPERIMENTAL)", &
2872 10278 : print_level=debug_print_level, common_iter_levels=1, filename="")
2873 :
2874 : CALL keyword_create(keyword, __LOCATION__, name="SEED_NAME", &
2875 : description="The seedname for the Wannier90 calculation (body of filenames).", &
2876 : usage="SEED_NAME filename", default_c_val="wannier90", &
2877 10278 : n_var=1, type_of_var=char_t)
2878 10278 : CALL section_add_keyword(print_key, keyword)
2879 10278 : CALL keyword_release(keyword)
2880 :
2881 : CALL keyword_create(keyword, __LOCATION__, name="MP_GRID", &
2882 : description="The dimensions of the Monkhorst-Pack k-point grid. ", &
2883 10278 : usage="MP_GRID 6 6 6", n_var=-1, default_i_vals=[10, 10, 10], type_of_var=integer_t)
2884 10278 : CALL section_add_keyword(print_key, keyword)
2885 10278 : CALL keyword_release(keyword)
2886 :
2887 : CALL keyword_create(keyword, __LOCATION__, name="KPOINTS_SOURCE", &
2888 : description="Select the k-point source for the Wannier90 export. MP_GRID keeps "// &
2889 : "the historical behavior and builds a full grid from WANNIER90%MP_GRID. SCF uses "// &
2890 : "the full k-point mesh from DFT%KPOINTS for Monkhorst-Pack, MacDonald, Gamma, or "// &
2891 : "explicit GENERAL k-points. If the SCF calculation uses K290 or SPGLIB symmetry "// &
2892 : "reduction, the corresponding unreduced mesh is used for Wannier90 because "// &
2893 : "Wannier90 requires a complete mesh.", &
2894 : usage="KPOINTS_SOURCE MP_GRID", type_of_var=enum_t, &
2895 : enum_c_vals=s2a("MP_GRID", "SCF"), &
2896 : enum_i_vals=[0, 1], &
2897 : enum_desc=s2a("Build the Wannier90 k-point mesh from WANNIER90%MP_GRID.", &
2898 : "Use the full k-point mesh from DFT%KPOINTS."), &
2899 10278 : default_i_val=0)
2900 10278 : CALL section_add_keyword(print_key, keyword)
2901 10278 : CALL keyword_release(keyword)
2902 :
2903 : CALL keyword_create(keyword, __LOCATION__, name="REUSE_SCF_MOS", &
2904 : description="Try to reuse the SCF k-point MO coefficients when KPOINTS_SOURCE SCF "// &
2905 : "is active. CP2K can directly reuse full SCF meshes, time-reversal partners, "// &
2906 : "non-degenerate atom/AO symmetry images, and atom/AO symmetry images whose "// &
2907 : "degenerate band subspaces are fully contained in the exported Wannier90 band "// &
2908 : "window. If the Wannier90 band window cuts through a degenerate subspace, CP2K "// &
2909 : "falls back to the historical full-mesh diagonalization.", &
2910 10278 : usage="REUSE_SCF_MOS T", default_l_val=.TRUE.)
2911 10278 : CALL section_add_keyword(print_key, keyword)
2912 10278 : CALL keyword_release(keyword)
2913 :
2914 : CALL keyword_create(keyword, __LOCATION__, name="VALIDATE_REUSE_SCF_MOS", &
2915 : description="When KPOINTS_SOURCE SCF and REUSE_SCF_MOS are active, first build a "// &
2916 : "full-mesh diagonalization reference and validate the reconstructed SCF MO "// &
2917 : "subspaces against it before writing Wannier90 files. This diagnostic option is "// &
2918 : "expensive and intended for development of symmetry-reconstructed Wannier90 "// &
2919 : "exports.", &
2920 10278 : usage="VALIDATE_REUSE_SCF_MOS T", default_l_val=.FALSE.)
2921 10278 : CALL section_add_keyword(print_key, keyword)
2922 10278 : CALL keyword_release(keyword)
2923 :
2924 : CALL keyword_create(keyword, __LOCATION__, name="USE_BLOCH_PHASES", &
2925 : description="Apply the CP2K Bloch-phase gauge to complete exported band subspaces "// &
2926 : "and write an explicit identity .amn projection file for Wannier90. It is only "// &
2927 : "valid when WANNIER_FUNCTIONS matches the number of exported bands; disentangled "// &
2928 : "Wannier90 calculations still need explicit projections.", &
2929 10278 : usage="USE_BLOCH_PHASES T", default_l_val=.FALSE.)
2930 10278 : CALL section_add_keyword(print_key, keyword)
2931 10278 : CALL keyword_release(keyword)
2932 :
2933 : CALL keyword_create(keyword, __LOCATION__, name="ADDED_MOS", &
2934 : variants=["ADDED_BANDS"], &
2935 : description="Number of MOs/Bands added to the Band Structure calculation.", &
2936 20556 : default_i_val=0)
2937 10278 : CALL section_add_keyword(print_key, keyword)
2938 10278 : CALL keyword_release(keyword)
2939 :
2940 : CALL keyword_create(keyword, __LOCATION__, name="EXCLUDE_BANDS", &
2941 : description="List of Bands excluded in the Wannier calculation.", &
2942 : usage="EXCLUDE_BANDS b1 b2 ...", n_var=-1, repeats=.TRUE., &
2943 10278 : type_of_var=integer_t)
2944 10278 : CALL section_add_keyword(print_key, keyword)
2945 10278 : CALL keyword_release(keyword)
2946 :
2947 : CALL keyword_create(keyword, __LOCATION__, name="WANNIER_FUNCTIONS", &
2948 : description="Number of Wannier functions to be calculated. ", &
2949 : usage="WANNIER_FUNCTIONS 6", n_var=1, default_i_val=0, &
2950 10278 : repeats=.TRUE., type_of_var=integer_t)
2951 10278 : CALL section_add_keyword(print_key, keyword)
2952 10278 : CALL keyword_release(keyword)
2953 :
2954 10278 : END SUBROUTINE create_wannier_section
2955 :
2956 : ! **************************************************************************************************
2957 : !> \brief ...
2958 : !> \param print_key ...
2959 : ! **************************************************************************************************
2960 10278 : SUBROUTINE create_stm_section(print_key)
2961 : TYPE(section_type), POINTER :: print_key
2962 :
2963 : TYPE(keyword_type), POINTER :: keyword
2964 :
2965 10278 : NULLIFY (keyword)
2966 :
2967 : CALL cp_print_key_section_create(print_key, __LOCATION__, "STM", &
2968 : description="Controls the printing of cubes for the generation of STM images.", &
2969 10278 : print_level=debug_print_level, filename="")
2970 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
2971 : description="The stride (X,Y,Z) used to write the cube file "// &
2972 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
2973 : " 1 number valid for all components.", &
2974 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
2975 10278 : CALL section_add_keyword(print_key, keyword)
2976 10278 : CALL keyword_release(keyword)
2977 :
2978 : CALL keyword_create(keyword, __LOCATION__, name="nlumo", &
2979 : description="If the printkey is activated controls the number of additional lumos"// &
2980 : " that are computed to be able to reproduce STM images obtained"// &
2981 : " from positive bias (imaging unoccupied states)", &
2982 10278 : default_i_val=0)
2983 10278 : CALL section_add_keyword(print_key, keyword)
2984 10278 : CALL keyword_release(keyword)
2985 :
2986 : CALL keyword_create(keyword, __LOCATION__, name="BIAS", &
2987 : description="Bias energy for scanning tunneling microscopy (STM) image generation. "// &
2988 : "Orbital densities are summed according to the bias energy. "// &
2989 : "For negative values, states in the range ]EF+bias,EF] are summed, "// &
2990 : "While positive values sum states in the range [EF,EF+bias[. "// &
2991 : "If positive biases are used, sufficiently many unoccupied stated "// &
2992 : "(see ADDED_MOS and NLUMO ) should be computed.", &
2993 10278 : n_var=-1, type_of_var=real_t, default_r_vals=[0.0_dp], unit_str='eV')
2994 10278 : CALL section_add_keyword(print_key, keyword)
2995 10278 : CALL keyword_release(keyword)
2996 :
2997 : CALL keyword_create(keyword, __LOCATION__, name="TH_TORB", &
2998 : description="Tip orbital symmetry in Tersoff-Hamann approximation to compute STM images", &
2999 : repeats=.TRUE., &
3000 : default_i_val=orb_s, &
3001 : usage="TH_TORB s dz2", &
3002 : enum_c_vals=s2a("S", "PX", "PY", "PZ", "DXY", "DYZ", "DZX", "DX2", "DY2", "DZ2"), &
3003 : enum_i_vals=[orb_s, orb_px, orb_py, orb_pz, orb_dxy, orb_dyz, orb_dzx, orb_dx2, orb_dy2, orb_dz2], &
3004 : enum_desc=s2a("s orbital", "px orbital", "py orbital", "pz orbital", &
3005 10278 : "dxy orbital", "dyz orbital", "dzx orbital", "x^2 orbital", "y^2 orbital", "z^2 orbital"))
3006 10278 : CALL section_add_keyword(print_key, keyword)
3007 10278 : CALL keyword_release(keyword)
3008 :
3009 : CALL keyword_create(keyword, __LOCATION__, name="REF_ENERGY", &
3010 : description="By default the reference energy is the Fermi energy. In order to compare"// &
3011 : " with STS experiments, where specific energy ranges are addressed, here"// &
3012 : " one can set a different reference energy."// &
3013 : " The energy range is anyway controlled by the BIAS", &
3014 10278 : type_of_var=real_t, default_r_val=0.0_dp, unit_str='eV')
3015 10278 : CALL section_add_keyword(print_key, keyword)
3016 10278 : CALL keyword_release(keyword)
3017 :
3018 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
3019 : description="append the cube files when they already exist", &
3020 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
3021 10278 : CALL section_add_keyword(print_key, keyword)
3022 10278 : CALL keyword_release(keyword)
3023 :
3024 10278 : END SUBROUTINE create_stm_section
3025 :
3026 : ! **************************************************************************************************
3027 : !> \brief ...
3028 : !> \param section ...
3029 : ! **************************************************************************************************
3030 10278 : SUBROUTINE create_wfn_mix_section(section)
3031 :
3032 : TYPE(section_type), POINTER :: section
3033 :
3034 : TYPE(keyword_type), POINTER :: keyword
3035 : TYPE(section_type), POINTER :: subsection
3036 :
3037 10278 : NULLIFY (subsection)
3038 10278 : NULLIFY (keyword)
3039 :
3040 10278 : CPASSERT(.NOT. ASSOCIATED(section))
3041 :
3042 : CALL section_create(section, __LOCATION__, name="WFN_MIX", &
3043 : description="A section that allows manipulation of the MO coeffs, "// &
3044 : "e.g. for changing a ground state into an excited state. "// &
3045 : "Starting from a copy of the original MOs, changes can be made "// &
3046 : "by adding linear combinations of HOMO/LUMO of the original MOs to the result MOs. "// &
3047 : "This method is called after an SCF optimization or before an RTP run if "// &
3048 : "INITIAL_WFN=RESTART_WFN. Note that if called after an SCF optimization, a restart file "// &
3049 : "with the mixed MOs is saved. This is not the case for an RTP with "// &
3050 : "INITIAL_WFN=RESTART_WFN.", &
3051 10278 : n_keywords=1, n_subsections=0, repeats=.FALSE.)
3052 :
3053 : CALL keyword_create(keyword, __LOCATION__, name="OVERWRITE_MOS", &
3054 : description="If set to True, the active molecular orbitals in memory will be replaced by the mixed wfn "// &
3055 : "at the end of the wfn mixing procedure. For instance, you can then use this new set of MOs to perform "// &
3056 : "RTP or EMD directly. Note that in the case of an RTP run with INITIAL_WFN=RESTART_WFN, the OVERWRITE_MOS "// &
3057 : "keyword is not used.", &
3058 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
3059 10278 : CALL section_add_keyword(section, keyword)
3060 10278 : CALL keyword_release(keyword)
3061 :
3062 : CALL section_create(subsection, __LOCATION__, name="UPDATE", &
3063 : description="Update a result MO with with a linear combination of original MOs."// &
3064 : " This section can be repeated to build arbitrary linear combinations using repeatedly y=a*y+b*x. "// &
3065 : "RESULT is (y), RESULT_SCALE is (a), ORIG is (x), ORIG_SCALE is (b)", &
3066 10278 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
3067 :
3068 : CALL keyword_create(keyword, __LOCATION__, name="RESULT_MO_INDEX", &
3069 : description="Index of the MO (y) to be modified. Counting down in energy: "// &
3070 : "set to 1 for the highest MO, to 3 for the highest MO-2.", &
3071 10278 : usage="RESULT_MO_INDEX 1", type_of_var=integer_t, default_i_val=0)
3072 10278 : CALL section_add_keyword(subsection, keyword)
3073 10278 : CALL keyword_release(keyword)
3074 :
3075 : CALL keyword_create(keyword, __LOCATION__, name="RESULT_MARKED_STATE", &
3076 : description="Specifies the MO according to "// &
3077 : "the marks set in MOLECULAR_STATES. The value corresponds to the repetition "// &
3078 : "of MARK_STATES in MOLECULAR_STATES", &
3079 10278 : usage="RESULT_MARKED_STATE 1", type_of_var=integer_t, default_i_val=0)
3080 10278 : CALL section_add_keyword(subsection, keyword)
3081 10278 : CALL keyword_release(keyword)
3082 :
3083 : CALL keyword_create(keyword, __LOCATION__, name="REVERSE_MO_INDEX", &
3084 : description="Reverses the index order of the OCCUPIED and EXTERNAL MOs. With this keyword "// &
3085 : "ORIG_MO_INDEX/RESULT_MO_INDEX 1 point to the lowest energy MO (instead of the highest) "// &
3086 : "and counts up in energy. The VIRTUAL MOs indexing is unchanged.", &
3087 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
3088 10278 : CALL section_add_keyword(subsection, keyword)
3089 10278 : CALL keyword_release(keyword)
3090 :
3091 : CALL keyword_create(keyword, __LOCATION__, name="RESULT_SPIN_INDEX", &
3092 : description="Spin of the MO (y) to be modified.", &
3093 : enum_c_vals=s2a("Alpha", "Beta"), &
3094 : enum_i_vals=[1, 2], & ! direct index in array
3095 : default_i_val=1, &
3096 10278 : enum_desc=s2a("Majority spin", "Minority spin"))
3097 10278 : CALL section_add_keyword(subsection, keyword)
3098 10278 : CALL keyword_release(keyword)
3099 :
3100 : CALL keyword_create(keyword, __LOCATION__, name="RESULT_SCALE", &
3101 : description="Scaling factor of the result variable (a).", &
3102 10278 : usage="RESULT_SCALE 0.0", type_of_var=real_t)
3103 10278 : CALL section_add_keyword(subsection, keyword)
3104 10278 : CALL keyword_release(keyword)
3105 :
3106 : CALL keyword_create(keyword, __LOCATION__, name="ORIG_MO_INDEX", &
3107 : description="Index of the original MO (x). "// &
3108 : "If ORIG_TYPE is OCCUPIED, it counts down in energy: set to 1 to point to "// &
3109 : "the highest MO and to 3 for the highest MO-2. "// &
3110 : "If ORIG_TYPE is VIRTUAL, it counts up in energy: set to 1 to point to "// &
3111 : "the lowest virtual MO and to 3 for the lowest MO+2. "// &
3112 : "If ORIG_TYPE is EXTERNAL, it counts down in energy for the external "// &
3113 : "set of MOs: set to 1 to point to the highest MO and to 3 for the highest MO-2. "// &
3114 : "Do not set to zero or negative values.", &
3115 10278 : usage="ORIG_MO_INDEX 1", type_of_var=integer_t, default_i_val=0)
3116 10278 : CALL section_add_keyword(subsection, keyword)
3117 10278 : CALL keyword_release(keyword)
3118 :
3119 : CALL keyword_create(keyword, __LOCATION__, name="ORIG_MARKED_STATE", &
3120 : description="Specifies the MO according to "// &
3121 : "the marks set in MOLECULAR_STATES. The value corresponds to the repetition "// &
3122 : "of MARK_STATES in MOLECULAR_STATES", &
3123 10278 : usage="ORIG_MARKED_STATE 1", type_of_var=integer_t, default_i_val=0)
3124 10278 : CALL section_add_keyword(subsection, keyword)
3125 10278 : CALL keyword_release(keyword)
3126 :
3127 : CALL keyword_create(keyword, __LOCATION__, name="ORIG_SPIN_INDEX", &
3128 : description="Spin of the MO (x) to be modified.", &
3129 : enum_c_vals=s2a("Alpha", "Beta"), &
3130 : enum_i_vals=[1, 2], & ! direct index in array
3131 : default_i_val=1, &
3132 10278 : enum_desc=s2a("Majority spin", "Minority spin"))
3133 10278 : CALL section_add_keyword(subsection, keyword)
3134 10278 : CALL keyword_release(keyword)
3135 :
3136 : CALL keyword_create(keyword, __LOCATION__, name="ORIG_SCALE", &
3137 : description="Scaling factor of the original variable (b).", &
3138 10278 : usage="ORIG_SCALE 0.0", type_of_var=real_t)
3139 10278 : CALL section_add_keyword(subsection, keyword)
3140 10278 : CALL keyword_release(keyword)
3141 :
3142 : CALL keyword_create(keyword, __LOCATION__, name="ORIG_TYPE", &
3143 : description="Type of the original MO. Note that if ADDED_MOS was used in the "// &
3144 : "SCF construction of the MO matrix, these extra MOs are also treated as OCCUPIED. ", &
3145 : enum_c_vals=s2a("OCCUPIED", "VIRTUAL", 'EXTERNAL'), &
3146 : usage="ORIG_TYPE OCCUPIED", &
3147 : default_i_val=wfn_mix_orig_occ, &
3148 : enum_desc=s2a("The original MO is the result of the SCF procedure. This can also contain "// &
3149 : "unoccupied MOs if the SCF%ADDED_MOS keyword was used.", &
3150 : "The original MO is taken from the result of additional MOs calculated a "// &
3151 : "posteriori of the SCF by request of the user. E.g. by specifying print%mo_cubes%nlumo. ", &
3152 : "The orginal MO is from an external .wfn file. Use the keyword "// &
3153 : "ORIG_EXT_FILE_NAME to define its name."), &
3154 10278 : enum_i_vals=[wfn_mix_orig_occ, wfn_mix_orig_virtual, wfn_mix_orig_external])
3155 10278 : CALL section_add_keyword(subsection, keyword)
3156 10278 : CALL keyword_release(keyword)
3157 :
3158 : CALL keyword_create(keyword, __LOCATION__, name="ORIG_EXT_FILE_NAME", &
3159 : description="Name of the wavefunction file to read the original MO from. "// &
3160 : "For instance, a restart wfn file from SCF calculation or an excited state from XAS_TDP calculation. "// &
3161 : "If no file is specified, the run will crash. "// &
3162 : "Currently, a RTP restart file (.rtpwfn) cannot be used as reference. "// &
3163 : "Currently, this file SHALL have the basis set, number of MO and the same number of spin as the one "// &
3164 : "from the SCF cycle.", &
3165 : usage="ORIG_EXT_FILE_NAME <FILENAME>", &
3166 10278 : default_lc_val="EMPTY")
3167 10278 : CALL section_add_keyword(subsection, keyword)
3168 10278 : CALL keyword_release(keyword)
3169 :
3170 10278 : CALL section_add_subsection(section, subsection)
3171 10278 : CALL section_release(subsection)
3172 :
3173 10278 : END SUBROUTINE create_wfn_mix_section
3174 :
3175 : ! **************************************************************************************************
3176 : !> \brief Creates the section for cube files related to the implicit Poisson solver.
3177 : !> \param section the section to be created
3178 : !> \par History
3179 : !> 03.2016 refactored from create_print_dft_section [Hossein Bani-Hashemian]
3180 : !> \author Mohammad Hossein Bani-Hashemian
3181 : ! **************************************************************************************************
3182 10278 : SUBROUTINE create_implicit_psolver_section(section)
3183 : TYPE(section_type), POINTER :: section
3184 :
3185 : TYPE(keyword_type), POINTER :: keyword
3186 : TYPE(section_type), POINTER :: print_key
3187 :
3188 10278 : CPASSERT(.NOT. ASSOCIATED(section))
3189 : CALL section_create(section, __LOCATION__, name="IMPLICIT_PSOLVER", &
3190 : description="Controls printing of cube files for data from the implicit "// &
3191 : "(generalized) Poisson solver.", &
3192 : citations=[BaniHashemian2016], &
3193 20556 : n_keywords=0, n_subsections=3, repeats=.FALSE.)
3194 :
3195 10278 : NULLIFY (keyword, print_key)
3196 :
3197 : ! dielectric constant function
3198 : CALL cp_print_key_section_create(print_key, __LOCATION__, "DIELECTRIC_CUBE", &
3199 : description="Controls the printing of a cube file with dielectric constant from "// &
3200 : "the implicit (generalized) Poisson solver.", &
3201 10278 : print_level=high_print_level, filename="")
3202 :
3203 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
3204 : description="The stride (X,Y,Z) used to write the cube file "// &
3205 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
3206 : " 1 number valid for all components.", &
3207 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
3208 10278 : CALL section_add_keyword(print_key, keyword)
3209 10278 : CALL keyword_release(keyword)
3210 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
3211 : description="append the cube files when they already exist", &
3212 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
3213 10278 : CALL section_add_keyword(print_key, keyword)
3214 10278 : CALL keyword_release(keyword)
3215 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
3216 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
3217 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
3218 10278 : CALL section_add_keyword(print_key, keyword)
3219 10278 : CALL keyword_release(keyword)
3220 :
3221 10278 : CALL section_add_subsection(section, print_key)
3222 10278 : CALL section_release(print_key)
3223 :
3224 : ! dirichlet type constraints
3225 : CALL cp_print_key_section_create( &
3226 : print_key, __LOCATION__, "DIRICHLET_BC_CUBE", &
3227 : description="Controls the printing of cube files with unit step functions (constraints)"// &
3228 : " representing Dirichlet-type (boundary) regions defined in the implicit (generalized) Poisson"// &
3229 : " solver section. The regions remain unchanged throughout the calculations. If the Dirichlet"// &
3230 : " regions are relatively large and/or the number of partitions is quite high, in order to save memory,"// &
3231 : " generate the cube files in early steps and perform the rest of the calculations with this keyword"// &
3232 : " switched off.", &
3233 10278 : print_level=high_print_level, filename="")
3234 :
3235 : CALL keyword_create(keyword, __LOCATION__, name="TILE_CUBES", &
3236 : description="Print tiles that tessellate the Dirichlet regions into cube files. If TRUE, "// &
3237 : "generates cube files as many as the total number of tiles.", &
3238 : usage="TILE_CUBES <logical>", &
3239 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
3240 10278 : CALL section_add_keyword(print_key, keyword)
3241 10278 : CALL keyword_release(keyword)
3242 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
3243 : description="The stride (X,Y,Z) used to write the cube file "// &
3244 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
3245 : " 1 number valid for all components.", &
3246 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
3247 10278 : CALL section_add_keyword(print_key, keyword)
3248 10278 : CALL keyword_release(keyword)
3249 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
3250 : description="append the cube files when they already exist", &
3251 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
3252 10278 : CALL section_add_keyword(print_key, keyword)
3253 10278 : CALL keyword_release(keyword)
3254 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
3255 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
3256 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
3257 10278 : CALL section_add_keyword(print_key, keyword)
3258 10278 : CALL keyword_release(keyword)
3259 :
3260 10278 : CALL section_add_subsection(section, print_key)
3261 10278 : CALL section_release(print_key)
3262 :
3263 : ! charge introduced by Lagrange multipliers
3264 : CALL cp_print_key_section_create(print_key, __LOCATION__, "DIRICHLET_CSTR_CHARGE_CUBE", &
3265 : description="Controls the printing of cube files with penalty charges induced to "// &
3266 : "Dirichlet regions by Lagrange multipliers (implicit Poisson solver).", &
3267 10278 : print_level=high_print_level, filename="")
3268 :
3269 : CALL keyword_create(keyword, __LOCATION__, name="stride", &
3270 : description="The stride (X,Y,Z) used to write the cube file "// &
3271 : "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
3272 : " 1 number valid for all components.", &
3273 10278 : usage="STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=integer_t)
3274 10278 : CALL section_add_keyword(print_key, keyword)
3275 10278 : CALL keyword_release(keyword)
3276 : CALL keyword_create(keyword, __LOCATION__, name="APPEND", &
3277 : description="append the cube files when they already exist", &
3278 10278 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
3279 10278 : CALL section_add_keyword(print_key, keyword)
3280 10278 : CALL keyword_release(keyword)
3281 : CALL keyword_create(keyword, __LOCATION__, name="MAX_FILE_SIZE_MB", &
3282 : description="Limits the size of the cube file by choosing a suitable stride. Zero means no limit.", &
3283 10278 : usage="MAX_FILE_SIZE_MB 1.5", default_r_val=0.0_dp)
3284 10278 : CALL section_add_keyword(print_key, keyword)
3285 10278 : CALL keyword_release(keyword)
3286 :
3287 10278 : CALL section_add_subsection(section, print_key)
3288 10278 : CALL section_release(print_key)
3289 :
3290 10278 : END SUBROUTINE create_implicit_psolver_section
3291 :
3292 : ! **************************************************************************************************
3293 : !> \brief creates the interpolation section for the periodic QM/MM
3294 : !> \param section ...
3295 : !> \author tlaino
3296 : ! **************************************************************************************************
3297 10278 : SUBROUTINE create_gspace_interp_section(section)
3298 : TYPE(section_type), POINTER :: section
3299 :
3300 : TYPE(keyword_type), POINTER :: keyword
3301 : TYPE(section_type), POINTER :: print_key
3302 :
3303 10278 : CPASSERT(.NOT. ASSOCIATED(section))
3304 : CALL section_create(section, __LOCATION__, name="interpolator", &
3305 : description="controls the interpolation for the G-space term", &
3306 10278 : n_keywords=5, n_subsections=0, repeats=.FALSE.)
3307 :
3308 10278 : NULLIFY (keyword, print_key)
3309 :
3310 : CALL keyword_create(keyword, __LOCATION__, name="aint_precond", &
3311 : description="the approximate inverse to use to get the starting point"// &
3312 : " for the linear solver of the spline3 methods", &
3313 : usage="aint_precond copy", &
3314 : default_i_val=precond_spl3_aint, &
3315 : enum_c_vals=s2a("copy", "spl3_nopbc_aint1", "spl3_nopbc_precond1", &
3316 : "spl3_nopbc_aint2", "spl3_nopbc_precond2", "spl3_nopbc_precond3"), &
3317 : enum_i_vals=[no_precond, precond_spl3_aint, precond_spl3_1, &
3318 10278 : precond_spl3_aint2, precond_spl3_2, precond_spl3_3])
3319 10278 : CALL section_add_keyword(section, keyword)
3320 10278 : CALL keyword_release(keyword)
3321 :
3322 : CALL keyword_create(keyword, __LOCATION__, name="precond", &
3323 : description="The preconditioner used"// &
3324 : " for the linear solver of the spline3 methods", &
3325 : usage="precond copy", &
3326 : default_i_val=precond_spl3_3, &
3327 : enum_c_vals=s2a("copy", "spl3_nopbc_aint1", "spl3_nopbc_precond1", &
3328 : "spl3_nopbc_aint2", "spl3_nopbc_precond2", "spl3_nopbc_precond3"), &
3329 : enum_i_vals=[no_precond, precond_spl3_aint, precond_spl3_1, &
3330 10278 : precond_spl3_aint2, precond_spl3_2, precond_spl3_3])
3331 10278 : CALL section_add_keyword(section, keyword)
3332 10278 : CALL keyword_release(keyword)
3333 :
3334 : CALL keyword_create(keyword, __LOCATION__, name="eps_x", &
3335 : description="accuracy on the solution for spline3 the interpolators", &
3336 10278 : usage="eps_x 1.e-15", default_r_val=1.e-10_dp)
3337 10278 : CALL section_add_keyword(section, keyword)
3338 10278 : CALL keyword_release(keyword)
3339 :
3340 : CALL keyword_create(keyword, __LOCATION__, name="eps_r", &
3341 : description="accuracy on the residual for spline3 the interpolators", &
3342 10278 : usage="eps_r 1.e-15", default_r_val=1.e-10_dp)
3343 10278 : CALL section_add_keyword(section, keyword)
3344 10278 : CALL keyword_release(keyword)
3345 :
3346 : CALL keyword_create(keyword, __LOCATION__, name="max_iter", &
3347 : variants=['maxiter'], &
3348 : description="the maximum number of iterations", &
3349 20556 : usage="max_iter 200", default_i_val=100)
3350 10278 : CALL section_add_keyword(section, keyword)
3351 10278 : CALL keyword_release(keyword)
3352 :
3353 10278 : NULLIFY (print_key)
3354 : CALL cp_print_key_section_create(print_key, __LOCATION__, "conv_info", &
3355 : description="if convergence information about the linear solver"// &
3356 : " of the spline methods should be printed", &
3357 : print_level=medium_print_level, each_iter_names=s2a("SPLINE_FIND_COEFFS"), &
3358 : each_iter_values=[10], filename="__STD_OUT__", &
3359 10278 : add_last=add_last_numeric)
3360 10278 : CALL section_add_subsection(section, print_key)
3361 10278 : CALL section_release(print_key)
3362 :
3363 10278 : END SUBROUTINE create_gspace_interp_section
3364 :
3365 : END MODULE input_cp2k_print_dft
|