69#include "./base/base_uses.f90"
74 LOGICAL,
PRIVATE,
PARAMETER :: debug_this_module = .true.
75 CHARACTER(len=*),
PARAMETER,
PRIVATE :: moduleN =
'input_cp2k_properties_dft'
92 cpassert(.NOT.
ASSOCIATED(section))
94 description=
"This section is used to set up the PROPERTIES calculation.", &
95 n_keywords=0, n_subsections=6, repeats=.false.)
97 NULLIFY (subsection, keyword)
99 CALL create_linres_section(subsection, create_subsections=.true.)
103 CALL create_et_coupling_section(subsection)
116 description=
"This section is used to print the density derived atomic point charges. "// &
117 "The fit of the charges is controlled through the DENSITY_FITTING section", &
119 CALL keyword_create(keyword, __location__, name=
"TYPE_OF_DENSITY", &
120 description=
"Specifies the type of density used for the fitting", &
121 usage=
"TYPE_OF_DENSITY (FULL|SPIN)", &
122 enum_c_vals=
s2a(
"FULL",
"SPIN"), &
124 enum_desc=
s2a(
"Full density",
"Spin density"), &
131 CALL create_tddfpt2_section(subsection)
135 CALL create_rixs_section(subsection)
139 CALL create_bandstructure_section(subsection)
143 CALL create_tipscan_section(subsection)
154 SUBROUTINE create_rixs_section(section)
159 cpassert(.NOT.
ASSOCIATED(section))
161 NULLIFY (keyword, subsection, print_key)
164 description=
"Resonant Inelastic Xray Scattering using XAS_TDP and TDDFPT.", &
165 n_keywords=1, n_subsections=3, repeats=.false., &
169 name=
"_SECTION_PARAMETERS_", &
170 description=
"Controls the activation of the RIXS procedure", &
171 default_l_val=.false., &
172 lone_keyword_l_val=.true.)
177 description=
"Number of core excited states to be used in the RIXS "// &
178 "calculation. Restricting this number reduces computational cost. "// &
179 "-1 means all available core states will be used.", &
180 n_var=1, type_of_var=
integer_t, default_i_val=-1)
184 CALL keyword_create(keyword, __location__, name=
"VALENCE_STATES", &
185 description=
"Number of valence excited states to be used in the RIXS "// &
186 "calculation. Restricting this number reduces computational cost, but "// &
187 "removes spectral features corresponding to higher excitations. Should be "// &
188 "used with care. -1 means all available valence states will be used.", &
189 n_var=1, type_of_var=
integer_t, default_i_val=-1)
193 CALL create_tddfpt2_section(subsection)
201 CALL section_create(subsection, __location__,
"PRINT",
"Controls the printing of information "// &
202 "during RIXS calculations", repeats=.false.)
205 description=
"Controles the printing of the RIXS spectrum "// &
208 common_iter_levels=3)
215 END SUBROUTINE create_rixs_section
226 SUBROUTINE create_linres_section(section, create_subsections, default_set_tdlr)
228 LOGICAL,
INTENT(in) :: create_subsections
229 LOGICAL,
INTENT(IN),
OPTIONAL :: default_set_tdlr
231 INTEGER :: def_max_iter, def_precond
232 REAL(kind=
dp) :: def_egap, def_eps, def_eps_filter
236 CHARACTER(len=256) :: desc
238 NULLIFY (keyword, print_key)
240 IF (
PRESENT(default_set_tdlr))
THEN
243 def_eps_filter = 1.0e-15_dp
246 desc =
"Controls the parameters of the LINRES force calculations for excited states."
250 def_eps_filter = 0.0_dp
253 desc =
"The linear response is used to calculate one of the following properties: nmr, epr, raman, ..."
256 cpassert(.NOT.
ASSOCIATED(section))
258 description=desc, n_keywords=5, n_subsections=2, repeats=.false., &
262 description=
"target accuracy for the convergence of the conjugate gradient.", &
263 usage=
"EPS 1.e-6", default_r_val=def_eps)
268 description=
"Filter threshold for response density matrix.", &
269 usage=
"EPS_FILTER 1.e-8", default_r_val=def_eps_filter)
274 description=
"Maximum number of conjugate gradient iteration to be performed for one optimization.", &
275 usage=
"MAX_ITER 200", default_i_val=def_max_iter)
279 CALL keyword_create(keyword, __location__, name=
"RESTART_EVERY", &
280 description=
"Restart the conjugate gradient after the specified number of iterations.", &
281 usage=
"RESTART_EVERY 200", default_i_val=50)
286 keyword, __location__, name=
"PRECONDITIONER", &
287 description=
"Type of preconditioner to be used with all minimization schemes. "// &
288 "They differ in effectiveness, cost of construction, cost of application. "// &
289 "Properly preconditioned minimization can be orders of magnitude faster than doing nothing.", &
290 usage=
"PRECONDITIONER FULL_ALL", &
291 default_i_val=def_precond, &
292 enum_c_vals=
s2a(
"FULL_ALL",
"FULL_SINGLE_INVERSE",
"FULL_SINGLE",
"FULL_KINETIC",
"FULL_S_INVERSE", &
294 enum_desc=
s2a(
"Most effective state selective preconditioner based on diagonalization, "// &
295 "requires the ENERGY_GAP parameter to be an underestimate of the HOMO-LUMO gap. "// &
296 "This preconditioner is recommended for almost all systems, except very large systems where "// &
297 "make_preconditioner would dominate the total computational cost.", &
298 "Based on H-eS cholesky inversion, similar to FULL_SINGLE in preconditioning efficiency "// &
299 "but cheaper to construct, "// &
300 "might be somewhat less robust. Recommended for large systems.", &
301 "Based on H-eS diagonalisation, not as good as FULL_ALL, but somewhat cheaper to apply. ", &
302 "Cholesky inversion of S and T, fast construction, robust, and relatively good, "// &
303 "use for very large systems.", &
304 "Cholesky inversion of S, not as good as FULL_KINETIC, yet equally expensive.", &
305 "skip preconditioning"), &
312 description=
"Energy gap estimate [a.u.] for preconditioning", &
313 usage=
"ENERGY_GAP 0.1", &
314 default_r_val=def_egap)
319 description=
"Perform a linear response calculation every N-th step for MD run", &
320 usage=
"EVERY_N_STEP 50", default_i_val=1)
325 description=
"Restart the response calculation if the restart file exists", &
327 default_l_val=.false., lone_keyword_l_val=.true.)
331 CALL keyword_create(keyword, __location__, name=
"WFN_RESTART_FILE_NAME", &
332 variants=[
"RESTART_FILE_NAME"], &
333 description=
"Root of the file names where to read the response functions from "// &
334 "which to restart the calculation of the linear response", &
335 usage=
"WFN_RESTART_FILE_NAME <FILENAME>", &
340 IF (create_subsections)
THEN
347 CALL create_current_section(subsection)
351 CALL create_nmr_section(subsection)
355 CALL create_spin_spin_section(subsection)
359 CALL create_epr_section(subsection)
363 CALL create_polarizability_section(subsection)
367 CALL create_dcdr_section(subsection)
371 CALL create_vcd_section(subsection)
376 description=
"printing of information during the linear response calculation", &
380 print_key, __location__,
"program_run_info", &
381 description=
"Controls the printing of basic iteration information during the LINRES calculation", &
387 description=
"Controls the dumping of restart file of the response wavefunction. "// &
388 "For each set of response functions, i.e. for each perturbation, "// &
389 "one different restart file is dumped. These restart files should be "// &
390 "employed only to restart the same type of LINRES calculation, "// &
391 "i.e. with the same perturbation.", &
402 END SUBROUTINE create_linres_section
410 SUBROUTINE create_dcdr_section(section)
419 NULLIFY (keyword, print_key, subsection)
421 cpassert(.NOT.
ASSOCIATED(section))
423 IF (.NOT. failure)
THEN
425 description=
"Compute analytical gradients the dipole moments.", &
426 n_keywords=50, n_subsections=1, repeats=.false.)
428 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
429 description=
"controls the activation of the APT calculation", &
431 default_l_val=.false., &
432 lone_keyword_l_val=.true.)
436 CALL keyword_create(keyword, __location__, name=
"LIST_OF_ATOMS", &
437 description=
"Specifies a list of atoms.", &
438 usage=
"LIST_OF_ATOMS {integer} {integer} .. {integer}", repeats=.true., &
443 CALL keyword_create(keyword, __location__, name=
"DISTRIBUTED_ORIGIN", &
444 variants=[
"DO_GAUGE"], &
445 description=
"Use the distributed origin (DO) gauge?", &
446 usage=
"DISTRIBUTED_ORIGIN T", &
447 default_l_val=.false., lone_keyword_l_val=.true.)
451 CALL keyword_create(keyword, __location__, name=
"ORBITAL_CENTER", &
452 description=
"The orbital center.", &
453 usage=
"ORBITAL_CENTER WANNIER", &
455 enum_c_vals=
s2a(
"WANNIER",
"COMMON",
"ATOM",
"BOX"), &
456 enum_desc=
s2a(
"Use the Wannier centers.", &
457 "Use a common center (works only for an isolate molecule).", &
458 "Use the atoms as center.", &
466 description=
"Gauge origin of the velocity gauge factor.", &
467 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
468 enum_desc=
s2a(
"Use Center of Mass", &
469 "Use Center of Atomic Charges", &
470 "Use User-defined Point", &
471 "Use Origin of Coordinate System"), &
480 CALL keyword_create(keyword, __location__, name=
"REFERENCE_POINT", &
481 description=
"User-defined reference point of the velocity gauge factor.", &
482 usage=
"REFERENCE_POINT x y z", &
483 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
487 CALL keyword_create(keyword, __location__, name=
"Z_MATRIX_METHOD", &
488 description=
"Use Z_matrix method to solve the response equation", &
489 usage=
"Z_MATRIX_METHOD T", &
490 default_l_val=.false., lone_keyword_l_val=.true.)
495 description=
"Use numerical differentiation to compute the APT, "// &
496 "switches off the calculation of dcdr analytical derivatives. "// &
497 "Requires RUN_TYPE = ENERGY_FORCE or MD.", &
499 default_l_val=.false., lone_keyword_l_val=.true.)
504 description=
"Electric field strength (atomic units) to use for finite differences", &
508 default_r_val=0.0003_dp, &
509 usage=
"APT_FD_DE 1.0E-4")
513 CALL keyword_create(keyword, __location__, name=
"APT_FD_METHOD", &
514 description=
"Numerical differentiation method", &
515 usage=
"APT_FD_METHOD FD", &
518 enum_c_vals=
s2a(
"2PNT"), &
521 enum_desc=
s2a(
"Symmetric two-point differences."), &
529 description=
"print results of the magnetic dipole moment calculation", &
533 description=
"Controls the printing of the electric dipole gradient", &
548 END SUBROUTINE create_dcdr_section
556 SUBROUTINE create_vcd_section(section)
563 NULLIFY (keyword, print_key, subsection)
565 cpassert(.NOT.
ASSOCIATED(section))
568 description=
"Carry out a VCD calculation.", &
569 n_keywords=50, n_subsections=1, repeats=.false.)
571 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
572 description=
"controls the activation of the APT/AAT calculation", &
574 default_l_val=.false., &
575 lone_keyword_l_val=.true.)
579 CALL keyword_create(keyword, __location__, name=
"LIST_OF_ATOMS", &
580 description=
"Specifies a list of atoms.", &
581 usage=
"LIST_OF_ATOMS {integer} {integer} .. {integer}", repeats=.true., &
586 CALL keyword_create(keyword, __location__, name=
"DISTRIBUTED_ORIGIN", &
587 variants=[
"DO_GAUGE"], &
588 description=
"Use the distributed origin (DO) gauge?", &
589 usage=
"DISTRIBUTED_ORIGIN T", &
590 default_l_val=.false., lone_keyword_l_val=.true.)
594 CALL keyword_create(keyword, __location__, name=
"ORIGIN_DEPENDENT_MFP", &
595 description=
"Use the origin dependent MFP operator.", &
596 usage=
"ORIGIN_DEPENDENT_MFP T", &
597 default_l_val=.false., lone_keyword_l_val=.true.)
601 CALL keyword_create(keyword, __location__, name=
"ORBITAL_CENTER", &
602 description=
"The orbital center.", &
603 usage=
"ORBITAL_CENTER WANNIER", &
605 enum_c_vals=
s2a(
"WANNIER",
"COMMON",
"ATOM",
"BOX"), &
606 enum_desc=
s2a(
"Use the Wannier centers.", &
607 "Use a common center (works only for an isolate molecule).", &
608 "Use the atoms as center.", &
616 CALL keyword_create(keyword, __location__, name=
"MAGNETIC_ORIGIN", &
617 description=
"Gauge origin of the magnetic dipole operator.", &
618 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
619 enum_desc=
s2a(
"Use Center of Mass", &
620 "Use Center of Atomic Charges", &
621 "Use User-defined Point", &
622 "Use Origin of Coordinate System"), &
631 CALL keyword_create(keyword, __location__, name=
"MAGNETIC_ORIGIN_REFERENCE", &
632 description=
"User-defined reference point of the magnetic dipole operator.", &
633 usage=
"MAGNETIC_ORIGIN_REFERENCE x y z", &
634 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
639 CALL keyword_create(keyword, __location__, name=
"SPATIAL_ORIGIN", &
640 description=
"Gauge origin of the velocity gauge factor/spatial origin.", &
641 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
642 enum_desc=
s2a(
"Use Center of Mass", &
643 "Use Center of Atomic Charges", &
644 "Use User-defined Point", &
645 "Use Origin of Coordinate System"), &
654 CALL keyword_create(keyword, __location__, name=
"SPATIAL_ORIGIN_REFERENCE", &
655 description=
"User-defined reference point of the velocity gauge factor/spatial origin.", &
656 usage=
"SPATIAL_ORIGIN_REFERENCE x y z", &
657 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
663 description=
"print results of the magnetic dipole moment calculation", &
667 description=
"Controls the printing of the APTs and AATs", &
680 END SUBROUTINE create_vcd_section
689 SUBROUTINE create_current_section(section)
695 NULLIFY (keyword, print_key, subsection)
697 cpassert(.NOT.
ASSOCIATED(section))
699 description=
"The induced current density is calculated by DFPT.", &
700 n_keywords=4, n_subsections=1, repeats=.false., &
703 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
704 description=
"controls the activation of the induced current calculation", &
705 usage=
"&CURRENT T", &
706 default_l_val=.false., &
707 lone_keyword_l_val=.true.)
712 description=
"The gauge used to compute the induced current within GAPW.", &
715 enum_c_vals=
s2a(
"R",
"R_AND_STEP_FUNCTION",
"ATOM"), &
716 enum_desc=
s2a(
"Position gauge (doesnt work well).", &
717 "Position and step function for the soft and the local parts, respectively.", &
723 CALL keyword_create(keyword, __location__, name=
"GAUGE_ATOM_RADIUS", &
724 description=
"Build the gauge=atom using only the atoms within this radius.", &
725 usage=
"GAUGE_ATOM_RADIUS 10.0", &
732 CALL keyword_create(keyword, __location__, name=
"USE_OLD_GAUGE_ATOM", &
733 description=
"Use the old way to compute the gauge.", &
734 usage=
"USE_OLD_GAUGE_ATOM T", &
735 default_l_val=.true., lone_keyword_l_val=.true.)
739 CALL keyword_create(keyword, __location__, name=
"ORBITAL_CENTER", &
740 description=
"The orbital center.", &
741 usage=
"ORBITAL_CENTER WANNIER", &
743 enum_c_vals=
s2a(
"WANNIER",
"COMMON",
"ATOM",
"BOX"), &
744 enum_desc=
s2a(
"Use the Wannier centers.", &
745 "Use a common center (works only for an isolate molecule).", &
746 "Use the atoms as center.", &
753 CALL keyword_create(keyword, __location__, name=
"COMMON_CENTER", &
754 description=
"The common center ", usage=
"COMMON_CENTER 0.0 1.0 0.0", &
755 n_var=3, default_r_vals=[0.0_dp, 0.0_dp, 0.0_dp], type_of_var=
real_t, &
761 description=
"How many boxes along each directions ", usage=
"NBOX 6 6 5", &
762 n_var=3, default_i_vals=[4, 4, 4], type_of_var=
integer_t)
767 description=
"Calculate the succeptibility correction to the shift with PBC", &
769 default_l_val=.false., lone_keyword_l_val=.true.)
773 CALL keyword_create(keyword, __location__, name=
"FORCE_NO_FULL", &
774 description=
"Avoid the calculation of the state dependent perturbation term, "// &
775 "even if the orbital centers are set at Wannier centers or at Atom centers", &
776 usage=
"FORCE_NO_FULL T", &
777 default_l_val=.false., lone_keyword_l_val=.true.)
781 CALL keyword_create(keyword, __location__, name=
"SELECTED_STATES_ON_ATOM_LIST", &
782 description=
"Indexes of the atoms for selecting"// &
783 " the states to be used for the response calculations.", &
784 usage=
"SELECTED_STATES_ON_ATOM_LIST 1 2 10", &
785 n_var=-1, type_of_var=
integer_t, repeats=.true.)
789 CALL keyword_create(keyword, __location__, name=
"SELECTED_STATES_ATOM_RADIUS", &
790 description=
"Select all the states included in the given radius around each atoms "// &
791 "in SELECTED_STATES_ON_ATOM_LIST.", &
792 usage=
"SELECTED_STATES_ATOM_RADIUS 2.0", &
799 CALL keyword_create(keyword, __location__, name=
"RESTART_CURRENT", &
800 description=
"Restart the induced current density calculation"// &
801 " from a previous run (not working yet).", &
802 usage=
"RESTART_CURRENT", default_l_val=.false., &
803 lone_keyword_l_val=.true.)
809 description=
"print results of induced current density calculation", &
813 description=
"Controls the printing of the induced current density (not working yet).", &
816 description=
"The stride (X,Y,Z) used to write the cube file "// &
817 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
818 " 1 number valid for all components (not working yet).", &
819 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
823 description=
"append the cube files when they already exist", &
824 default_l_val=.false., lone_keyword_l_val=.true.)
832 description=
"Controls the printing of the response functions (not working yet).", &
835 description=
"The stride (X,Y,Z) used to write the cube file "// &
836 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
837 " 1 number valid for all components (not working yet).", &
838 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
842 CALL keyword_create(keyword, __location__, name=
"CUBES_LU_BOUNDS", &
843 variants=[
"CUBES_LU"], &
844 description=
"The lower and upper index of the states to be printed as cube (not working yet).", &
845 usage=
"CUBES_LU_BOUNDS integer integer", &
846 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
851 description=
"Indexes of the states to be printed as cube files "// &
852 "This keyword can be repeated several times "// &
853 "(useful if you have to specify many indexes) (not working yet).", &
854 usage=
"CUBES_LIST 1 2", &
855 n_var=-1, type_of_var=
integer_t, repeats=.true.)
859 description=
"append the cube files when they already exist", &
860 default_l_val=.false., lone_keyword_l_val=.true.)
875 END SUBROUTINE create_current_section
885 SUBROUTINE create_nmr_section(section)
891 NULLIFY (keyword, print_key, subsection)
893 cpassert(.NOT.
ASSOCIATED(section))
895 description=
"The chemical shift is calculated by DFPT.", &
896 n_keywords=5, n_subsections=1, repeats=.false., &
899 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
900 description=
"controls the activation of the nmr calculation", &
902 default_l_val=.false., &
903 lone_keyword_l_val=.true.)
907 CALL keyword_create(keyword, __location__, name=
"INTERPOLATE_SHIFT", &
908 description=
"Calculate the soft part of the chemical shift by interpolation ", &
909 usage=
"INTERPOLATE_SHIFT T", &
910 default_l_val=.false., lone_keyword_l_val=.true.)
915 description=
"Calculate the chemical shift in a set of points"// &
916 " given from an external file", usage=
"NICS", &
917 default_l_val=.false., lone_keyword_l_val=.true.)
921 CALL keyword_create(keyword, __location__, name=
"NICS_FILE_NAME", &
922 description=
"Name of the file with the NICS points coordinates", &
923 usage=
"NICS_FILE_NAME nics_file", &
924 default_lc_val=
"nics_file")
929 description=
"Restart the NMR calculation from a previous run (NOT WORKING YET)", &
930 usage=
"RESTART_NMR", default_l_val=.false., &
931 lone_keyword_l_val=.true.)
935 CALL keyword_create(keyword, __location__, name=
"SHIFT_GAPW_RADIUS", &
936 description=
"While computing the local part of the shift (GAPW), "// &
937 "the integration is restricted to nuclei that are within this radius.", &
938 usage=
"SHIFT_GAPW_RADIUS 20.0", &
947 description=
"print results of nmr calculation", &
951 description=
"Controls the printing of the response functions ", &
954 description=
"The stride (X,Y,Z) used to write the cube file "// &
955 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
956 " 1 number valid for all components.", &
957 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
961 CALL keyword_create(keyword, __location__, name=
"CUBES_LU_BOUNDS", &
962 variants=[
"CUBES_LU"], &
963 description=
"The lower and upper index of the states to be printed as cube", &
964 usage=
"CUBES_LU_BOUNDS integer integer", &
965 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
970 description=
"Indexes of the states to be printed as cube files "// &
971 "This keyword can be repeated several times "// &
972 "(useful if you have to specify many indexes).", &
973 usage=
"CUBES_LIST 1 2", &
974 n_var=-1, type_of_var=
integer_t, repeats=.true.)
978 description=
"append the cube files when they already exist", &
979 default_l_val=.false., lone_keyword_l_val=.true.)
987 description=
"Controls the printing of susceptibility", &
993 description=
"Controls the printing of the chemical shift", &
996 CALL keyword_create(keyword, __location__, name=
"ATOMS_LU_BOUNDS", &
997 variants=[
"ATOMS_LU"], &
998 description=
"The lower and upper atomic index for which the tensor is printed", &
999 usage=
"ATOMS_LU_BOUNDS integer integer", &
1000 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
1005 description=
"list of atoms for which the shift is printed into a file ", &
1006 usage=
"ATOMS_LIST 1 2", n_var=-1, &
1017 NULLIFY (subsection)
1022 END SUBROUTINE create_nmr_section
1031 SUBROUTINE create_spin_spin_section(section)
1037 NULLIFY (keyword, print_key, subsection)
1039 cpassert(.NOT.
ASSOCIATED(section))
1041 description=
"Compute indirect spin-spin coupling constants.", &
1042 n_keywords=5, n_subsections=1, repeats=.false.)
1044 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
1045 description=
"controls the activation of the nmr calculation", &
1046 usage=
"&SPINSPIN T", &
1047 default_l_val=.false., &
1048 lone_keyword_l_val=.true.)
1052 CALL keyword_create(keyword, __location__, name=
"RESTART_SPINSPIN", &
1053 description=
"Restart the spin-spin calculation from a previous run (NOT WORKING YET)", &
1054 usage=
"RESTART_SPINSPIN", default_l_val=.false., &
1055 lone_keyword_l_val=.true.)
1059 CALL keyword_create(keyword, __location__, name=
"ISSC_ON_ATOM_LIST", &
1060 description=
"Atoms for which the issc is computed.", &
1061 usage=
"ISSC_ON_ATOM_LIST 1 2 10", &
1062 n_var=-1, type_of_var=
integer_t, repeats=.true.)
1067 description=
"Compute the Fermi contact contribution", &
1069 default_l_val=.true., lone_keyword_l_val=.true.)
1074 description=
"Compute the spin-dipolar contribution", &
1076 default_l_val=.true., lone_keyword_l_val=.true.)
1081 description=
"Compute the paramagnetic spin-orbit contribution", &
1083 default_l_val=.true., lone_keyword_l_val=.true.)
1088 description=
"Compute the diamagnetic spin-orbit contribution (NOT YET IMPLEMENTED)", &
1090 default_l_val=.true., lone_keyword_l_val=.true.)
1094 NULLIFY (subsection)
1096 description=
"print results of the indirect spin-spin calculation", &
1100 description=
"Controls the printing of the indirect spin-spin matrix", &
1104 description=
"list of atoms for which the indirect spin-spin is printed into a file ", &
1105 usage=
"ATOMS_LIST 1 2", n_var=-1, &
1116 NULLIFY (subsection)
1121 END SUBROUTINE create_spin_spin_section
1131 SUBROUTINE create_epr_section(section)
1135 TYPE(
section_type),
POINTER :: print_key, subsection, subsubsection
1137 NULLIFY (keyword, print_key, subsection, subsubsection)
1139 cpassert(.NOT.
ASSOCIATED(section))
1141 description=
"The g tensor is calculated by DFPT ", &
1142 n_keywords=5, n_subsections=1, repeats=.false., &
1145 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
1146 description=
"controls the activation of the epr calculation", &
1148 default_l_val=.false., &
1149 lone_keyword_l_val=.true.)
1154 description=
"Restart the EPR calculation from a previous run (NOT WORKING)", &
1155 usage=
"RESTART_EPR", default_l_val=.false., &
1156 lone_keyword_l_val=.true.)
1160 NULLIFY (subsection)
1162 description=
"print results of epr calculation", &
1166 description=
"Controls the printing of the components of nabla v_ks ", &
1169 description=
"The stride (X,Y,Z) used to write the cube file "// &
1170 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1171 " 1 number valid for all components.", &
1172 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1176 description=
"append the cube files when they already exist", &
1177 default_l_val=.false., lone_keyword_l_val=.true.)
1185 description=
"Controls the printing of the g tensor", &
1191 CALL keyword_create(keyword, __location__, name=
"GAPW_MAX_ALPHA", &
1192 description=
"Maximum alpha of GTH potentials allowed on the soft grids ", &
1193 usage=
"GAPW_MAX_ALPHA real", default_r_val=5.0_dp)
1197 CALL keyword_create(keyword, __location__, name=
"SOO_RHO_HARD", &
1198 description=
"Whether or not to include the atomic parts of the density "// &
1199 "in the SOO part of the g tensor", usage=
"SOO_RHO_HARD", &
1200 default_l_val=.false., lone_keyword_l_val=.true.)
1208 description=
"Controls the printing of the response functions ", &
1211 description=
"The stride (X,Y,Z) used to write the cube file "// &
1212 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1213 " 1 number valid for all components.", &
1214 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1218 CALL keyword_create(keyword, __location__, name=
"CUBES_LU_BOUNDS", &
1219 variants=[
"CUBES_LU"], &
1220 description=
"The lower and upper index of the states to be printed as cube", &
1221 usage=
"CUBES_LU_BOUNDS integer integer", &
1222 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
1227 description=
"Indexes of the states to be printed as cube files "// &
1228 "This keyword can be repeated several times "// &
1229 "(useful if you have to specify many indexes).", &
1230 usage=
"CUBES_LIST 1 2", &
1231 n_var=-1, type_of_var=
integer_t, repeats=.true.)
1235 description=
"append the cube files when they already exist", &
1236 default_l_val=.false., lone_keyword_l_val=.true.)
1246 NULLIFY (subsection)
1251 END SUBROUTINE create_epr_section
1260 SUBROUTINE create_polarizability_section(section)
1267 NULLIFY (keyword, print_key, subsection)
1269 cpassert(.NOT.
ASSOCIATED(section))
1271 description=
"Compute polarizabilities.", &
1272 n_keywords=5, n_subsections=1, repeats=.false., &
1275 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
1276 description=
"controls the activation of the polarizability calculation", &
1278 default_l_val=.false., &
1279 lone_keyword_l_val=.true.)
1284 description=
"Compute the electric-dipole--electric-dipole polarizability", &
1285 usage=
"DO_RAMAN F", &
1287 default_l_val=.true., lone_keyword_l_val=.true.)
1291 CALL keyword_create(keyword, __location__, name=
"PERIODIC_DIPOLE_OPERATOR", &
1292 description=
"Type of dipole operator: Berry phase(T) or Local(F)", &
1293 usage=
"PERIODIC_DIPOLE_OPERATOR T", &
1294 default_l_val=.true., lone_keyword_l_val=.true.)
1298 NULLIFY (subsection)
1300 description=
"print results of the polarizability calculation", &
1304 description=
"Controls the printing of the polarizabilities", &
1312 NULLIFY (subsection)
1317 END SUBROUTINE create_polarizability_section
1324 SUBROUTINE create_et_coupling_section(section)
1331 cpassert(.NOT.
ASSOCIATED(section))
1333 description=
"specifies the two constraints/restraints for extracting ET coupling elements", &
1336 NULLIFY (subsection)
1341 NULLIFY (subsection)
1346 NULLIFY (subsection)
1347 CALL create_projection(subsection,
"PROJECTION")
1351 CALL keyword_create(keyword, __location__, name=
"TYPE_OF_CONSTRAINT", &
1352 description=
"Specifies the type of constraint", &
1353 usage=
"TYPE_OF_CONSTRAINT DDAPC", &
1354 enum_c_vals=
s2a(
"NONE",
"DDAPC"), &
1356 enum_desc=
s2a(
"NONE",
"DDAPC Constraint"), &
1363 description=
"Controls the printing basic info about the method", &
1368 END SUBROUTINE create_et_coupling_section
1377 SUBROUTINE create_projection(section, section_name)
1381 CHARACTER(len=*),
INTENT(in) :: section_name
1384 TYPE(
section_type),
POINTER :: print_key, section_block, section_print
1389 cpassert(.NOT.
ASSOCIATED(section))
1394 NULLIFY (section_block)
1395 NULLIFY (section_print)
1398 CALL section_create(section, __location__, name=trim(adjustl(section_name)), &
1399 description=
"Projection-operator approach fo ET coupling calculation", &
1400 n_keywords=0, n_subsections=2, repeats=.false.)
1404 description=
"Controls printing of data and informations to log file", &
1411 description=
"Part of the system (donor, acceptor, bridge,...)", &
1412 n_keywords=2, n_subsections=1, repeats=.true.)
1417 description=
"Array of atom IDs in the system part", &
1418 usage=
"ATOMS {integer} {integer} .. {integer}", &
1419 n_var=-1, type_of_var=
integer_t, repeats=.false.)
1425 description=
"Number of electrons expected in the system part", &
1426 usage=
"NELECTRON {integer}", default_i_val=0)
1432 description=
"Possible printing options in ET system part", &
1433 n_keywords=0, n_subsections=0, repeats=.false.)
1437 CALL keyword_create(keyword, __location__, name=
'MO_COEFF_ATOM', &
1438 description=
"Print out MO coeffiecients on given atom", &
1439 usage=
"MO_COEFF_ATOM {integer} {integer} .. {integer}", &
1440 type_of_var=
integer_t, n_var=-1, repeats=.true.)
1445 CALL keyword_create(keyword, __location__, name=
'MO_COEFF_ATOM_STATE', &
1446 description=
"Print out MO coeffiecients of specific state", &
1447 usage=
"MO_COEFF_ATOM_STATE {integer} {integer} .. {integer}", &
1448 type_of_var=
integer_t, n_var=-1, repeats=.true.)
1454 description=
"Controls saving of MO cube files", &
1459 description=
"The stride (X,Y,Z) used to write the cube file", &
1460 usage=
"STRIDE {integer} {integer} {integer}", n_var=-1, &
1461 default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1467 description=
"Indices of molecular orbitals to save", &
1468 usage=
"MO_LIST {integer} {integer} .. {integer}", &
1469 type_of_var=
integer_t, n_var=-1, repeats=.true.)
1475 description=
"Number of unoccupied molecular orbitals to save", &
1476 usage=
"NLUMO {integer}", default_i_val=1)
1482 description=
"Number of occupied molecular orbitals to save", &
1483 usage=
"NHOMO {integer}", default_i_val=1)
1498 description=
"Possible printing options in ET", &
1499 n_keywords=0, n_subsections=0, repeats=.false.)
1504 description=
"Controls printing couplings onto file", &
1508 description=
"append the files when they already exist", &
1509 default_l_val=.false., lone_keyword_l_val=.true.)
1518 END SUBROUTINE create_projection
1527 SUBROUTINE create_tddfpt2_section(section)
1533 cpassert(.NOT.
ASSOCIATED(section))
1535 description=
"Parameters needed to set up the Time-Dependent "// &
1536 "Density Functional Perturbation Theory. "// &
1537 "Current implementation works for hybrid functionals. "// &
1538 "Can be used with Gaussian and Plane Waves (GPW) method only.", &
1539 n_keywords=14, n_subsections=4, repeats=.false., &
1542 NULLIFY (keyword, print_key, subsection)
1545 name=
"_SECTION_PARAMETERS_", &
1546 description=
"Controls the activation of the TDDFPT procedure", &
1547 default_l_val=.false., &
1548 lone_keyword_l_val=.true.)
1554 description=
"Number of excited states to converge.", &
1561 description=
"Maximal number of iterations to be performed.", &
1568 description=
"Maximal number of Krylov space vectors. "// &
1569 "Davidson iterations will be restarted upon reaching this limit.", &
1576 description=
"Number of unoccupied orbitals to consider. "// &
1577 "Default is to use all unoccupied orbitals (-1).", &
1584 description=
"Number of MPI processes to be used per excited state. "// &
1585 "Default is to use all processors (0).", &
1593 description=
"Options to compute the kernel", &
1594 usage=
"KERNEL FULL", &
1595 enum_c_vals=
s2a(
"FULL",
"sTDA",
"NONE"), &
1603 description=
"Selects the type of spin-flip TDDFPT kernel", &
1604 usage=
"SPINFLIP NONCOLLINEAR", &
1605 enum_c_vals=
s2a(
"NONE",
"COLLINEAR",
"NONCOLLINEAR"), &
1612 description=
"Orbital energy correction potential.", &
1613 enum_c_vals=
s2a(
"NONE",
"LB94",
"GLLB",
"SAOP",
"SHIFT"), &
1615 enum_desc=
s2a(
"No orbital correction scheme is used", &
1616 "van Leeuwen and Baerends. PRA, 49:2421, 1994", &
1617 "Gritsenko, van Leeuwen, van Lenthe, Baerends. PRA, 51:1944, 1995", &
1618 "Gritsenko, Schipper, Baerends. Chem. Phys. Lett., 302:199, 1999", &
1619 "Constant shift of virtual and/or open-shell orbitals"), &
1626 variants=
s2a(
"VIRTUAL_SHIFT"), &
1627 description=
"Constant shift of virtual state eigenvalues.", &
1628 usage=
"EV_SHIFT 0.500", &
1629 n_var=1, type_of_var=
real_t, &
1631 default_r_val=0.0_dp)
1636 variants=
s2a(
"OPEN_SHELL_SHIFT"), &
1637 description=
"Constant shift of open shell eigenvalues.", &
1638 usage=
"EOS_SHIFT 0.200", &
1639 n_var=1, type_of_var=
real_t, &
1641 default_r_val=0.0_dp)
1647 description=
"Target accuracy for excited state energies.", &
1648 n_var=1, type_of_var=
real_t, unit_str=
"hartree", &
1649 default_r_val=1.0e-5_dp)
1653 CALL keyword_create(keyword, __location__, name=
"MIN_AMPLITUDE", &
1654 description=
"The smallest excitation amplitude to print.", &
1655 n_var=1, type_of_var=
real_t, &
1656 default_r_val=5.0e-2_dp)
1660 CALL keyword_create(keyword, __location__, name=
"ORTHOGONAL_EPS", &
1661 description=
"The largest possible overlap between the ground state and "// &
1662 "orthogonalised excited state wave-functions. Davidson iterations "// &
1663 "will be restarted when the overlap goes beyond this threshold in "// &
1664 "order to prevent numerical instability.", &
1665 n_var=1, type_of_var=
real_t, &
1666 default_r_val=1.0e-4_dp)
1672 description=
"Restart the TDDFPT calculation if a restart file exists", &
1674 default_l_val=.false., lone_keyword_l_val=.true.)
1678 CALL keyword_create(keyword, __location__, name=
"RKS_TRIPLETS", &
1679 description=
"Compute triplet excited states using spin-unpolarised molecular orbitals.", &
1681 default_l_val=.false.)
1685 CALL keyword_create(keyword, __location__, name=
"ADMM_KERNEL_XC_CORRECTION", &
1686 description=
"Use/Ignore ADMM correction xc functional for TD kernel. "// &
1687 "XC correction functional is defined in ground state XC section.", &
1689 default_l_val=.true., lone_keyword_l_val=.true.)
1693 CALL keyword_create(keyword, __location__, name=
"ADMM_KERNEL_CORRECTION_SYMMETRIC", &
1694 description=
"ADMM correction functional in kernel is applied symmetrically. "// &
1695 "Original implementation is using a non-symmetric formula.", &
1697 default_l_val=.true., lone_keyword_l_val=.true.)
1702 description=
"Local resolution of identity for Coulomb contribution.", &
1704 default_l_val=.false.)
1709 description=
"Specify size of automatically generated auxiliary basis sets: "// &
1710 "Options={small,medium,large,huge}", &
1711 usage=
"AUTO_BASIS {basis_type} {basis_size}", &
1712 type_of_var=
char_t, repeats=.true., n_var=-1, default_c_vals=[
"X",
"X"])
1717 description=
"Implying smeared occupation. ", &
1719 default_l_val=.false., lone_keyword_l_val=.true.)
1723 CALL keyword_create(keyword, __location__, name=
"EXCITON_DESCRIPTORS", &
1724 description=
"Compute exciton descriptors. "// &
1725 "Details given in Manual section about Bethe Salpeter equation.", &
1727 default_l_val=.false.)
1731 CALL keyword_create(keyword, __location__, name=
"DIRECTIONAL_EXCITON_DESCRIPTORS", &
1732 description=
"Print cartesian components of exciton descriptors.", &
1734 default_l_val=.false.)
1739 CALL keyword_create(keyword, __location__, name=
"WFN_RESTART_FILE_NAME", &
1740 variants=[
"RESTART_FILE_NAME"], &
1741 description=
"Name of the wave function restart file, may include a path."// &
1742 " If no file is specified, the default is to open the file as generated by"// &
1743 " the wave function restart print key.", &
1744 usage=
"WFN_RESTART_FILE_NAME <FILENAME>", &
1750 CALL section_create(subsection, __location__, name=
"DIPOLE_MOMENTS", &
1751 description=
"Parameters to compute oscillator strengths in the dipole approximation.", &
1752 n_keywords=3, n_subsections=0, repeats=.false.)
1755 description=
"Form of dipole transition integrals.", &
1756 enum_c_vals=
s2a(
"BERRY",
"LENGTH",
"VELOCITY"), &
1757 enum_desc=
s2a(
"Based on Berry phase formula (valid for fully periodic molecular systems only)", &
1758 "Length form ⟨ i | r | j ⟩ (valid for non-periodic molecular systems only)", &
1759 "Velocity form ⟨ i | d/dr | j ⟩"), &
1766 description=
"Reference point to calculate electric "// &
1767 "dipole moments using the dipole integrals in the length form.", &
1768 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
1769 enum_desc=
s2a(
"Use Center of Mass", &
1770 "Use Center of Atomic Charges", &
1771 "Use User-defined Point", &
1772 "Use Origin of Coordinate System"), &
1781 CALL keyword_create(keyword, __location__, name=
"REFERENCE_POINT", &
1782 description=
"User-defined reference point.", &
1783 usage=
"REFERENCE_POINT x y z", &
1784 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
1794 description=
"Is jet to be implemented", &
1795 n_keywords=2, n_subsections=0, repeats=.false.)
1798 variants=
s2a(
"EPS_FILTER_MATRIX"), &
1799 description=
"The threshold used for sparse matrix operations", &
1800 usage=
"EPS_FILTER {real}", &
1802 default_r_val=1.0e-10_dp)
1807 variants=[
"ATOMIC_GRID"], &
1808 description=
"Specification of the atomic angular and radial grids for "// &
1809 "a atomic kind. This keyword must be repeated for all kinds! "// &
1810 "Usage: GRID < LEBEDEV_GRID > < RADIAL_GRID >", &
1811 usage=
"GRID {string} {integer} {integer}", &
1812 n_var=3, type_of_var=
char_t, repeats=.true.)
1830 CALL create_stda_section(subsection)
1835 CALL create_res_section(subsection)
1840 description=
"Choosing BSE kernel.", &
1841 usage=
"DO_BSE", default_l_val=.false., lone_keyword_l_val=.true.)
1851 CALL create_linres_section(subsection, create_subsections=.false., default_set_tdlr=.true.)
1857 description=
"Printing of information during the TDDFT run.", repeats=.false.)
1860 description=
"Controls the printing of the banner for TDDFPT program", &
1866 description=
"Controls the printing of initial guess vectors.", &
1872 description=
"Controls the printing of basic iteration information "// &
1873 "during the TDDFT run.", &
1879 description=
"Controls the printing of detailed energy information "// &
1880 "during the TDDFT run.", &
1886 description=
"Controls the printing of a file with all basis sets used.", &
1892 description=
"Controls the dumping of the MO restart file during TDDFPT. "// &
1893 "By default keeps a short history of three restarts.", &
1895 each_iter_names=
s2a(
"TDDFT_SCF"), each_iter_values=[10], &
1897 CALL keyword_create(keyword, __location__, name=
"BACKUP_COPIES", &
1898 description=
"Specifies the maximum number of backup copies.", &
1899 usage=
"BACKUP_COPIES {int}", &
1907 description=
"Perform a natural transition orbital analysis.", &
1910 description=
"Threshold for sum of NTO eigenvalues considered", &
1911 usage=
"Threshold 0.95", &
1914 default_r_val=0.975_dp)
1917 CALL keyword_create(keyword, __location__, name=
"INTENSITY_THRESHOLD", &
1918 description=
"Threshold for oscillator strength to screen states.", &
1919 usage=
"Intensity_threshold 0.01", &
1922 default_r_val=0.0_dp)
1926 description=
"Specifies a list of states for the NTO calculations.", &
1927 usage=
"STATE_LIST {integer} {integer} .. {integer}", &
1932 description=
"Print NTOs on Cube Files", &
1933 usage=
"CUBE_FILES {logical}", repeats=.false., n_var=1, &
1934 default_l_val=.false., lone_keyword_l_val=.true., type_of_var=
logical_t)
1938 description=
"The stride (X,Y,Z) used to write the cube file "// &
1939 "(larger values result in smaller cube files). Provide 3 numbers (for X,Y,Z) or"// &
1940 " 1 number valid for all components.", &
1941 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1945 description=
"append the cube files when they already exist", &
1946 default_l_val=.false., lone_keyword_l_val=.true.)
1953 description=
"Write the NTO in Molden file format, for visualisation.", &
1956 description=
"Specifies the number of significant digits retained. 3 is OK for visualization.", &
1957 usage=
"NDIGITS {int}", &
1962 description=
"Representation of Gaussian-type orbitals", &
1964 enum_c_vals=
s2a(
"CARTESIAN",
"SPHERICAL"), &
1966 "Cartesian Gaussian orbitals. Use with caution", &
1967 "Spherical Gaussian orbitals. Incompatible with VMD"), &
1975 description=
"Controls the printout required for NAMD with NEWTONX.", &
1977 CALL keyword_create(keyword, __location__, name=
"PRINT_VIRTUALS", &
1978 description=
"Print occupied AND virtual molecular orbital coefficients", &
1979 default_l_val=.false., lone_keyword_l_val=.true.)
1982 CALL keyword_create(keyword, __location__, name=
"PRINT_PHASES", &
1983 description=
"Print phases of occupied and virtuals MOs.", &
1984 default_l_val=.false., lone_keyword_l_val=.true.)
1987 CALL keyword_create(keyword, __location__, name=
"SCALE_WITH_PHASES", &
1988 description=
"Scale ES eigenvectors with phases of occupied and virtuals MOs.", &
1989 default_l_val=.false., lone_keyword_l_val=.true.)
1997 description=
"Controls the printout of the tddfpt2_soc modul", &
2000 description=
"Will detrement if output in eVolt will be printef.", &
2001 default_l_val=.true., lone_keyword_l_val=.true.)
2005 description=
"Will detrement if output in wavenumbers will be printed.", &
2006 default_l_val=.false., lone_keyword_l_val=.true.)
2010 description=
"Will add the SOC-Splitting as additional output", &
2011 default_l_val=.false., lone_keyword_l_val=.true.)
2015 description=
"Will add the SOC-Matrix as additional output in a different file", &
2016 default_l_val=.false., lone_keyword_l_val=.true.)
2023 description=
"Controls the calculation and printing of excited state forces. "// &
2024 "This needs a RUN_TYPE that includes force evaluation, e.g. ENERGY_FORCE", &
2027 description=
"Specifies a list of states for the force calculations.", &
2028 usage=
"LIST {integer} {integer} .. {integer}", repeats=.true., &
2033 description=
"Threshold for oszillator strength to screen states.", &
2034 usage=
"Threshold 0.01", &
2037 default_r_val=0.0_dp)
2046 END SUBROUTINE create_tddfpt2_section
2052 SUBROUTINE create_stda_section(section)
2057 cpassert(.NOT.
ASSOCIATED(section))
2059 description=
"parameters needed and setup for sTDA calculations", &
2060 n_keywords=3, n_subsections=0, repeats=.false.)
2064 variants=[
"HFX_FRACTION"], &
2065 description=
"The fraction of TB Hartree-Fock exchange to use in the Kernel. "// &
2066 "0.0 implies no HFX part is used in the kernel. ", &
2067 usage=
"FRACTION 0.0", default_r_val=0.0_dp)
2074 description=
"Explicitly including or switching off sTDA exchange", &
2075 usage=
"DO_EXCHANGE", default_l_val=.true., lone_keyword_l_val=.true.)
2080 description=
"Use Ewald type method for Coulomb interaction", &
2081 usage=
"DO_EWALD", default_l_val=.false., lone_keyword_l_val=.true.)
2085 CALL keyword_create(keyword, __location__, name=
"EPS_TD_FILTER", &
2086 description=
"Threshold for filtering the transition density matrix", &
2087 usage=
"EPS_TD_FILTER epsf", default_r_val=1.e-10_dp)
2091 CALL keyword_create(keyword, __location__, name=
"MATAGA_NISHIMOTO_CEXP", &
2092 description=
"Exponent used in Mataga-Nishimoto formula for Coulomb (alpha). "// &
2093 "Default value is method dependent!", &
2094 usage=
"MATAGA_NISHIMOTO_CEXP cexp", default_r_val=-99.0_dp)
2098 CALL keyword_create(keyword, __location__, name=
"MATAGA_NISHIMOTO_XEXP", &
2099 description=
"Exponent used in Mataga-Nishimoto formula for Exchange (beta). "// &
2100 "Default value is method dependent!", &
2101 usage=
"MATAGA_NISHIMOTO_XEXP xexp", default_r_val=-99.0_dp)
2105 CALL keyword_create(keyword, __location__, name=
"COULOMB_SR_CUT", &
2106 description=
"Maximum range of short range part of Coulomb interaction.", &
2107 usage=
"COULOMB_SR_CUT rcut", default_r_val=20.0_dp)
2111 CALL keyword_create(keyword, __location__, name=
"COULOMB_SR_EPS", &
2112 description=
"Threshold for short range part of Coulomb interaction.", &
2113 usage=
"COULOMB_SR_EPS sreps", default_r_val=1.e-03_dp)
2117 END SUBROUTINE create_stda_section
2123 SUBROUTINE create_res_section(section)
2128 cpassert(.NOT.
ASSOCIATED(section))
2129 CALL section_create(section, __location__, name=
"REDUCED_EXCITATION_SPACE", &
2130 description=
"Sets up a restricted (reduced) excitation space for TDDFT", &
2131 n_keywords=3, n_subsections=0, repeats=.false.)
2135 name=
"_SECTION_PARAMETERS_", &
2136 description=
"Controls the activation of RES calculation.", &
2137 default_l_val=.false., &
2138 lone_keyword_l_val=.true.)
2142 CALL keyword_create(keyword, __location__, name=
"ENERGY_WINDOW", &
2143 description=
"Upper and lower cutoffs [eV] for orbitals to be included for excitations. ", &
2144 usage=
"ENERGY_WINDOW -5.0 0.0", default_r_vals=[-1.0e10_dp, 1.0e10_dp], &
2145 type_of_var=
real_t, unit_str=
"eV")
2149 CALL keyword_create(keyword, __location__, name=
"UPPER_ENERGY_CUTOFF", &
2150 description=
"Upper energy cutoff [eV] for orbitals to be included in excitations.", &
2151 usage=
"UPPER_ENERGY_CUTOFF -5.0", default_r_val=1.0e10_dp, &
2152 type_of_var=
real_t, unit_str=
"eV")
2156 CALL keyword_create(keyword, __location__, name=
"LOWER_ENERGY_CUTOFF", &
2157 description=
"Lower energy cutoff [eV] for orbitals to be included in excitations.", &
2158 usage=
"LOWER_ENERGY_CUTOFF -5.0", default_r_val=-1.0e10_dp, &
2159 type_of_var=
real_t, unit_str=
"eV")
2163 CALL keyword_create(keyword, __location__, name=
"MOLECULE_LIST", &
2164 description=
"Indices of molecules to be excited. "// &
2165 "This implies the calculation of molecular states through orbital location "// &
2166 "and subspace diagonalization.", &
2167 usage=
"MOLECULE_LIST {integer} {integer} .. {integer} ", &
2168 n_var=-1, type_of_var=
integer_t, repeats=.false.)
2172 END SUBROUTINE create_res_section
2180 SUBROUTINE create_bandstructure_section(section)
2186 cpassert(.NOT.
ASSOCIATED(section))
2187 CALL section_create(section, __location__, name=
"BANDSTRUCTURE", &
2188 description=
"Parameters needed to set up a calculation for "// &
2189 "electronic level energies of molecules and the electronic band "// &
2190 "structure of materials from post-SCF schemes (GW, perturbative "// &
2191 "spin-orbit coupling). Also, the density of states (DOS), "// &
2192 "projected density of states (PDOS), local density of states (LDOS), "// &
2193 "local valence band maximum (LVBM), local conduction band minimum "// &
2194 "(LCBM) and local band gap can be calculated. Please note that "// &
2195 "all methods in this section start from a Gamma-only DFT SCF. "// &
2196 "You need to make sure that the cell chosen in the DFT SCF is "// &
2197 "converged in the cell size. Band structures are computed "// &
2198 "for the primitive cell (i.e. the smallest possible unit cell of "// &
2199 "the input structure which is detected automatically). Moreover, "// &
2200 "spin-orbit coupling (SOC) on eigenvalues and band structures is "// &
2201 "available using Hartwigsen-Goedecker-Hutter "// &
2202 "pseudopotentials.", &
2203 n_keywords=1, n_subsections=1, repeats=.false.)
2205 NULLIFY (keyword, subsection)
2207 name=
"_SECTION_PARAMETERS_", &
2208 description=
"Controls the activation of the band structure calculation.", &
2209 default_l_val=.false., &
2210 lone_keyword_l_val=.true.)
2219 CALL create_gw_section(subsection)
2223 CALL create_soc_section(subsection)
2227 CALL create_dos_section(subsection)
2231 END SUBROUTINE create_bandstructure_section
2239 SUBROUTINE create_gw_section(section)
2245 cpassert(.NOT.
ASSOCIATED(section))
2247 description=
"Parameters needed to set up a GW calculation for "// &
2248 "electronic level energies $\varepsilon_{n\mathbf{k}}^{G_0W_0}$ "// &
2249 "of molecules and the band structure of materials: "// &
2250 "$\varepsilon_{n\mathbf{k}}^{G_0W_0}= "// &
2251 "\varepsilon_{n\mathbf{k}}^\text{DFT}+\Sigma_{n\mathbf{k}} "// &
2252 "-v^\text{xc}_{n\mathbf{k}}$. "// &
2253 "For the GW algorithm for molecules, see "// &
2254 "<https://doi.org/10.1021/acs.jctc.0c01282>. "// &
2255 "For 2D materials, see <https://doi.org/10.1021/acs.jctc.3c01230>.", &
2256 n_keywords=1, n_subsections=1, repeats=.false.)
2260 name=
"_SECTION_PARAMETERS_", &
2261 description=
"Controls the activation of the GW calculation.", &
2262 default_l_val=.false., &
2263 lone_keyword_l_val=.true.)
2267 CALL keyword_create(keyword, __location__, name=
"NUM_TIME_FREQ_POINTS", &
2268 description=
"Number of discrete points for the imaginary-time "// &
2269 "grid and the imaginary-frequency grid. The more points, the more "// &
2270 "precise is the calculation. Typically, 10 points are good "// &
2271 "for 0.1 eV precision of band structures and molecular energy "// &
2272 "levels, 20 points for 0.03 eV precision, "// &
2273 "and 30 points for 0.01 eV precision, see Table I in "// &
2274 "<https://doi.org/10.1021/acs.jctc.0c01282>. GW computation time "// &
2275 "increases linearly with `NUM_TIME_FREQ_POINTS`.", &
2276 usage=
"NUM_TIME_FREQ_POINTS 30", &
2282 description=
"Determines a threshold for the DBCSR based sparse "// &
2283 "multiplications. Normally, `EPS_FILTER` determines accuracy "// &
2284 "and timing of low-scaling GW calculations. (Lower filter means "// &
2285 "higher numerical precision, but higher computational cost.)", &
2286 usage=
"EPS_FILTER 1.0E-6", &
2287 default_r_val=1.0e-8_dp)
2291 CALL keyword_create(keyword, __location__, name=
"REGULARIZATION_MINIMAX", &
2292 description=
"Parameter to regularize the Fourier transformation with minimax grids. "// &
2293 "In case the parameter 0.0 is chosen, no regularization is performed.", &
2294 usage=
"REGULARIZATION_MINIMAX 1.0E-4", &
2295 default_r_val=-1.0_dp)
2299 CALL keyword_create(keyword, __location__, name=
"REGULARIZATION_RI", &
2300 description=
"Parameter for RI regularization, setting a negative "// &
2301 "value triggers the default value. Affects RI basis set convergence "// &
2302 "but in any case large RI basis will give RI basis set convergence.", &
2303 usage=
"REGULARIZATION_RI 1.0E-4", &
2304 default_r_val=-1.0_dp)
2308 CALL keyword_create(keyword, __location__, name=
"CUTOFF_RADIUS_RI", &
2309 description=
"The cutoff radius (in Angstrom) for the truncated "// &
2310 "Coulomb operator. The larger the cutoff radius, the faster "// &
2311 "converges the resolution of the identity (RI) with respect to the "// &
2312 "RI basis set size. Larger cutoff radius means higher computational "// &
2314 usage=
"CUTOFF_RADIUS_RI 3.0", &
2316 type_of_var=
real_t, unit_str=
"angstrom")
2320 CALL keyword_create(keyword, __location__, name=
"MEMORY_PER_PROC", &
2321 description=
"Specify the available memory per MPI process. Set "// &
2322 "`MEMORY_PER_PROC` as accurately as possible for good performance. If "// &
2323 "`MEMORY_PER_PROC` is set lower as the actually available "// &
2324 "memory per MPI process, the performance will be "// &
2325 "bad; if `MEMORY_PER_PROC` is set higher as the actually "// &
2326 "available memory per MPI process, the program might run out of "// &
2327 "memory. You can calculate `MEMORY_PER_PROC` as follows: "// &
2328 "Get the memory per node on your machine, mem_per_node "// &
2329 "(for example, from a supercomputer website, typically between "// &
2330 "100 GB and 2 TB), get the number of "// &
2331 "MPI processes per node, n_MPI_proc_per_node"// &
2332 " (for example from your run-script; if you "// &
2333 "use slurm, the number behind '--ntasks-per-node' is the number "// &
2334 "of MPI processes per node). Then calculate "// &
2335 "`MEMORY_PER_PROC` = mem_per_node / n_MPI_proc_per_node "// &
2336 "(typically between 2 GB and 50 GB). Unit of keyword: Gigabyte (GB).", &
2337 usage=
"MEMORY_PER_PROC 16", &
2338 default_r_val=2.0_dp)
2342 CALL keyword_create(keyword, __location__, name=
"APPROX_KP_EXTRAPOL", &
2343 description=
"If true, use only a 4x4 kpoint mesh for frequency "// &
2344 "points $\omega_j, j \ge 2$ (instead of a 4x4 and 6x6 k-point mesh). "// &
2345 "The k-point extrapolation of $W_{PQ}(i\omega_j,\mathbf{q})$ "// &
2346 "is done approximately from $W_{PQ}(i\omega_1,\mathbf{q})$.", &
2347 usage=
"APPROX_KP_EXTRAPOL", &
2348 default_l_val=.false., lone_keyword_l_val=.true.)
2352 CALL keyword_create(keyword, __location__, name=
"SIZE_LATTICE_SUM", &
2353 description=
"Parameter determines how many neighbor cells $\mathbf{R}$ "// &
2354 "are used for computing "// &
2355 "$V_{PQ}(\mathbf{k}) = "// &
2356 "\sum_{\mathbf{R}} e^{i\mathbf{k}\cdot\mathbf{R}}\,\langle P, "// &
2357 "\text{cell}{=}\mathbf{0}|1/r|Q,\text{cell}{=}\mathbf{R}\rangle$. "// &
2358 "Normally, parameter does not need to be touched.", &
2359 usage=
"SIZE_LATTICE_SUM 4", &
2365 keyword, __location__, name=
"KPOINTS_W", &
2366 description=
"Monkhorst-Pack k-point mesh of size N_x, N_y, N_z for calculating "// &
2367 "$W_{PQ}^\mathbf{R}=\int_\text{BZ}\frac{d\mathbf{k}}{\Omega_\text{BZ}}\, "// &
2368 "e^{-i\mathbf{k}\cdot\mathbf{R}}\,W_{PQ}(\mathbf{k})$. "// &
2369 αα
"For non-periodic directions , choose N_ = 1. "// &
2370 "Automatic choice of the k-point mesh for negative "// &
2371 "values, i.e. KPOINTS_W -1 -1 -1. "// &
2372 "K-point extrapolation of W is automatically switched on.", &
2373 usage=
"KPOINTS_W N_x N_y N_z", &
2374 n_var=3, type_of_var=
integer_t, default_i_vals=[-1, -1, -1])
2379 description=
"If true, use Hedin's shift in G0W0, evGW and evGW0. "// &
2380 "Details see in Li et al. JCTC 18, 7570 "// &
2381 "(2022), Figure 1. G0W0 with Hedin's shift should give "// &
2382 "similar GW eigenvalues as evGW0; at a lower "// &
2383 "computational cost.", &
2384 usage=
"HEDIN_SHIFT", &
2385 default_l_val=.false., &
2386 lone_keyword_l_val=.true.)
2390 CALL keyword_create(keyword, __location__, name=
"FREQ_MAX_FIT", &
2391 description=Σω
"For analytic continuation, a fit on (i) is performed. "// &
2392 Σω
"This fit is then evaluated at a real frequency, (), which is used "// &
2393 "in the quasiparticle equation "// &
2394 "$\varepsilon_{n\mathbf{k}}^{G_0W_0}= "// &
2395 "\varepsilon_{n\mathbf{k}}^\text{DFT}+\Sigma_{n\mathbf{k}} "// &
2396 "-v^\text{xc}_{n\mathbf{k}}$. The keyword FREQ_MAX_FIT "// &
2397 Σω
"determines fitting range for the self-energy (i) on "// &
2398 ωω
"imaginary axis: i*[0, _max] for empty orbitals/bands, i*[-_max,0] "// &
2399 ω
"for occ orbitals. A smaller _max might lead to better numerical "// &
2400 "stability (i.e., if you observe clearly wrong GW eigenvalues/bands "// &
2401 ω
"around HOMO/LUMO, decreasing _max might fix this issue). "// &
2402 ω
"A small benchmark of _max is contained in Fig. 5 of "// &
2403 "J. Wilhelm et al., JCTC 12, 3623-3635 (2016). "// &
2404 ω
"Note that we used _max = 1 Ha = 27.211 eV in the benchmark "// &
2405 "M. Azizi et al., PRB 109, 245101 (2024).", &
2407 usage=
"FREQ_MAX_FIT 20.0", &
2412 NULLIFY (subsection, print_key)
2414 description=
"Printing of GW restarts.", &
2415 n_keywords=0, n_subsections=1, repeats=.false.)
2417 description=
"Controls the printing of restart files "// &
2420 common_iter_levels=3)
2427 END SUBROUTINE create_gw_section
2435 SUBROUTINE create_soc_section(section)
2440 cpassert(.NOT.
ASSOCIATED(section))
2442 description=
"Switch on or off spin-orbit coupling. Use SOC "// &
2443 "parameters from non-local pseudopotentials as given in "// &
2444 "Hartwigsen, Goedecker, Hutter, Eq.(18), (19), "// &
2445 "<https://doi.org/10.1103/PhysRevB.58.3641>, "// &
2446 "$V_{\mu\nu}^{\mathrm{SOC}, (\alpha)} = "// &
2447 "(\hbar/2) \langle \phi_\mu | \sum_l \Delta "// &
2448 "V_l^\mathrm{SO}(\mathbf{r},\mathbf{r}') "// &
2449 "L^{(\alpha)} | \phi_\nu \rangle, "// &
2450 "\alpha = x, y, z$.", &
2451 n_keywords=1, n_subsections=1, repeats=.false.)
2455 name=
"_SECTION_PARAMETERS_", &
2456 description=
"Controls the activation of the SOC calculation.", &
2457 default_l_val=.false., &
2458 lone_keyword_l_val=.true.)
2462 CALL keyword_create(keyword, __location__, name=
"ENERGY_WINDOW", &
2463 description=
"Apply SOC only for states with eigenvalues in the "// &
2464 "interval $[\varepsilon_\mathrm{VBM}-E_\mathrm{window}/2, "// &
2465 "\varepsilon_\mathrm{CBM}+E_\mathrm{window}/2]$. Might be necessary "// &
2466 "to use for large systems to prevent numerical instabilities.", &
2467 usage=
"ENERGY_WINDOW 5.0", &
2473 END SUBROUTINE create_soc_section
2481 SUBROUTINE create_dos_section(section)
2487 cpassert(.NOT.
ASSOCIATED(section))
2489 description=
"Parameters needed to calculate the density of states "// &
2490 "(DOS) and the projected density of states (PDOS).", &
2491 n_keywords=1, n_subsections=1, repeats=.false.)
2495 name=
"_SECTION_PARAMETERS_", &
2496 description=
"Controls the activation of the DOS calculation.", &
2497 default_l_val=.false., &
2498 lone_keyword_l_val=.true.)
2502 CALL keyword_create(keyword, __location__, name=
"ENERGY_WINDOW", &
2503 description=
"Print DOS and PDOS in the energy window "// &
2504 "$[\varepsilon_\mathrm{VBM}-E_\mathrm{window}/2, "// &
2505 "\varepsilon_\mathrm{CBM}+E_\mathrm{window}/2]$,"// &
2506 " where VBM is the valence "// &
2507 "band maximum (or highest occupied molecular orbital, HOMO, for "// &
2508 "molecules) and CBM the conduction band minimum (or lowest "// &
2509 "unoccupied molecular orbital, LUMO, for molecules).", &
2510 usage=
"ENERGY_WINDOW 5.0", &
2517 description=
"Resolution of the energy E when computing the $\rho(E)$.", &
2518 usage=
"ENERGY_STEP 0.01", &
2525 description=α
"Broadening in Gaussians used in the DOS; "// &
2526 "$\rho(E) = \sum_n \exp(((E-\varepsilon_n)/\alpha)^2)/("// &
2527 " \sqrt{2\pi} \alpha)$.", &
2528 usage=
"BROADENING 0.01", &
2535 keyword, __location__, name=
"KPOINTS", &
2536 description=
"Monkhorst-Pack k-point mesh of size N_x, N_y, N_z for calculating "// &
2537 "the density of states (DOS). In GW, the KPOINT_DOS mesh is thus used as k-point "// &
2538 αα
"mesh for the self-energy. For non-periodic directions , choose N_ = 1. "// &
2539 "Automatic choice of the k-point mesh for negative "// &
2540 α
"values, i.e. KPOINTS_DOS -1 -1 -1 (automatic choice: N_ = 1 in non-periodic "// &
2541 "direction, 8 k-points in periodic direction). If you like to compute a "// &
2542 "band structure along a k-path, you can specify the k-path in "// &
2544 usage=
"KPOINTS N_x N_y N_z", &
2545 n_var=3, type_of_var=
integer_t, default_i_vals=[-1, -1, -1])
2549 NULLIFY (subsection)
2550 CALL create_ldos_section(subsection)
2554 END SUBROUTINE create_dos_section
2560 SUBROUTINE create_ldos_section(section)
2565 cpassert(.NOT.
ASSOCIATED(section))
2567 description=
"Parameters needed to calculate the local density "// &
2568 "of states (LDOS). "// &
2569 "The LDOS is computed as $\rho(\mathbf{r},E) = "// &
2570 "\sum\limits_{n,\mathbf{k}}"// &
2571 " |\psi_{n\mathbf{k}}(r)|^2\, w_\mathbf{k}\, g(E-\varepsilon_{n\mathbf{k}})$ "// &
2572 "using the Gaussian weight function "// &
2573 "$g(x) = \exp(x^2/\alpha^2)/(\sqrt{2\pi}\alpha)$, $\alpha$ is the broadening "// &
2574 "from the &DOS section, and the k-point weight "// &
2575 "$w_\mathbf{k}$. The k-mesh is taken from the &DOS section.", &
2576 n_keywords=2, repeats=.false.)
2580 name=
"_SECTION_PARAMETERS_", &
2581 description=
"Activates the local VBM CBM gap calculation.", &
2582 default_l_val=.false., &
2583 lone_keyword_l_val=.true.)
2588 description=
"Defines whether the LDOS is integrated along a "// &
2589 "coordinate. As an example, for INTEGRATION Z, the LDOS "// &
2590 "$\rho(x,y,E) = \int dz\, \rho(x,y,z,E)$ is computed.", &
2591 usage=
"INTEGRATION Z", &
2592 enum_c_vals=
s2a(
"X",
"Y",
"Z",
"NONE"), &
2594 enum_desc=
s2a(
"Integrate over x coordinate (not yet implemented).", &
2595 "Integrate over y coordinate (not yet implemented).", &
2596 "Integrate over z coordinate.", &
2597 "No integration, print cube file as function "// &
2598 "of x,y,z (not yet implemented)."), &
2604 keyword, __location__, name=
"BIN_MESH", &
2605 description=
"Mesh of size n x m for binning the space coordinates x and y of "// &
2606 "the LDOS $\rho(x,y,E)$. If -1, no binning is performed and the "// &
2607 "fine x, y resolution of the electron density from SCF is used.", &
2608 usage=
"BIN_MESH n m", &
2609 n_var=2, type_of_var=
integer_t, default_i_vals=[10, 10])
2613 END SUBROUTINE create_ldos_section
2621 SUBROUTINE create_tipscan_section(section)
2626 cpassert(.NOT.
ASSOCIATED(section))
2628 description=
"Parameters needed to set up a Tip Scan. "// &
2629 "Needs external definition of tip induced field.", &
2630 n_keywords=1, n_subsections=1, repeats=.false.)
2635 name=
"_SECTION_PARAMETERS_", &
2636 description=
"Controls the activation of the Tip Scan procedure", &
2637 default_l_val=.false., &
2638 lone_keyword_l_val=.true.)
2642 CALL keyword_create(keyword, __location__, name=
"SCAN_DIRECTION", &
2643 description=
"Defines scan direction and scan type(line, plane).", &
2644 usage=
"SCAN_DIRECTION XY", &
2645 enum_c_vals=
s2a(
"X",
"Y",
"Z",
"XY",
"XZ",
"YZ",
"XYZ"), &
2651 CALL keyword_create(keyword, __location__, name=
"REFERENCE_POINT", &
2652 description=
"The reference point to define the absolute position of the scan. ", &
2653 usage=
"REFERENCE_POINT 0.0 0.0 1.0", &
2654 n_var=3, default_r_vals=[0.0_dp, 0.0_dp, 0.0_dp], type_of_var=
real_t, &
2655 unit_str=
"angstrom")
2660 description=
"Number of points calculated for each scan direction.", &
2661 usage=
"SCAN_POINTS 20 20", &
2667 description=
"Step size for each scan direction.", &
2668 usage=
"SCAN_STEP 0.01 0.01", &
2669 n_var=-1, type_of_var=
real_t, unit_str=
"angstrom")
2673 CALL keyword_create(keyword, __location__, name=
"TIP_FILENAME", &
2674 description=
"Filename of tip potential defined in cube file format.", &
2675 usage=
"TIP_FILENAME <filename>", &
2680 END SUBROUTINE create_tipscan_section
collects all references to literature in CP2K as new algorithms / method are included from literature...
integer, save, public putrino2000
integer, save, public weber2009
integer, save, public kondov2007
integer, save, public luber2014
integer, save, public iannuzzi2005
integer, save, public sebastiani2001
integer, save, public hernandez2025
integer, save, public putrino2002
integer, save, public vazdacruz2021
integer, save, public futera2017
routines to handle the output, The idea is to remove the decision of wheter to output and what to out...
integer, parameter, public debug_print_level
integer, parameter, public low_print_level
integer, parameter, public medium_print_level
integer, parameter, public high_print_level
integer, parameter, public add_last_numeric
integer, parameter, public silent_print_level
subroutine, public cp_print_key_section_create(print_key_section, location, name, description, print_level, each_iter_names, each_iter_values, add_last, filename, common_iter_levels, citations, unit_str)
creates a print_key section
real(kind=dp) function, public cp_unit_to_cp2k(value, unit_str, defaults, power)
converts to the internal cp2k units to the given unit
Defines the basic variable types.
integer, parameter, public dp
Utilities for string manipulations.