70#include "./base/base_uses.f90"
75 LOGICAL,
PRIVATE,
PARAMETER :: debug_this_module = .true.
76 CHARACTER(len=*),
PARAMETER,
PRIVATE :: moduleN =
'input_cp2k_properties_dft'
93 cpassert(.NOT.
ASSOCIATED(section))
95 description=
"This section is used to set up the PROPERTIES calculation.", &
96 n_keywords=0, n_subsections=6, repeats=.false.)
98 NULLIFY (subsection, keyword)
100 CALL create_linres_section(subsection, create_subsections=.true.)
104 CALL create_et_coupling_section(subsection)
117 description=
"This section is used to print the density derived atomic point charges. "// &
118 "The fit of the charges is controlled through the DENSITY_FITTING section", &
120 CALL keyword_create(keyword, __location__, name=
"TYPE_OF_DENSITY", &
121 description=
"Specifies the type of density used for the fitting", &
122 usage=
"TYPE_OF_DENSITY (FULL|SPIN)", &
123 enum_c_vals=
s2a(
"FULL",
"SPIN"), &
125 enum_desc=
s2a(
"Full density",
"Spin density"), &
132 CALL create_tddfpt2_section(subsection)
136 CALL create_rixs_section(subsection)
140 CALL create_bandstructure_section(subsection)
144 CALL create_tipscan_section(subsection)
155 SUBROUTINE create_rixs_section(section)
160 cpassert(.NOT.
ASSOCIATED(section))
162 NULLIFY (keyword, subsection, print_key)
165 description=
"Resonant Inelastic Xray Scattering using XAS_TDP and TDDFPT.", &
166 n_keywords=1, n_subsections=3, repeats=.false., &
170 name=
"_SECTION_PARAMETERS_", &
171 description=
"Controls the activation of the RIXS procedure", &
172 default_l_val=.false., &
173 lone_keyword_l_val=.true.)
178 description=
"Number of core excited states to be used in the RIXS "// &
179 "calculation. Restricting this number reduces computational cost. "// &
180 "-1 means all available core states will be used.", &
181 n_var=1, type_of_var=
integer_t, default_i_val=-1)
185 CALL keyword_create(keyword, __location__, name=
"VALENCE_STATES", &
186 description=
"Number of valence excited states to be used in the RIXS "// &
187 "calculation. Restricting this number reduces computational cost, but "// &
188 "removes spectral features corresponding to higher excitations. Should be "// &
189 "used with care. -1 means all available valence states will be used.", &
190 n_var=1, type_of_var=
integer_t, default_i_val=-1)
194 CALL create_tddfpt2_section(subsection)
202 CALL section_create(subsection, __location__,
"PRINT",
"Controls the printing of information "// &
203 "during RIXS calculations", repeats=.false.)
206 description=
"Controles the printing of the RIXS spectrum "// &
209 common_iter_levels=3)
216 END SUBROUTINE create_rixs_section
227 SUBROUTINE create_linres_section(section, create_subsections, default_set_tdlr)
229 LOGICAL,
INTENT(in) :: create_subsections
230 LOGICAL,
INTENT(IN),
OPTIONAL :: default_set_tdlr
232 INTEGER :: def_max_iter, def_precond
233 REAL(kind=
dp) :: def_egap, def_eps, def_eps_filter
237 CHARACTER(len=256) :: desc
239 NULLIFY (keyword, print_key)
241 IF (
PRESENT(default_set_tdlr))
THEN
244 def_eps_filter = 1.0e-15_dp
247 desc =
"Controls the parameters of the LINRES force calculations for excited states."
251 def_eps_filter = 0.0_dp
254 desc =
"The linear response is used to calculate one of the following properties: nmr, epr, raman, ..."
257 cpassert(.NOT.
ASSOCIATED(section))
259 description=desc, n_keywords=5, n_subsections=2, repeats=.false., &
263 description=
"target accuracy for the convergence of the conjugate gradient.", &
264 usage=
"EPS 1.e-6", default_r_val=def_eps)
269 description=
"Filter threshold for response density matrix.", &
270 usage=
"EPS_FILTER 1.e-8", default_r_val=def_eps_filter)
275 description=
"Maximum number of conjugate gradient iteration to be performed for one optimization.", &
276 usage=
"MAX_ITER 200", default_i_val=def_max_iter)
280 CALL keyword_create(keyword, __location__, name=
"RESTART_EVERY", &
281 description=
"Restart the conjugate gradient after the specified number of iterations.", &
282 usage=
"RESTART_EVERY 200", default_i_val=50)
287 keyword, __location__, name=
"PRECONDITIONER", &
288 description=
"Type of preconditioner to be used with all minimization schemes. "// &
289 "They differ in effectiveness, cost of construction, cost of application. "// &
290 "Properly preconditioned minimization can be orders of magnitude faster than doing nothing.", &
291 usage=
"PRECONDITIONER FULL_ALL", &
292 default_i_val=def_precond, &
293 enum_c_vals=
s2a(
"FULL_ALL",
"FULL_SINGLE_INVERSE",
"FULL_SINGLE",
"FULL_KINETIC",
"FULL_S_INVERSE", &
295 enum_desc=
s2a(
"Most effective state selective preconditioner based on diagonalization, "// &
296 "requires the ENERGY_GAP parameter to be an underestimate of the HOMO-LUMO gap. "// &
297 "This preconditioner is recommended for almost all systems, except very large systems where "// &
298 "make_preconditioner would dominate the total computational cost.", &
299 "Based on H-eS cholesky inversion, similar to FULL_SINGLE in preconditioning efficiency "// &
300 "but cheaper to construct, "// &
301 "might be somewhat less robust. Recommended for large systems.", &
302 "Based on H-eS diagonalisation, not as good as FULL_ALL, but somewhat cheaper to apply. ", &
303 "Cholesky inversion of S and T, fast construction, robust, and relatively good, "// &
304 "use for very large systems.", &
305 "Cholesky inversion of S, not as good as FULL_KINETIC, yet equally expensive.", &
306 "skip preconditioning"), &
313 description=
"Energy gap estimate [a.u.] for preconditioning", &
314 usage=
"ENERGY_GAP 0.1", &
315 default_r_val=def_egap)
320 description=
"Perform a linear response calculation every N-th step for MD run", &
321 usage=
"EVERY_N_STEP 50", default_i_val=1)
326 description=
"Restart the response calculation if the restart file exists", &
328 default_l_val=.false., lone_keyword_l_val=.true.)
332 CALL keyword_create(keyword, __location__, name=
"WFN_RESTART_FILE_NAME", &
333 variants=[
"RESTART_FILE_NAME"], &
334 description=
"Root of the file names where to read the response functions from "// &
335 "which to restart the calculation of the linear response", &
336 usage=
"WFN_RESTART_FILE_NAME <FILENAME>", &
341 IF (create_subsections)
THEN
348 CALL create_current_section(subsection)
352 CALL create_nmr_section(subsection)
356 CALL create_spin_spin_section(subsection)
360 CALL create_epr_section(subsection)
364 CALL create_polarizability_section(subsection)
368 CALL create_dcdr_section(subsection)
372 CALL create_vcd_section(subsection)
377 description=
"printing of information during the linear response calculation", &
381 print_key, __location__,
"program_run_info", &
382 description=
"Controls the printing of basic iteration information during the LINRES calculation", &
388 description=
"Controls the dumping of restart file of the response wavefunction. "// &
389 "For each set of response functions, i.e. for each perturbation, "// &
390 "one different restart file is dumped. These restart files should be "// &
391 "employed only to restart the same type of LINRES calculation, "// &
392 "i.e. with the same perturbation.", &
403 END SUBROUTINE create_linres_section
411 SUBROUTINE create_dcdr_section(section)
420 NULLIFY (keyword, print_key, subsection)
422 cpassert(.NOT.
ASSOCIATED(section))
424 IF (.NOT. failure)
THEN
426 description=
"Compute analytical gradients the dipole moments.", &
427 n_keywords=50, n_subsections=1, repeats=.false.)
429 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
430 description=
"controls the activation of the APT calculation", &
432 default_l_val=.false., &
433 lone_keyword_l_val=.true.)
437 CALL keyword_create(keyword, __location__, name=
"LIST_OF_ATOMS", &
438 description=
"Specifies a list of atoms.", &
439 usage=
"LIST_OF_ATOMS {integer} {integer} .. {integer}", repeats=.true., &
444 CALL keyword_create(keyword, __location__, name=
"DISTRIBUTED_ORIGIN", &
445 variants=[
"DO_GAUGE"], &
446 description=
"Use the distributed origin (DO) gauge?", &
447 usage=
"DISTRIBUTED_ORIGIN T", &
448 default_l_val=.false., lone_keyword_l_val=.true.)
452 CALL keyword_create(keyword, __location__, name=
"ORBITAL_CENTER", &
453 description=
"The orbital center.", &
454 usage=
"ORBITAL_CENTER WANNIER", &
456 enum_c_vals=
s2a(
"WANNIER",
"COMMON",
"ATOM",
"BOX"), &
457 enum_desc=
s2a(
"Use the Wannier centers.", &
458 "Use a common center (works only for an isolate molecule).", &
459 "Use the atoms as center.", &
467 description=
"Gauge origin of the velocity gauge factor.", &
468 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
469 enum_desc=
s2a(
"Use Center of Mass", &
470 "Use Center of Atomic Charges", &
471 "Use User-defined Point", &
472 "Use Origin of Coordinate System"), &
481 CALL keyword_create(keyword, __location__, name=
"REFERENCE_POINT", &
482 description=
"User-defined reference point of the velocity gauge factor.", &
483 usage=
"REFERENCE_POINT x y z", &
484 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
488 CALL keyword_create(keyword, __location__, name=
"Z_MATRIX_METHOD", &
489 description=
"Use Z_matrix method to solve the response equation", &
490 usage=
"Z_MATRIX_METHOD T", &
491 default_l_val=.false., lone_keyword_l_val=.true.)
496 description=
"Use numerical differentiation to compute the APT, "// &
497 "switches off the calculation of dcdr analytical derivatives. "// &
498 "Requires RUN_TYPE = ENERGY_FORCE or MD.", &
500 default_l_val=.false., lone_keyword_l_val=.true.)
505 description=
"Electric field strength (atomic units) to use for finite differences", &
509 default_r_val=0.0003_dp, &
510 usage=
"APT_FD_DE 1.0E-4")
514 CALL keyword_create(keyword, __location__, name=
"APT_FD_METHOD", &
515 description=
"Numerical differentiation method", &
516 usage=
"APT_FD_METHOD FD", &
519 enum_c_vals=
s2a(
"2PNT"), &
522 enum_desc=
s2a(
"Symmetric two-point differences."), &
530 description=
"print results of the magnetic dipole moment calculation", &
534 description=
"Controls the printing of the electric dipole gradient", &
549 END SUBROUTINE create_dcdr_section
557 SUBROUTINE create_vcd_section(section)
564 NULLIFY (keyword, print_key, subsection)
566 cpassert(.NOT.
ASSOCIATED(section))
569 description=
"Carry out a VCD calculation.", &
570 n_keywords=50, n_subsections=1, repeats=.false.)
572 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
573 description=
"controls the activation of the APT/AAT calculation", &
575 default_l_val=.false., &
576 lone_keyword_l_val=.true.)
580 CALL keyword_create(keyword, __location__, name=
"LIST_OF_ATOMS", &
581 description=
"Specifies a list of atoms.", &
582 usage=
"LIST_OF_ATOMS {integer} {integer} .. {integer}", repeats=.true., &
587 CALL keyword_create(keyword, __location__, name=
"DISTRIBUTED_ORIGIN", &
588 variants=[
"DO_GAUGE"], &
589 description=
"Use the distributed origin (DO) gauge?", &
590 usage=
"DISTRIBUTED_ORIGIN T", &
591 default_l_val=.false., lone_keyword_l_val=.true.)
595 CALL keyword_create(keyword, __location__, name=
"ORIGIN_DEPENDENT_MFP", &
596 description=
"Use the origin dependent MFP operator.", &
597 usage=
"ORIGIN_DEPENDENT_MFP T", &
598 default_l_val=.false., lone_keyword_l_val=.true.)
602 CALL keyword_create(keyword, __location__, name=
"ORBITAL_CENTER", &
603 description=
"The orbital center.", &
604 usage=
"ORBITAL_CENTER WANNIER", &
606 enum_c_vals=
s2a(
"WANNIER",
"COMMON",
"ATOM",
"BOX"), &
607 enum_desc=
s2a(
"Use the Wannier centers.", &
608 "Use a common center (works only for an isolate molecule).", &
609 "Use the atoms as center.", &
617 CALL keyword_create(keyword, __location__, name=
"MAGNETIC_ORIGIN", &
618 description=
"Gauge origin of the magnetic dipole operator.", &
619 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
620 enum_desc=
s2a(
"Use Center of Mass", &
621 "Use Center of Atomic Charges", &
622 "Use User-defined Point", &
623 "Use Origin of Coordinate System"), &
632 CALL keyword_create(keyword, __location__, name=
"MAGNETIC_ORIGIN_REFERENCE", &
633 description=
"User-defined reference point of the magnetic dipole operator.", &
634 usage=
"MAGNETIC_ORIGIN_REFERENCE x y z", &
635 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
640 CALL keyword_create(keyword, __location__, name=
"SPATIAL_ORIGIN", &
641 description=
"Gauge origin of the velocity gauge factor/spatial origin.", &
642 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
643 enum_desc=
s2a(
"Use Center of Mass", &
644 "Use Center of Atomic Charges", &
645 "Use User-defined Point", &
646 "Use Origin of Coordinate System"), &
655 CALL keyword_create(keyword, __location__, name=
"SPATIAL_ORIGIN_REFERENCE", &
656 description=
"User-defined reference point of the velocity gauge factor/spatial origin.", &
657 usage=
"SPATIAL_ORIGIN_REFERENCE x y z", &
658 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
664 description=
"print results of the magnetic dipole moment calculation", &
668 description=
"Controls the printing of the APTs and AATs", &
681 END SUBROUTINE create_vcd_section
690 SUBROUTINE create_current_section(section)
696 NULLIFY (keyword, print_key, subsection)
698 cpassert(.NOT.
ASSOCIATED(section))
700 description=
"The induced current density is calculated by DFPT.", &
701 n_keywords=4, n_subsections=1, repeats=.false., &
704 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
705 description=
"controls the activation of the induced current calculation", &
706 usage=
"&CURRENT T", &
707 default_l_val=.false., &
708 lone_keyword_l_val=.true.)
713 description=
"The gauge used to compute the induced current within GAPW.", &
716 enum_c_vals=
s2a(
"R",
"R_AND_STEP_FUNCTION",
"ATOM"), &
717 enum_desc=
s2a(
"Position gauge (doesnt work well).", &
718 "Position and step function for the soft and the local parts, respectively.", &
724 CALL keyword_create(keyword, __location__, name=
"GAUGE_ATOM_RADIUS", &
725 description=
"Build the gauge=atom using only the atoms within this radius.", &
726 usage=
"GAUGE_ATOM_RADIUS 10.0", &
733 CALL keyword_create(keyword, __location__, name=
"USE_OLD_GAUGE_ATOM", &
734 description=
"Use the old way to compute the gauge.", &
735 usage=
"USE_OLD_GAUGE_ATOM T", &
736 default_l_val=.true., lone_keyword_l_val=.true.)
740 CALL keyword_create(keyword, __location__, name=
"ORBITAL_CENTER", &
741 description=
"The orbital center.", &
742 usage=
"ORBITAL_CENTER WANNIER", &
744 enum_c_vals=
s2a(
"WANNIER",
"COMMON",
"ATOM",
"BOX"), &
745 enum_desc=
s2a(
"Use the Wannier centers.", &
746 "Use a common center (works only for an isolate molecule).", &
747 "Use the atoms as center.", &
754 CALL keyword_create(keyword, __location__, name=
"COMMON_CENTER", &
755 description=
"The common center ", usage=
"COMMON_CENTER 0.0 1.0 0.0", &
756 n_var=3, default_r_vals=[0.0_dp, 0.0_dp, 0.0_dp], type_of_var=
real_t, &
762 description=
"How many boxes along each directions ", usage=
"NBOX 6 6 5", &
763 n_var=3, default_i_vals=[4, 4, 4], type_of_var=
integer_t)
768 description=
"Calculate the succeptibility correction to the shift with PBC", &
770 default_l_val=.false., lone_keyword_l_val=.true.)
774 CALL keyword_create(keyword, __location__, name=
"FORCE_NO_FULL", &
775 description=
"Avoid the calculation of the state dependent perturbation term, "// &
776 "even if the orbital centers are set at Wannier centers or at Atom centers", &
777 usage=
"FORCE_NO_FULL T", &
778 default_l_val=.false., lone_keyword_l_val=.true.)
782 CALL keyword_create(keyword, __location__, name=
"SELECTED_STATES_ON_ATOM_LIST", &
783 description=
"Indexes of the atoms for selecting"// &
784 " the states to be used for the response calculations.", &
785 usage=
"SELECTED_STATES_ON_ATOM_LIST 1 2 10", &
786 n_var=-1, type_of_var=
integer_t, repeats=.true.)
790 CALL keyword_create(keyword, __location__, name=
"SELECTED_STATES_ATOM_RADIUS", &
791 description=
"Select all the states included in the given radius around each atoms "// &
792 "in SELECTED_STATES_ON_ATOM_LIST.", &
793 usage=
"SELECTED_STATES_ATOM_RADIUS 2.0", &
800 CALL keyword_create(keyword, __location__, name=
"RESTART_CURRENT", &
801 description=
"Restart the induced current density calculation"// &
802 " from a previous run (not working yet).", &
803 usage=
"RESTART_CURRENT", default_l_val=.false., &
804 lone_keyword_l_val=.true.)
810 description=
"print results of induced current density calculation", &
814 description=
"Controls the printing of the induced current density (not working yet).", &
817 description=
"The stride (X,Y,Z) used to write the cube file "// &
818 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
819 " 1 number valid for all components (not working yet).", &
820 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
824 description=
"append the cube files when they already exist", &
825 default_l_val=.false., lone_keyword_l_val=.true.)
833 description=
"Controls the printing of the response functions (not working yet).", &
836 description=
"The stride (X,Y,Z) used to write the cube file "// &
837 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
838 " 1 number valid for all components (not working yet).", &
839 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
843 CALL keyword_create(keyword, __location__, name=
"CUBES_LU_BOUNDS", &
844 variants=[
"CUBES_LU"], &
845 description=
"The lower and upper index of the states to be printed as cube (not working yet).", &
846 usage=
"CUBES_LU_BOUNDS integer integer", &
847 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
852 description=
"Indexes of the states to be printed as cube files "// &
853 "This keyword can be repeated several times "// &
854 "(useful if you have to specify many indexes) (not working yet).", &
855 usage=
"CUBES_LIST 1 2", &
856 n_var=-1, type_of_var=
integer_t, repeats=.true.)
860 description=
"append the cube files when they already exist", &
861 default_l_val=.false., lone_keyword_l_val=.true.)
876 END SUBROUTINE create_current_section
886 SUBROUTINE create_nmr_section(section)
892 NULLIFY (keyword, print_key, subsection)
894 cpassert(.NOT.
ASSOCIATED(section))
896 description=
"The chemical shift is calculated by DFPT.", &
897 n_keywords=5, n_subsections=1, repeats=.false., &
900 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
901 description=
"controls the activation of the nmr calculation", &
903 default_l_val=.false., &
904 lone_keyword_l_val=.true.)
908 CALL keyword_create(keyword, __location__, name=
"INTERPOLATE_SHIFT", &
909 description=
"Calculate the soft part of the chemical shift by interpolation ", &
910 usage=
"INTERPOLATE_SHIFT T", &
911 default_l_val=.false., lone_keyword_l_val=.true.)
916 description=
"Calculate the chemical shift in a set of points"// &
917 " given from an external file", usage=
"NICS", &
918 default_l_val=.false., lone_keyword_l_val=.true.)
922 CALL keyword_create(keyword, __location__, name=
"NICS_FILE_NAME", &
923 description=
"Name of the file with the NICS points coordinates", &
924 usage=
"NICS_FILE_NAME nics_file", &
925 default_lc_val=
"nics_file")
930 description=
"Restart the NMR calculation from a previous run (NOT WORKING YET)", &
931 usage=
"RESTART_NMR", default_l_val=.false., &
932 lone_keyword_l_val=.true.)
936 CALL keyword_create(keyword, __location__, name=
"SHIFT_GAPW_RADIUS", &
937 description=
"While computing the local part of the shift (GAPW), "// &
938 "the integration is restricted to nuclei that are within this radius.", &
939 usage=
"SHIFT_GAPW_RADIUS 20.0", &
948 description=
"print results of nmr calculation", &
952 description=
"Controls the printing of the response functions ", &
955 description=
"The stride (X,Y,Z) used to write the cube file "// &
956 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
957 " 1 number valid for all components.", &
958 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
962 CALL keyword_create(keyword, __location__, name=
"CUBES_LU_BOUNDS", &
963 variants=[
"CUBES_LU"], &
964 description=
"The lower and upper index of the states to be printed as cube", &
965 usage=
"CUBES_LU_BOUNDS integer integer", &
966 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
971 description=
"Indexes of the states to be printed as cube files "// &
972 "This keyword can be repeated several times "// &
973 "(useful if you have to specify many indexes).", &
974 usage=
"CUBES_LIST 1 2", &
975 n_var=-1, type_of_var=
integer_t, repeats=.true.)
979 description=
"append the cube files when they already exist", &
980 default_l_val=.false., lone_keyword_l_val=.true.)
988 description=
"Controls the printing of susceptibility", &
994 description=
"Controls the printing of the chemical shift", &
997 CALL keyword_create(keyword, __location__, name=
"ATOMS_LU_BOUNDS", &
998 variants=[
"ATOMS_LU"], &
999 description=
"The lower and upper atomic index for which the tensor is printed", &
1000 usage=
"ATOMS_LU_BOUNDS integer integer", &
1001 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
1006 description=
"list of atoms for which the shift is printed into a file ", &
1007 usage=
"ATOMS_LIST 1 2", n_var=-1, &
1018 NULLIFY (subsection)
1023 END SUBROUTINE create_nmr_section
1032 SUBROUTINE create_spin_spin_section(section)
1038 NULLIFY (keyword, print_key, subsection)
1040 cpassert(.NOT.
ASSOCIATED(section))
1042 description=
"Compute indirect spin-spin coupling constants.", &
1043 n_keywords=5, n_subsections=1, repeats=.false.)
1045 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
1046 description=
"controls the activation of the nmr calculation", &
1047 usage=
"&SPINSPIN T", &
1048 default_l_val=.false., &
1049 lone_keyword_l_val=.true.)
1053 CALL keyword_create(keyword, __location__, name=
"RESTART_SPINSPIN", &
1054 description=
"Restart the spin-spin calculation from a previous run (NOT WORKING YET)", &
1055 usage=
"RESTART_SPINSPIN", default_l_val=.false., &
1056 lone_keyword_l_val=.true.)
1060 CALL keyword_create(keyword, __location__, name=
"ISSC_ON_ATOM_LIST", &
1061 description=
"Atoms for which the issc is computed.", &
1062 usage=
"ISSC_ON_ATOM_LIST 1 2 10", &
1063 n_var=-1, type_of_var=
integer_t, repeats=.true.)
1068 description=
"Compute the Fermi contact contribution", &
1070 default_l_val=.true., lone_keyword_l_val=.true.)
1075 description=
"Compute the spin-dipolar contribution", &
1077 default_l_val=.true., lone_keyword_l_val=.true.)
1082 description=
"Compute the paramagnetic spin-orbit contribution", &
1084 default_l_val=.true., lone_keyword_l_val=.true.)
1089 description=
"Compute the diamagnetic spin-orbit contribution (NOT YET IMPLEMENTED)", &
1091 default_l_val=.true., lone_keyword_l_val=.true.)
1095 NULLIFY (subsection)
1097 description=
"print results of the indirect spin-spin calculation", &
1101 description=
"Controls the printing of the indirect spin-spin matrix", &
1105 description=
"list of atoms for which the indirect spin-spin is printed into a file ", &
1106 usage=
"ATOMS_LIST 1 2", n_var=-1, &
1117 NULLIFY (subsection)
1122 END SUBROUTINE create_spin_spin_section
1132 SUBROUTINE create_epr_section(section)
1136 TYPE(
section_type),
POINTER :: print_key, subsection, subsubsection
1138 NULLIFY (keyword, print_key, subsection, subsubsection)
1140 cpassert(.NOT.
ASSOCIATED(section))
1142 description=
"The g tensor is calculated by DFPT ", &
1143 n_keywords=5, n_subsections=1, repeats=.false., &
1146 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
1147 description=
"controls the activation of the epr calculation", &
1149 default_l_val=.false., &
1150 lone_keyword_l_val=.true.)
1155 description=
"Restart the EPR calculation from a previous run (NOT WORKING)", &
1156 usage=
"RESTART_EPR", default_l_val=.false., &
1157 lone_keyword_l_val=.true.)
1161 NULLIFY (subsection)
1163 description=
"print results of epr calculation", &
1167 description=
"Controls the printing of the components of nabla v_ks ", &
1170 description=
"The stride (X,Y,Z) used to write the cube file "// &
1171 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1172 " 1 number valid for all components.", &
1173 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1177 description=
"append the cube files when they already exist", &
1178 default_l_val=.false., lone_keyword_l_val=.true.)
1186 description=
"Controls the printing of the g tensor", &
1192 CALL keyword_create(keyword, __location__, name=
"GAPW_MAX_ALPHA", &
1193 description=
"Maximum alpha of GTH potentials allowed on the soft grids ", &
1194 usage=
"GAPW_MAX_ALPHA real", default_r_val=5.0_dp)
1198 CALL keyword_create(keyword, __location__, name=
"SOO_RHO_HARD", &
1199 description=
"Whether or not to include the atomic parts of the density "// &
1200 "in the SOO part of the g tensor", usage=
"SOO_RHO_HARD", &
1201 default_l_val=.false., lone_keyword_l_val=.true.)
1209 description=
"Controls the printing of the response functions ", &
1212 description=
"The stride (X,Y,Z) used to write the cube file "// &
1213 "(larger values result in smaller cube files). You can provide 3 numbers (for X,Y,Z) or"// &
1214 " 1 number valid for all components.", &
1215 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1219 CALL keyword_create(keyword, __location__, name=
"CUBES_LU_BOUNDS", &
1220 variants=[
"CUBES_LU"], &
1221 description=
"The lower and upper index of the states to be printed as cube", &
1222 usage=
"CUBES_LU_BOUNDS integer integer", &
1223 n_var=2, default_i_vals=[0, -2], type_of_var=
integer_t)
1228 description=
"Indexes of the states to be printed as cube files "// &
1229 "This keyword can be repeated several times "// &
1230 "(useful if you have to specify many indexes).", &
1231 usage=
"CUBES_LIST 1 2", &
1232 n_var=-1, type_of_var=
integer_t, repeats=.true.)
1236 description=
"append the cube files when they already exist", &
1237 default_l_val=.false., lone_keyword_l_val=.true.)
1247 NULLIFY (subsection)
1252 END SUBROUTINE create_epr_section
1261 SUBROUTINE create_polarizability_section(section)
1268 NULLIFY (keyword, print_key, subsection)
1270 cpassert(.NOT.
ASSOCIATED(section))
1272 description=
"Compute polarizabilities.", &
1273 n_keywords=5, n_subsections=1, repeats=.false., &
1276 CALL keyword_create(keyword, __location__, name=
"_SECTION_PARAMETERS_", &
1277 description=
"controls the activation of the polarizability calculation", &
1279 default_l_val=.false., &
1280 lone_keyword_l_val=.true.)
1285 description=
"Compute the electric-dipole--electric-dipole polarizability", &
1286 usage=
"DO_RAMAN F", &
1288 default_l_val=.true., lone_keyword_l_val=.true.)
1292 CALL keyword_create(keyword, __location__, name=
"PERIODIC_DIPOLE_OPERATOR", &
1293 description=
"Type of dipole operator: Berry phase(T) or Local(F)", &
1294 usage=
"PERIODIC_DIPOLE_OPERATOR T", &
1295 default_l_val=.true., lone_keyword_l_val=.true.)
1299 NULLIFY (subsection)
1301 description=
"print results of the polarizability calculation", &
1305 description=
"Controls the printing of the polarizabilities", &
1313 NULLIFY (subsection)
1318 END SUBROUTINE create_polarizability_section
1325 SUBROUTINE create_et_coupling_section(section)
1332 cpassert(.NOT.
ASSOCIATED(section))
1334 description=
"specifies the two constraints/restraints for extracting ET coupling elements", &
1337 NULLIFY (subsection)
1342 NULLIFY (subsection)
1347 NULLIFY (subsection)
1348 CALL create_projection(subsection,
"PROJECTION")
1352 CALL keyword_create(keyword, __location__, name=
"TYPE_OF_CONSTRAINT", &
1353 description=
"Specifies the type of constraint", &
1354 usage=
"TYPE_OF_CONSTRAINT DDAPC", &
1355 enum_c_vals=
s2a(
"NONE",
"DDAPC"), &
1357 enum_desc=
s2a(
"NONE",
"DDAPC Constraint"), &
1364 description=
"Controls the printing basic info about the method", &
1369 END SUBROUTINE create_et_coupling_section
1378 SUBROUTINE create_projection(section, section_name)
1382 CHARACTER(len=*),
INTENT(in) :: section_name
1385 TYPE(
section_type),
POINTER :: print_key, section_block, section_print
1390 cpassert(.NOT.
ASSOCIATED(section))
1395 NULLIFY (section_block)
1396 NULLIFY (section_print)
1399 CALL section_create(section, __location__, name=trim(adjustl(section_name)), &
1400 description=
"Projection-operator approach fo ET coupling calculation", &
1401 n_keywords=0, n_subsections=2, repeats=.false.)
1405 description=
"Controls printing of data and informations to log file", &
1412 description=
"Part of the system (donor, acceptor, bridge,...)", &
1413 n_keywords=2, n_subsections=1, repeats=.true.)
1418 description=
"Array of atom IDs in the system part", &
1419 usage=
"ATOMS {integer} {integer} .. {integer}", &
1420 n_var=-1, type_of_var=
integer_t, repeats=.false.)
1426 description=
"Number of electrons expected in the system part", &
1427 usage=
"NELECTRON {integer}", default_i_val=0)
1433 description=
"Possible printing options in ET system part", &
1434 n_keywords=0, n_subsections=0, repeats=.false.)
1438 CALL keyword_create(keyword, __location__, name=
'MO_COEFF_ATOM', &
1439 description=
"Print out MO coeffiecients on given atom", &
1440 usage=
"MO_COEFF_ATOM {integer} {integer} .. {integer}", &
1441 type_of_var=
integer_t, n_var=-1, repeats=.true.)
1446 CALL keyword_create(keyword, __location__, name=
'MO_COEFF_ATOM_STATE', &
1447 description=
"Print out MO coeffiecients of specific state", &
1448 usage=
"MO_COEFF_ATOM_STATE {integer} {integer} .. {integer}", &
1449 type_of_var=
integer_t, n_var=-1, repeats=.true.)
1455 description=
"Controls saving of MO cube files", &
1460 description=
"The stride (X,Y,Z) used to write the cube file", &
1461 usage=
"STRIDE {integer} {integer} {integer}", n_var=-1, &
1462 default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1468 description=
"Indices of molecular orbitals to save", &
1469 usage=
"MO_LIST {integer} {integer} .. {integer}", &
1470 type_of_var=
integer_t, n_var=-1, repeats=.true.)
1476 description=
"Number of unoccupied molecular orbitals to save", &
1477 usage=
"NLUMO {integer}", default_i_val=1)
1483 description=
"Number of occupied molecular orbitals to save", &
1484 usage=
"NHOMO {integer}", default_i_val=1)
1499 description=
"Possible printing options in ET", &
1500 n_keywords=0, n_subsections=0, repeats=.false.)
1505 description=
"Controls printing couplings onto file", &
1509 description=
"append the files when they already exist", &
1510 default_l_val=.false., lone_keyword_l_val=.true.)
1519 END SUBROUTINE create_projection
1528 SUBROUTINE create_tddfpt2_section(section)
1534 cpassert(.NOT.
ASSOCIATED(section))
1536 description=
"Parameters needed to set up the Time-Dependent "// &
1537 "Density Functional Perturbation Theory. "// &
1538 "Current implementation works for hybrid functionals. ", &
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"), &
1607 enum_desc=
s2a(
"Only molecular orbital energy differences are considered", &
1608 "MO energy diferences and Fock exchange contributions are "// &
1610 "MO energy differences, Fock exchange and "// &
1611 "Noncollinear local exchange-correlation "// &
1612 "kernel are considered"), &
1618 description=
"Orbital energy correction potential.", &
1619 enum_c_vals=
s2a(
"NONE",
"LB94",
"GLLB",
"SAOP",
"SHIFT"), &
1621 enum_desc=
s2a(
"No orbital correction scheme is used", &
1622 "van Leeuwen and Baerends. PRA, 49:2421, 1994", &
1623 "Gritsenko, van Leeuwen, van Lenthe, Baerends. PRA, 51:1944, 1995", &
1624 "Gritsenko, Schipper, Baerends. Chem. Phys. Lett., 302:199, 1999", &
1625 "Constant shift of virtual and/or open-shell orbitals"), &
1632 variants=
s2a(
"VIRTUAL_SHIFT"), &
1633 description=
"Constant shift of virtual state eigenvalues.", &
1634 usage=
"EV_SHIFT 0.500", &
1635 n_var=1, type_of_var=
real_t, &
1637 default_r_val=0.0_dp)
1642 variants=
s2a(
"OPEN_SHELL_SHIFT"), &
1643 description=
"Constant shift of open shell eigenvalues.", &
1644 usage=
"EOS_SHIFT 0.200", &
1645 n_var=1, type_of_var=
real_t, &
1647 default_r_val=0.0_dp)
1653 description=
"Target accuracy for excited state energies.", &
1654 n_var=1, type_of_var=
real_t, unit_str=
"hartree", &
1655 default_r_val=1.0e-5_dp)
1659 CALL keyword_create(keyword, __location__, name=
"MIN_AMPLITUDE", &
1660 description=
"The smallest excitation amplitude to print.", &
1661 n_var=1, type_of_var=
real_t, &
1662 default_r_val=5.0e-2_dp)
1666 CALL keyword_create(keyword, __location__, name=
"ORTHOGONAL_EPS", &
1667 description=
"The largest possible overlap between the ground state and "// &
1668 "orthogonalised excited state wave-functions. Davidson iterations "// &
1669 "will be restarted when the overlap goes beyond this threshold in "// &
1670 "order to prevent numerical instability.", &
1671 n_var=1, type_of_var=
real_t, &
1672 default_r_val=1.0e-4_dp)
1678 description=
"Restart the TDDFPT calculation if a restart file exists", &
1680 default_l_val=.false., lone_keyword_l_val=.true.)
1684 CALL keyword_create(keyword, __location__, name=
"RKS_TRIPLETS", &
1685 description=
"Compute triplet excited states using spin-unpolarised molecular orbitals.", &
1687 default_l_val=.false.)
1691 CALL keyword_create(keyword, __location__, name=
"ADMM_KERNEL_XC_CORRECTION", &
1692 description=
"Use/Ignore ADMM correction xc functional for TD kernel. "// &
1693 "XC correction functional is defined in ground state XC section.", &
1695 default_l_val=.true., lone_keyword_l_val=.true.)
1699 CALL keyword_create(keyword, __location__, name=
"ADMM_KERNEL_CORRECTION_SYMMETRIC", &
1700 description=
"ADMM correction functional in kernel is applied symmetrically. "// &
1701 "Original implementation is using a non-symmetric formula.", &
1703 default_l_val=.true., lone_keyword_l_val=.true.)
1708 description=
"Local resolution of identity for Coulomb contribution.", &
1710 default_l_val=.false.)
1715 description=
"Specify size of automatically generated auxiliary basis sets: "// &
1716 "Options={small,medium,large,huge}", &
1717 usage=
"AUTO_BASIS {basis_type} {basis_size}", &
1718 type_of_var=
char_t, repeats=.true., n_var=-1, default_c_vals=[
"X",
"X"])
1723 description=
"Implying smeared occupation. ", &
1725 default_l_val=.false., lone_keyword_l_val=.true.)
1729 CALL keyword_create(keyword, __location__, name=
"EXCITON_DESCRIPTORS", &
1730 description=
"Compute exciton descriptors. "// &
1731 "Details given in Manual section about Bethe Salpeter equation.", &
1733 default_l_val=.false.)
1737 CALL keyword_create(keyword, __location__, name=
"DIRECTIONAL_EXCITON_DESCRIPTORS", &
1738 description=
"Print cartesian components of exciton descriptors.", &
1740 default_l_val=.false.)
1745 CALL keyword_create(keyword, __location__, name=
"WFN_RESTART_FILE_NAME", &
1746 variants=[
"RESTART_FILE_NAME"], &
1747 description=
"Name of the wave function restart file, may include a path."// &
1748 " If no file is specified, the default is to open the file as generated by"// &
1749 " the wave function restart print key.", &
1750 usage=
"WFN_RESTART_FILE_NAME <FILENAME>", &
1756 CALL section_create(subsection, __location__, name=
"DIPOLE_MOMENTS", &
1757 description=
"Parameters to compute oscillator strengths in the dipole approximation.", &
1758 n_keywords=3, n_subsections=0, repeats=.false.)
1761 description=
"Form of dipole transition integrals.", &
1762 enum_c_vals=
s2a(
"BERRY",
"LENGTH",
"VELOCITY"), &
1763 enum_desc=
s2a(
"Based on Berry phase formula (valid for fully periodic molecular systems only)", &
1764 "Length form ⟨ i | r | j ⟩ (valid for non-periodic molecular systems only)", &
1765 "Velocity form ⟨ i | d/dr | j ⟩"), &
1772 description=
"Reference point to calculate electric "// &
1773 "dipole moments using the dipole integrals in the length form.", &
1774 enum_c_vals=
s2a(
"COM",
"COAC",
"USER_DEFINED",
"ZERO"), &
1775 enum_desc=
s2a(
"Use Center of Mass", &
1776 "Use Center of Atomic Charges", &
1777 "Use User-defined Point", &
1778 "Use Origin of Coordinate System"), &
1787 CALL keyword_create(keyword, __location__, name=
"REFERENCE_POINT", &
1788 description=
"User-defined reference point.", &
1789 usage=
"REFERENCE_POINT x y z", &
1790 repeats=.false., n_var=3, type_of_var=
real_t, unit_str=
'bohr')
1800 description=
"Is jet to be implemented", &
1801 n_keywords=2, n_subsections=0, repeats=.false.)
1804 variants=
s2a(
"EPS_FILTER_MATRIX"), &
1805 description=
"The threshold used for sparse matrix operations", &
1806 usage=
"EPS_FILTER {real}", &
1808 default_r_val=1.0e-10_dp)
1813 variants=[
"ATOMIC_GRID"], &
1814 description=
"Specification of the atomic angular and radial grids for "// &
1815 "a atomic kind. This keyword must be repeated for all kinds! "// &
1816 "Usage: GRID < LEBEDEV_GRID > < RADIAL_GRID >", &
1817 usage=
"GRID {string} {integer} {integer}", &
1818 n_var=3, type_of_var=
char_t, repeats=.true.)
1836 CALL create_stda_section(subsection)
1841 CALL create_res_section(subsection)
1846 description=
"Choosing BSE kernel.", &
1847 usage=
"DO_BSE", default_l_val=.false., lone_keyword_l_val=.true.)
1857 CALL create_linres_section(subsection, create_subsections=.false., default_set_tdlr=.true.)
1863 description=
"Printing of information during the TDDFT run.", repeats=.false.)
1866 description=
"Controls the printing of the banner for TDDFPT program", &
1872 description=
"Controls the printing of initial guess vectors.", &
1878 description=
"Controls the printing of basic iteration information "// &
1879 "during the TDDFT run.", &
1885 description=
"Controls the printing of detailed energy information "// &
1886 "during the TDDFT run.", &
1892 description=
"Controls the printing of a file with all basis sets used.", &
1898 description=
"Controls the dumping of the MO restart file during TDDFPT. "// &
1899 "By default keeps a short history of three restarts.", &
1901 each_iter_names=
s2a(
"TDDFT_SCF"), each_iter_values=[10], &
1903 CALL keyword_create(keyword, __location__, name=
"BACKUP_COPIES", &
1904 description=
"Specifies the maximum number of backup copies.", &
1905 usage=
"BACKUP_COPIES {int}", &
1913 description=
"Perform a natural transition orbital analysis.", &
1916 description=
"Threshold for sum of NTO eigenvalues considered", &
1917 usage=
"Threshold 0.95", &
1920 default_r_val=0.975_dp)
1923 CALL keyword_create(keyword, __location__, name=
"INTENSITY_THRESHOLD", &
1924 description=
"Threshold for oscillator strength to screen states.", &
1925 usage=
"Intensity_threshold 0.01", &
1928 default_r_val=0.0_dp)
1932 description=
"Specifies a list of states for the NTO calculations.", &
1933 usage=
"STATE_LIST {integer} {integer} .. {integer}", &
1938 description=
"Print NTOs on Cube Files", &
1939 usage=
"CUBE_FILES {logical}", repeats=.false., n_var=1, &
1940 default_l_val=.false., lone_keyword_l_val=.true., type_of_var=
logical_t)
1944 description=
"The stride (X,Y,Z) used to write the cube file "// &
1945 "(larger values result in smaller cube files). Provide 3 numbers (for X,Y,Z) or"// &
1946 " 1 number valid for all components.", &
1947 usage=
"STRIDE 2 2 2", n_var=-1, default_i_vals=[2, 2, 2], type_of_var=
integer_t)
1951 description=
"append the cube files when they already exist", &
1952 default_l_val=.false., lone_keyword_l_val=.true.)
1959 description=
"Write the NTO in Molden file format, for visualisation.", &
1962 description=
"Unit for coordinates and cell in the MOLDEN file.", &
1963 usage=
"UNIT ANGSTROM", &
1964 enum_c_vals=
s2a(
"BOHR",
"ANGSTROM"), &
1965 enum_desc=
s2a(
"Write in Bohr (AU)",
"Write in Angstrom"), &
1966 enum_i_vals=[1, 2], &
1971 description=
"Controls whether the [Cell] block is written to the MOLDEN file.", &
1972 usage=
"WRITE_CELL TRUE", &
1973 default_l_val=.false., lone_keyword_l_val=.true.)
1977 description=
"Controls whether the [Nval] block is written to the MOLDEN file.", &
1978 usage=
"WRITE_NVAL TRUE", &
1979 default_l_val=.false., lone_keyword_l_val=.true.)
1983 description=
"Specifies the number of significant digits retained. 3 is OK for visualization.", &
1984 usage=
"NDIGITS {int}", &
1989 description=
"Representation of Gaussian-type orbitals", &
1991 enum_c_vals=
s2a(
"CARTESIAN",
"SPHERICAL"), &
1993 "Cartesian Gaussian orbitals. Use with caution", &
1994 "Spherical Gaussian orbitals. Incompatible with VMD"), &
2002 description=
"Controls the printout required for NAMD with NEWTONX.", &
2004 CALL keyword_create(keyword, __location__, name=
"PRINT_VIRTUALS", &
2005 description=
"Print occupied AND virtual molecular orbital coefficients", &
2006 default_l_val=.false., lone_keyword_l_val=.true.)
2009 CALL keyword_create(keyword, __location__, name=
"PRINT_PHASES", &
2010 description=
"Print phases of occupied and virtuals MOs.", &
2011 default_l_val=.false., lone_keyword_l_val=.true.)
2014 CALL keyword_create(keyword, __location__, name=
"SCALE_WITH_PHASES", &
2015 description=
"Scale ES eigenvectors with phases of occupied and virtuals MOs.", &
2016 default_l_val=.false., lone_keyword_l_val=.true.)
2024 description=
"Controls the printout of the tddfpt2_soc modul", &
2027 description=
"Will detrement if output in eVolt will be printef.", &
2028 default_l_val=.true., lone_keyword_l_val=.true.)
2032 description=
"Will detrement if output in wavenumbers will be printed.", &
2033 default_l_val=.false., lone_keyword_l_val=.true.)
2037 description=
"Will add the SOC-Splitting as additional output", &
2038 default_l_val=.false., lone_keyword_l_val=.true.)
2042 description=
"Will add the SOC-Matrix as additional output in a different file", &
2043 default_l_val=.false., lone_keyword_l_val=.true.)
2050 description=
"Controls the calculation and printing of excited state forces. "// &
2051 "This needs a RUN_TYPE that includes force evaluation, e.g. ENERGY_FORCE", &
2054 description=
"Specifies a list of states for the force calculations.", &
2055 usage=
"LIST {integer} {integer} .. {integer}", repeats=.true., &
2060 description=
"Threshold for oszillator strength to screen states.", &
2061 usage=
"Threshold 0.01", &
2064 default_r_val=0.0_dp)
2073 END SUBROUTINE create_tddfpt2_section
2079 SUBROUTINE create_stda_section(section)
2084 cpassert(.NOT.
ASSOCIATED(section))
2086 description=
"parameters needed and setup for sTDA calculations", &
2087 n_keywords=3, n_subsections=0, repeats=.false.)
2091 variants=[
"HFX_FRACTION"], &
2092 description=
"The fraction of TB Hartree-Fock exchange to use in the Kernel. "// &
2093 "0.0 implies no HFX part is used in the kernel. ", &
2094 usage=
"FRACTION 0.0", default_r_val=0.0_dp)
2101 description=
"Explicitly including or switching off sTDA exchange", &
2102 usage=
"DO_EXCHANGE", default_l_val=.true., lone_keyword_l_val=.true.)
2107 description=
"Use Ewald type method for Coulomb interaction", &
2108 usage=
"DO_EWALD", default_l_val=.false., lone_keyword_l_val=.true.)
2112 CALL keyword_create(keyword, __location__, name=
"EPS_TD_FILTER", &
2113 description=
"Threshold for filtering the transition density matrix", &
2114 usage=
"EPS_TD_FILTER epsf", default_r_val=1.e-10_dp)
2118 CALL keyword_create(keyword, __location__, name=
"MATAGA_NISHIMOTO_CEXP", &
2119 description=
"Exponent used in Mataga-Nishimoto formula for Coulomb (alpha). "// &
2120 "Default value is method dependent!", &
2121 usage=
"MATAGA_NISHIMOTO_CEXP cexp", default_r_val=-99.0_dp)
2125 CALL keyword_create(keyword, __location__, name=
"MATAGA_NISHIMOTO_XEXP", &
2126 description=
"Exponent used in Mataga-Nishimoto formula for Exchange (beta). "// &
2127 "Default value is method dependent!", &
2128 usage=
"MATAGA_NISHIMOTO_XEXP xexp", default_r_val=-99.0_dp)
2132 CALL keyword_create(keyword, __location__, name=
"COULOMB_SR_CUT", &
2133 description=
"Maximum range of short range part of Coulomb interaction.", &
2134 usage=
"COULOMB_SR_CUT rcut", default_r_val=20.0_dp)
2138 CALL keyword_create(keyword, __location__, name=
"COULOMB_SR_EPS", &
2139 description=
"Threshold for short range part of Coulomb interaction.", &
2140 usage=
"COULOMB_SR_EPS sreps", default_r_val=1.e-03_dp)
2144 END SUBROUTINE create_stda_section
2150 SUBROUTINE create_res_section(section)
2155 cpassert(.NOT.
ASSOCIATED(section))
2156 CALL section_create(section, __location__, name=
"REDUCED_EXCITATION_SPACE", &
2157 description=
"Sets up a restricted (reduced) excitation space for TDDFT", &
2158 n_keywords=3, n_subsections=0, repeats=.false.)
2162 name=
"_SECTION_PARAMETERS_", &
2163 description=
"Controls the activation of RES calculation.", &
2164 default_l_val=.false., &
2165 lone_keyword_l_val=.true.)
2169 CALL keyword_create(keyword, __location__, name=
"ENERGY_WINDOW", &
2170 description=
"Upper and lower cutoffs [eV] for orbitals to be included for excitations. ", &
2171 usage=
"ENERGY_WINDOW -5.0 0.0", default_r_vals=[-1.0e10_dp, 1.0e10_dp], &
2172 type_of_var=
real_t, unit_str=
"eV")
2176 CALL keyword_create(keyword, __location__, name=
"UPPER_ENERGY_CUTOFF", &
2177 description=
"Upper energy cutoff [eV] for orbitals to be included in excitations.", &
2178 usage=
"UPPER_ENERGY_CUTOFF -5.0", default_r_val=1.0e10_dp, &
2179 type_of_var=
real_t, unit_str=
"eV")
2183 CALL keyword_create(keyword, __location__, name=
"LOWER_ENERGY_CUTOFF", &
2184 description=
"Lower energy cutoff [eV] for orbitals to be included in excitations.", &
2185 usage=
"LOWER_ENERGY_CUTOFF -5.0", default_r_val=-1.0e10_dp, &
2186 type_of_var=
real_t, unit_str=
"eV")
2190 CALL keyword_create(keyword, __location__, name=
"MOLECULE_LIST", &
2191 description=
"Indices of molecules to be excited. "// &
2192 "This implies the calculation of molecular states through orbital location "// &
2193 "and subspace diagonalization.", &
2194 usage=
"MOLECULE_LIST {integer} {integer} .. {integer} ", &
2195 n_var=-1, type_of_var=
integer_t, repeats=.false.)
2199 END SUBROUTINE create_res_section
2207 SUBROUTINE create_bandstructure_section(section)
2213 cpassert(.NOT.
ASSOCIATED(section))
2214 CALL section_create(section, __location__, name=
"BANDSTRUCTURE", &
2215 description=
"Parameters needed to set up a calculation for "// &
2216 "electronic level energies of molecules and the electronic band "// &
2217 "structure of materials from post-SCF schemes (GW, perturbative "// &
2218 "spin-orbit coupling). Also, the density of states (DOS), "// &
2219 "projected density of states (PDOS), local density of states (LDOS), "// &
2220 "local valence band maximum (LVBM), local conduction band minimum "// &
2221 "(LCBM) and local band gap can be calculated. Please note that "// &
2222 "all methods in this section start from a Gamma-only DFT SCF. "// &
2223 "You need to make sure that the cell chosen in the DFT SCF is "// &
2224 "converged in the cell size. Band structures are computed "// &
2225 "for the primitive cell (i.e. the smallest possible unit cell of "// &
2226 "the input structure which is detected automatically). Moreover, "// &
2227 "spin-orbit coupling (SOC) on eigenvalues and band structures is "// &
2228 "available using Hartwigsen-Goedecker-Hutter "// &
2229 "pseudopotentials.", &
2230 n_keywords=1, n_subsections=1, repeats=.false.)
2232 NULLIFY (keyword, subsection)
2234 name=
"_SECTION_PARAMETERS_", &
2235 description=
"Controls the activation of the band structure calculation.", &
2236 default_l_val=.false., &
2237 lone_keyword_l_val=.true.)
2246 CALL create_gw_section(subsection)
2250 CALL create_soc_section(subsection)
2254 CALL create_dos_section(subsection)
2258 END SUBROUTINE create_bandstructure_section
2266 SUBROUTINE create_gw_section(section)
2272 cpassert(.NOT.
ASSOCIATED(section))
2274 description=
"Parameters needed to set up a GW calculation for "// &
2275 "electronic level energies $\varepsilon_{n\mathbf{k}}^{G_0W_0}$ "// &
2276 "of molecules and the band structure of materials: "// &
2277 "$\varepsilon_{n\mathbf{k}}^{G_0W_0}= "// &
2278 "\varepsilon_{n\mathbf{k}}^\text{DFT}+\Sigma_{n\mathbf{k}} "// &
2279 "-v^\text{xc}_{n\mathbf{k}}$. "// &
2280 "For the GW algorithm for molecules, see "// &
2281 "<https://doi.org/10.1021/acs.jctc.0c01282>. "// &
2282 "For 2D materials, see <https://doi.org/10.1021/acs.jctc.3c01230>.", &
2283 n_keywords=1, n_subsections=1, repeats=.false.)
2287 name=
"_SECTION_PARAMETERS_", &
2288 description=
"Controls the activation of the GW calculation.", &
2289 default_l_val=.false., &
2290 lone_keyword_l_val=.true.)
2294 CALL keyword_create(keyword, __location__, name=
"NUM_TIME_FREQ_POINTS", &
2295 description=
"Number of discrete points for the imaginary-time "// &
2296 "grid and the imaginary-frequency grid. The more points, the more "// &
2297 "precise is the calculation. Typically, 10 points are good "// &
2298 "for 0.1 eV precision of band structures and molecular energy "// &
2299 "levels, 20 points for 0.03 eV precision, "// &
2300 "and 30 points for 0.01 eV precision, see Table I in "// &
2301 "<https://doi.org/10.1021/acs.jctc.0c01282>. GW computation time "// &
2302 "increases linearly with `NUM_TIME_FREQ_POINTS`.", &
2303 usage=
"NUM_TIME_FREQ_POINTS 30", &
2309 description=
"Determines a threshold for the DBCSR based sparse "// &
2310 "multiplications. Normally, `EPS_FILTER` determines accuracy "// &
2311 "and timing of low-scaling GW calculations. (Lower filter means "// &
2312 "higher numerical precision, but higher computational cost.)", &
2313 usage=
"EPS_FILTER 1.0E-6", &
2314 default_r_val=1.0e-8_dp)
2318 CALL keyword_create(keyword, __location__, name=
"REGULARIZATION_MINIMAX", &
2319 description=
"Parameter to regularize the Fourier transformation with minimax grids. "// &
2320 "In case the parameter 0.0 is chosen, no regularization is performed.", &
2321 usage=
"REGULARIZATION_MINIMAX 1.0E-4", &
2322 default_r_val=-1.0_dp)
2326 CALL keyword_create(keyword, __location__, name=
"REGULARIZATION_RI", &
2327 description=
"Parameter for RI regularization, setting a negative "// &
2328 "value triggers the default value. Affects RI basis set convergence "// &
2329 "but in any case large RI basis will give RI basis set convergence.", &
2330 usage=
"REGULARIZATION_RI 1.0E-4", &
2331 default_r_val=-1.0_dp)
2335 CALL keyword_create(keyword, __location__, name=
"CUTOFF_RADIUS_RI", &
2336 description=
"The cutoff radius (in Angstrom) for the truncated "// &
2337 "Coulomb operator. The larger the cutoff radius, the faster "// &
2338 "converges the resolution of the identity (RI) with respect to the "// &
2339 "RI basis set size. Larger cutoff radius means higher computational "// &
2341 usage=
"CUTOFF_RADIUS_RI 3.0", &
2343 type_of_var=
real_t, unit_str=
"angstrom")
2347 CALL keyword_create(keyword, __location__, name=
"MEMORY_PER_PROC", &
2348 description=
"Specify the available memory per MPI process. Set "// &
2349 "`MEMORY_PER_PROC` as accurately as possible for good performance. If "// &
2350 "`MEMORY_PER_PROC` is set lower as the actually available "// &
2351 "memory per MPI process, the performance will be "// &
2352 "bad; if `MEMORY_PER_PROC` is set higher as the actually "// &
2353 "available memory per MPI process, the program might run out of "// &
2354 "memory. You can calculate `MEMORY_PER_PROC` as follows: "// &
2355 "Get the memory per node on your machine, mem_per_node "// &
2356 "(for example, from a supercomputer website, typically between "// &
2357 "100 GB and 2 TB), get the number of "// &
2358 "MPI processes per node, n_MPI_proc_per_node"// &
2359 " (for example from your run-script; if you "// &
2360 "use slurm, the number behind '--ntasks-per-node' is the number "// &
2361 "of MPI processes per node). Then calculate "// &
2362 "`MEMORY_PER_PROC` = mem_per_node / n_MPI_proc_per_node "// &
2363 "(typically between 2 GB and 50 GB). Unit of keyword: Gigabyte (GB).", &
2364 usage=
"MEMORY_PER_PROC 16", &
2365 default_r_val=2.0_dp)
2369 CALL keyword_create(keyword, __location__, name=
"APPROX_KP_EXTRAPOL", &
2370 description=
"If true, use only a 4x4 kpoint mesh for frequency "// &
2371 "points $\omega_j, j \ge 2$ (instead of a 4x4 and 6x6 k-point mesh). "// &
2372 "The k-point extrapolation of $W_{PQ}(i\omega_j,\mathbf{q})$ "// &
2373 "is done approximately from $W_{PQ}(i\omega_1,\mathbf{q})$.", &
2374 usage=
"APPROX_KP_EXTRAPOL", &
2375 default_l_val=.false., lone_keyword_l_val=.true.)
2379 CALL keyword_create(keyword, __location__, name=
"SIZE_LATTICE_SUM", &
2380 description=
"Parameter determines how many neighbor cells $\mathbf{R}$ "// &
2381 "are used for computing "// &
2382 "$V_{PQ}(\mathbf{k}) = "// &
2383 "\sum_{\mathbf{R}} e^{i\mathbf{k}\cdot\mathbf{R}}\,\langle P, "// &
2384 "\text{cell}{=}\mathbf{0}|1/r|Q,\text{cell}{=}\mathbf{R}\rangle$. "// &
2385 "Normally, parameter does not need to be touched.", &
2386 usage=
"SIZE_LATTICE_SUM 4", &
2392 keyword, __location__, name=
"KPOINTS_W", &
2393 description=
"Monkhorst-Pack k-point mesh of size N_x, N_y, N_z for calculating "// &
2394 "$W_{PQ}^\mathbf{R}=\int_\text{BZ}\frac{d\mathbf{k}}{\Omega_\text{BZ}}\, "// &
2395 "e^{-i\mathbf{k}\cdot\mathbf{R}}\,W_{PQ}(\mathbf{k})$. "// &
2396 αα
"For non-periodic directions , choose N_ = 1. "// &
2397 "Automatic choice of the k-point mesh for negative "// &
2398 "values, i.e. KPOINTS_W -1 -1 -1. "// &
2399 "K-point extrapolation of W is automatically switched on.", &
2400 usage=
"KPOINTS_W N_x N_y N_z", &
2401 n_var=3, type_of_var=
integer_t, default_i_vals=[-1, -1, -1])
2406 description=
"If true, use Hedin's shift in G0W0, evGW and evGW0. "// &
2407 "Details see in Li et al. JCTC 18, 7570 "// &
2408 "(2022), Figure 1. G0W0 with Hedin's shift should give "// &
2409 "similar GW eigenvalues as evGW0; at a lower "// &
2410 "computational cost.", &
2411 usage=
"HEDIN_SHIFT", &
2412 default_l_val=.false., &
2413 lone_keyword_l_val=.true.)
2417 CALL keyword_create(keyword, __location__, name=
"FREQ_MAX_FIT", &
2418 description=Σω
"For analytic continuation, a fit on (i) is performed. "// &
2419 Σω
"This fit is then evaluated at a real frequency, (), which is used "// &
2420 "in the quasiparticle equation "// &
2421 "$\varepsilon_{n\mathbf{k}}^{G_0W_0}= "// &
2422 "\varepsilon_{n\mathbf{k}}^\text{DFT}+\Sigma_{n\mathbf{k}} "// &
2423 "-v^\text{xc}_{n\mathbf{k}}$. The keyword FREQ_MAX_FIT "// &
2424 Σω
"determines fitting range for the self-energy (i) on "// &
2425 ωω
"imaginary axis: i*[0, _max] for empty orbitals/bands, i*[-_max,0] "// &
2426 ω
"for occ orbitals. A smaller _max might lead to better numerical "// &
2427 "stability (i.e., if you observe clearly wrong GW eigenvalues/bands "// &
2428 ω
"around HOMO/LUMO, decreasing _max might fix this issue). "// &
2429 ω
"A small benchmark of _max is contained in Fig. 5 of "// &
2430 "J. Wilhelm et al., JCTC 12, 3623-3635 (2016). "// &
2431 ω
"Note that we used _max = 1 Ha = 27.211 eV in the benchmark "// &
2432 "M. Azizi et al., PRB 109, 245101 (2024).", &
2434 usage=
"FREQ_MAX_FIT 20.0", &
2439 NULLIFY (subsection, print_key)
2441 description=
"Printing of GW restarts.", &
2442 n_keywords=2, n_subsections=1, repeats=.false.)
2444 description=
"Controls the printing of restart files "// &
2447 common_iter_levels=3)
2451 CALL keyword_create(keyword, __location__, name=
"PRINT_DBT_CONTRACT", &
2452 description=
"Prints information of contraction routines.", &
2453 usage=
"PRINT_DBT_CONTRACT", &
2454 default_l_val=.false., &
2455 lone_keyword_l_val=.true.)
2459 CALL keyword_create(keyword, __location__, name=
"PRINT_DBT_CONTRACT_VERBOSE", &
2460 description=
"Prints verbose information of contraction routines.", &
2461 usage=
"PRINT_DBT_CONTRACT_VERBOSE", &
2462 default_l_val=.false., &
2463 lone_keyword_l_val=.true.)
2470 END SUBROUTINE create_gw_section
2478 SUBROUTINE create_soc_section(section)
2483 cpassert(.NOT.
ASSOCIATED(section))
2485 description=
"Switch on or off spin-orbit coupling. Use SOC "// &
2486 "parameters from non-local pseudopotentials as given in "// &
2487 "Hartwigsen, Goedecker, Hutter, Eq.(18), (19), "// &
2488 "<https://doi.org/10.1103/PhysRevB.58.3641>, "// &
2489 "$V_{\mu\nu}^{\mathrm{SOC}, (\alpha)} = "// &
2490 "(\hbar/2) \langle \phi_\mu | \sum_l \Delta "// &
2491 "V_l^\mathrm{SO}(\mathbf{r},\mathbf{r}') "// &
2492 "L^{(\alpha)} | \phi_\nu \rangle, "// &
2493 "\alpha = x, y, z$.", &
2494 n_keywords=1, n_subsections=1, repeats=.false.)
2498 name=
"_SECTION_PARAMETERS_", &
2499 description=
"Controls the activation of the SOC calculation.", &
2500 default_l_val=.false., &
2501 lone_keyword_l_val=.true.)
2505 CALL keyword_create(keyword, __location__, name=
"ENERGY_WINDOW", &
2506 description=
"Apply SOC only for states with eigenvalues in the "// &
2507 "interval $[\varepsilon_\mathrm{VBM}-E_\mathrm{window}/2, "// &
2508 "\varepsilon_\mathrm{CBM}+E_\mathrm{window}/2]$. Might be necessary "// &
2509 "to use for large systems to prevent numerical instabilities.", &
2510 usage=
"ENERGY_WINDOW 5.0", &
2516 END SUBROUTINE create_soc_section
2524 SUBROUTINE create_dos_section(section)
2530 cpassert(.NOT.
ASSOCIATED(section))
2532 description=
"Parameters needed to calculate the density of states "// &
2533 "(DOS) and the projected density of states (PDOS).", &
2534 n_keywords=1, n_subsections=1, repeats=.false.)
2538 name=
"_SECTION_PARAMETERS_", &
2539 description=
"Controls the activation of the DOS calculation.", &
2540 default_l_val=.false., &
2541 lone_keyword_l_val=.true.)
2545 CALL keyword_create(keyword, __location__, name=
"ENERGY_WINDOW", &
2546 description=
"Print DOS and PDOS in the energy window "// &
2547 "$[\varepsilon_\mathrm{VBM}-E_\mathrm{window}/2, "// &
2548 "\varepsilon_\mathrm{CBM}+E_\mathrm{window}/2]$,"// &
2549 " where VBM is the valence "// &
2550 "band maximum (or highest occupied molecular orbital, HOMO, for "// &
2551 "molecules) and CBM the conduction band minimum (or lowest "// &
2552 "unoccupied molecular orbital, LUMO, for molecules).", &
2553 usage=
"ENERGY_WINDOW 5.0", &
2560 description=
"Resolution of the energy E when computing the $\rho(E)$.", &
2561 usage=
"ENERGY_STEP 0.01", &
2568 description=α
"Broadening in Gaussians used in the DOS; "// &
2569 "$\rho(E) = \sum_n \exp(((E-\varepsilon_n)/\alpha)^2)/("// &
2570 " \sqrt{2\pi} \alpha)$.", &
2571 usage=
"BROADENING 0.01", &
2578 keyword, __location__, name=
"KPOINTS", &
2579 description=
"Monkhorst-Pack k-point mesh of size N_x, N_y, N_z for calculating "// &
2580 "the density of states (DOS). In GW, the KPOINT_DOS mesh is thus used as k-point "// &
2581 αα
"mesh for the self-energy. For non-periodic directions , choose N_ = 1. "// &
2582 "Automatic choice of the k-point mesh for negative "// &
2583 α
"values, i.e. KPOINTS_DOS -1 -1 -1 (automatic choice: N_ = 1 in non-periodic "// &
2584 "direction, 8 k-points in periodic direction). If you like to compute a "// &
2585 "band structure along a k-path, you can specify the k-path in "// &
2587 usage=
"KPOINTS N_x N_y N_z", &
2588 n_var=3, type_of_var=
integer_t, default_i_vals=[-1, -1, -1])
2592 NULLIFY (subsection)
2593 CALL create_ldos_section(subsection)
2597 END SUBROUTINE create_dos_section
2603 SUBROUTINE create_ldos_section(section)
2608 cpassert(.NOT.
ASSOCIATED(section))
2610 description=
"Parameters needed to calculate the local density "// &
2611 "of states (LDOS). "// &
2612 "The LDOS is computed as $\rho(\mathbf{r},E) = "// &
2613 "\sum\limits_{n,\mathbf{k}}"// &
2614 " |\psi_{n\mathbf{k}}(r)|^2\, w_\mathbf{k}\, g(E-\varepsilon_{n\mathbf{k}})$ "// &
2615 "using the Gaussian weight function "// &
2616 "$g(x) = \exp(x^2/\alpha^2)/(\sqrt{2\pi}\alpha)$, $\alpha$ is the broadening "// &
2617 "from the &DOS section, and the k-point weight "// &
2618 "$w_\mathbf{k}$. The k-mesh is taken from the &DOS section.", &
2619 n_keywords=2, repeats=.false.)
2623 name=
"_SECTION_PARAMETERS_", &
2624 description=
"Activates the local VBM CBM gap calculation.", &
2625 default_l_val=.false., &
2626 lone_keyword_l_val=.true.)
2631 description=
"Defines whether the LDOS is integrated along a "// &
2632 "coordinate. As an example, for INTEGRATION Z, the LDOS "// &
2633 "$\rho(x,y,E) = \int dz\, \rho(x,y,z,E)$ is computed.", &
2634 usage=
"INTEGRATION Z", &
2635 enum_c_vals=
s2a(
"X",
"Y",
"Z",
"NONE"), &
2637 enum_desc=
s2a(
"Integrate over x coordinate (not yet implemented).", &
2638 "Integrate over y coordinate (not yet implemented).", &
2639 "Integrate over z coordinate.", &
2640 "No integration, print cube file as function "// &
2641 "of x,y,z (not yet implemented)."), &
2647 keyword, __location__, name=
"BIN_MESH", &
2648 description=
"Mesh of size n x m for binning the space coordinates x and y of "// &
2649 "the LDOS $\rho(x,y,E)$. If -1, no binning is performed and the "// &
2650 "fine x, y resolution of the electron density from SCF is used.", &
2651 usage=
"BIN_MESH n m", &
2652 n_var=2, type_of_var=
integer_t, default_i_vals=[10, 10])
2656 END SUBROUTINE create_ldos_section
2664 SUBROUTINE create_tipscan_section(section)
2669 cpassert(.NOT.
ASSOCIATED(section))
2671 description=
"Parameters needed to set up a Tip Scan. "// &
2672 "Needs external definition of tip induced field.", &
2673 n_keywords=1, n_subsections=1, repeats=.false.)
2678 name=
"_SECTION_PARAMETERS_", &
2679 description=
"Controls the activation of the Tip Scan procedure", &
2680 default_l_val=.false., &
2681 lone_keyword_l_val=.true.)
2685 CALL keyword_create(keyword, __location__, name=
"SCAN_DIRECTION", &
2686 description=
"Defines scan direction and scan type(line, plane).", &
2687 usage=
"SCAN_DIRECTION XY", &
2688 enum_c_vals=
s2a(
"X",
"Y",
"Z",
"XY",
"XZ",
"YZ",
"XYZ"), &
2694 CALL keyword_create(keyword, __location__, name=
"REFERENCE_POINT", &
2695 description=
"The reference point to define the absolute position of the scan. ", &
2696 usage=
"REFERENCE_POINT 0.0 0.0 1.0", &
2697 n_var=3, default_r_vals=[0.0_dp, 0.0_dp, 0.0_dp], type_of_var=
real_t, &
2698 unit_str=
"angstrom")
2703 description=
"Number of points calculated for each scan direction.", &
2704 usage=
"SCAN_POINTS 20 20", &
2710 description=
"Step size for each scan direction.", &
2711 usage=
"SCAN_STEP 0.01 0.01", &
2712 n_var=-1, type_of_var=
real_t, unit_str=
"angstrom")
2716 CALL keyword_create(keyword, __location__, name=
"TIP_FILENAME", &
2717 description=
"Filename of tip potential defined in cube file format.", &
2718 usage=
"TIP_FILENAME <filename>", &
2723 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 hanasaki2025
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.