Line data Source code
1 : !--------------------------------------------------------------------------------------------------!
2 : ! CP2K: A general program to perform molecular dynamics simulations !
3 : ! Copyright 2000-2024 CP2K developers group <https://cp2k.org> !
4 : ! !
5 : ! SPDX-License-Identifier: GPL-2.0-or-later !
6 : !--------------------------------------------------------------------------------------------------!
7 :
8 : ! **************************************************************************************************
9 : !> \brief creates the mm section of the input
10 : !> \note
11 : !> moved out of input_cp2k
12 : !> \par History
13 : !> 04.2004 created
14 : !> \author fawzi
15 : ! **************************************************************************************************
16 : MODULE input_cp2k_mm
17 : USE bibliography, ONLY: &
18 : Batzner2022, Clabaut2020, Clabaut2021, Devynck2012, Dick1958, Foiles1986, Mitchell1993, &
19 : Musaelian2023, QUIP_ref, Siepmann1995, Tersoff1988, Tosi1964a, Tosi1964b, Wang2018, &
20 : Yamada2000, Zeng2023
21 : USE cp_output_handling, ONLY: cp_print_key_section_create,&
22 : debug_print_level,&
23 : high_print_level,&
24 : low_print_level,&
25 : medium_print_level,&
26 : silent_print_level
27 : USE cp_units, ONLY: cp_unit_to_cp2k
28 : USE force_field_kind_types, ONLY: &
29 : do_ff_amber, do_ff_charmm, do_ff_cubic, do_ff_fues, do_ff_g87, do_ff_g96, do_ff_harmonic, &
30 : do_ff_legendre, do_ff_mixed_bend_stretch, do_ff_mm2, do_ff_mm3, do_ff_mm4, do_ff_morse, &
31 : do_ff_opls, do_ff_quartic, do_ff_undef
32 : USE input_constants, ONLY: use_mom_ref_coac,&
33 : use_mom_ref_com,&
34 : use_mom_ref_user,&
35 : use_mom_ref_zero
36 : USE input_cp2k_field, ONLY: create_per_efield_section
37 : USE input_cp2k_poisson, ONLY: create_poisson_section
38 : USE input_keyword_types, ONLY: keyword_create,&
39 : keyword_release,&
40 : keyword_type
41 : USE input_section_types, ONLY: section_add_keyword,&
42 : section_add_subsection,&
43 : section_create,&
44 : section_release,&
45 : section_type
46 : USE input_val_types, ONLY: char_t,&
47 : integer_t,&
48 : lchar_t,&
49 : real_t
50 : USE kinds, ONLY: default_string_length,&
51 : dp
52 : USE string_utilities, ONLY: newline,&
53 : s2a
54 : #include "./base/base_uses.f90"
55 :
56 : IMPLICIT NONE
57 : PRIVATE
58 :
59 : LOGICAL, PRIVATE, PARAMETER :: debug_this_module = .TRUE.
60 : CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'input_cp2k_mm'
61 :
62 : PUBLIC :: create_mm_section, create_dipoles_section
63 : PUBLIC :: create_NONBONDED14_section, create_LJ_section, create_Williams_section, &
64 : create_Goodwin_section, &
65 : create_GENPOT_section, create_TABPOT_section, create_neighbor_lists_section
66 : PUBLIC :: create_CHARGE_section
67 : !***
68 : CONTAINS
69 :
70 : ! **************************************************************************************************
71 : !> \brief Create the input section for FIST.. Come on.. Let's get woohooo
72 : !> \param section the section to create
73 : !> \author teo
74 : ! **************************************************************************************************
75 8392 : SUBROUTINE create_mm_section(section)
76 : TYPE(section_type), POINTER :: section
77 :
78 : TYPE(section_type), POINTER :: subsection
79 :
80 8392 : CPASSERT(.NOT. ASSOCIATED(section))
81 : CALL section_create(section, __LOCATION__, name="mm", &
82 : description="This section contains all information to run a MM calculation.", &
83 8392 : n_keywords=5, n_subsections=0, repeats=.FALSE.)
84 :
85 8392 : NULLIFY (subsection)
86 :
87 8392 : CALL create_forcefield_section(subsection)
88 8392 : CALL section_add_subsection(section, subsection)
89 8392 : CALL section_release(subsection)
90 :
91 8392 : CALL create_neighbor_lists_section(subsection)
92 8392 : CALL section_add_subsection(section, subsection)
93 8392 : CALL section_release(subsection)
94 :
95 8392 : CALL create_poisson_section(subsection)
96 8392 : CALL section_add_subsection(section, subsection)
97 8392 : CALL section_release(subsection)
98 :
99 8392 : CALL create_per_efield_section(subsection)
100 8392 : CALL section_add_subsection(section, subsection)
101 8392 : CALL section_release(subsection)
102 :
103 8392 : CALL create_print_mm_section(subsection)
104 8392 : CALL section_add_subsection(section, subsection)
105 8392 : CALL section_release(subsection)
106 :
107 8392 : END SUBROUTINE create_mm_section
108 :
109 : ! **************************************************************************************************
110 : !> \brief Create the print mm section
111 : !> \param section the section to create
112 : !> \author teo
113 : ! **************************************************************************************************
114 8392 : SUBROUTINE create_print_mm_section(section)
115 : TYPE(section_type), POINTER :: section
116 :
117 : TYPE(keyword_type), POINTER :: keyword
118 : TYPE(section_type), POINTER :: print_key
119 :
120 8392 : CPASSERT(.NOT. ASSOCIATED(section))
121 : CALL section_create(section, __LOCATION__, name="print", &
122 : description="Section of possible print options in MM code.", &
123 8392 : n_keywords=0, n_subsections=1, repeats=.FALSE.)
124 :
125 8392 : NULLIFY (print_key, keyword)
126 :
127 : CALL cp_print_key_section_create(print_key, __LOCATION__, "DERIVATIVES", &
128 : description="Controls the printing of derivatives.", &
129 8392 : print_level=high_print_level, filename="__STD_OUT__")
130 8392 : CALL section_add_subsection(section, print_key)
131 8392 : CALL section_release(print_key)
132 :
133 : CALL cp_print_key_section_create(print_key, __LOCATION__, "EWALD_INFO", &
134 : description="Controls the printing of Ewald energy components during the "// &
135 : "evaluation of the electrostatics.", &
136 8392 : print_level=high_print_level, filename="__STD_OUT__")
137 8392 : CALL section_add_subsection(section, print_key)
138 8392 : CALL section_release(print_key)
139 :
140 8392 : CALL create_dipoles_section(print_key, "DIPOLE", medium_print_level)
141 8392 : CALL section_add_subsection(section, print_key)
142 8392 : CALL section_release(print_key)
143 :
144 : CALL cp_print_key_section_create(print_key, __LOCATION__, "NEIGHBOR_LISTS", &
145 : description="Activates the printing of the neighbor lists.", &
146 8392 : print_level=high_print_level, filename="", unit_str="angstrom")
147 8392 : CALL section_add_subsection(section, print_key)
148 8392 : CALL section_release(print_key)
149 :
150 : CALL cp_print_key_section_create(print_key, __LOCATION__, "ITER_INFO", &
151 : description="Activates the printing of iteration info during the self-consistent "// &
152 : "calculation of a polarizable forcefield.", &
153 8392 : print_level=medium_print_level, filename="__STD_OUT__")
154 8392 : CALL section_add_subsection(section, print_key)
155 8392 : CALL section_release(print_key)
156 :
157 : CALL cp_print_key_section_create(print_key, __LOCATION__, "SUBCELL", &
158 : description="Activates the printing of the subcells used for the "// &
159 : "generation of neighbor lists.", &
160 8392 : print_level=high_print_level, filename="__STD_OUT__")
161 8392 : CALL section_add_subsection(section, print_key)
162 8392 : CALL section_release(print_key)
163 :
164 : CALL cp_print_key_section_create(print_key, __LOCATION__, "PROGRAM_BANNER", &
165 : description="Controls the printing of the banner of the MM program", &
166 8392 : print_level=silent_print_level, filename="__STD_OUT__")
167 8392 : CALL section_add_subsection(section, print_key)
168 8392 : CALL section_release(print_key)
169 :
170 : CALL cp_print_key_section_create(print_key, __LOCATION__, "PROGRAM_RUN_INFO", &
171 : description="Controls the printing of information regarding the run.", &
172 8392 : print_level=low_print_level, filename="__STD_OUT__")
173 8392 : CALL section_add_subsection(section, print_key)
174 8392 : CALL section_release(print_key)
175 :
176 : CALL cp_print_key_section_create(print_key, __LOCATION__, "FF_PARAMETER_FILE", description= &
177 : "Controls the printing of Force Field parameter file", &
178 8392 : print_level=debug_print_level + 1, filename="", common_iter_levels=2)
179 8392 : CALL section_add_subsection(section, print_key)
180 8392 : CALL section_release(print_key)
181 :
182 : CALL cp_print_key_section_create(print_key, __LOCATION__, "FF_INFO", description= &
183 : "Controls the printing of information in the forcefield settings", &
184 8392 : print_level=high_print_level, filename="__STD_OUT__")
185 :
186 : CALL keyword_create(keyword, __LOCATION__, name="spline_info", &
187 : description="if the printkey is active prints information regarding the splines"// &
188 : " used in the nonbonded interactions", &
189 8392 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
190 8392 : CALL section_add_keyword(print_key, keyword)
191 8392 : CALL keyword_release(keyword)
192 :
193 : CALL keyword_create(keyword, __LOCATION__, name="spline_data", &
194 : description="if the printkey is active prints on separated files the splined function"// &
195 : " together with the reference one. Useful to check the spline behavior.", &
196 8392 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
197 8392 : CALL section_add_keyword(print_key, keyword)
198 8392 : CALL keyword_release(keyword)
199 :
200 8392 : CALL section_add_subsection(section, print_key)
201 8392 : CALL section_release(print_key)
202 :
203 8392 : END SUBROUTINE create_print_mm_section
204 :
205 : ! **************************************************************************************************
206 : !> \brief Create the forcefield section. This section is useful to set up the
207 : !> proper force_field for FIST calculations
208 : !> \param section the section to create
209 : !> \author teo
210 : ! **************************************************************************************************
211 8392 : SUBROUTINE create_forcefield_section(section)
212 : TYPE(section_type), POINTER :: section
213 :
214 : TYPE(keyword_type), POINTER :: keyword
215 : TYPE(section_type), POINTER :: subsection
216 :
217 8392 : CPASSERT(.NOT. ASSOCIATED(section))
218 : CALL section_create(section, __LOCATION__, name="FORCEFIELD", &
219 : description="Section specifying information regarding how to set up properly"// &
220 : " a force_field for the classical calculations.", &
221 8392 : n_keywords=2, n_subsections=2, repeats=.FALSE.)
222 :
223 8392 : NULLIFY (subsection, keyword)
224 :
225 : CALL keyword_create( &
226 : keyword, __LOCATION__, name="PARMTYPE", &
227 : description="Define the kind of torsion potential", &
228 : usage="PARMTYPE {OFF,CHM,G87,G96}", &
229 : enum_c_vals=s2a("OFF", "CHM", "G87", "G96", "AMBER"), &
230 : enum_desc=s2a("Provides force field parameters through the input file", &
231 : "Provides force field parameters through an external file with CHARMM format", &
232 : "Provides force field parameters through an external file with GROMOS 87 format", &
233 : "Provides force field parameters through an external file with GROMOS 96 format", &
234 : "Provides force field parameters through an external file with AMBER format (from v.8 on)"), &
235 : enum_i_vals=(/do_ff_undef, &
236 : do_ff_charmm, &
237 : do_ff_g87, &
238 : do_ff_g96, &
239 : do_ff_amber/), &
240 8392 : default_i_val=do_ff_undef)
241 8392 : CALL section_add_keyword(section, keyword)
242 8392 : CALL keyword_release(keyword)
243 :
244 : CALL keyword_create(keyword, __LOCATION__, name="PARM_FILE_NAME", &
245 : description="Specifies the filename that contains the parameters of the FF.", &
246 8392 : usage="PARM_FILE_NAME {FILENAME}", type_of_var=lchar_t)
247 8392 : CALL section_add_keyword(section, keyword)
248 8392 : CALL keyword_release(keyword)
249 :
250 : CALL keyword_create(keyword, __LOCATION__, name="VDW_SCALE14", &
251 : description="Scaling factor for the VDW 1-4 ", &
252 8392 : usage="VDW_SCALE14 1.0", default_r_val=1.0_dp)
253 8392 : CALL section_add_keyword(section, keyword)
254 8392 : CALL keyword_release(keyword)
255 :
256 : CALL keyword_create(keyword, __LOCATION__, name="EI_SCALE14", &
257 : description="Scaling factor for the electrostatics 1-4 ", &
258 8392 : usage="EI_SCALE14 1.0", default_r_val=0.0_dp)
259 8392 : CALL section_add_keyword(section, keyword)
260 8392 : CALL keyword_release(keyword)
261 :
262 : CALL keyword_create(keyword, __LOCATION__, name="SHIFT_CUTOFF", &
263 : description="Add a constant energy shift to the real-space "// &
264 : "non-bonding interactions (both Van der Waals and "// &
265 : "electrostatic) such that the energy at the cutoff radius is "// &
266 : "zero. This makes the non-bonding interactions continuous at "// &
267 : "the cutoff.", &
268 8392 : usage="SHIFT_CUTOFF <LOGICAL>", default_l_val=.TRUE.)
269 8392 : CALL section_add_keyword(section, keyword)
270 8392 : CALL keyword_release(keyword)
271 :
272 : CALL keyword_create(keyword, __LOCATION__, name="DO_NONBONDED", &
273 : description="Controls the computation of all the real-space "// &
274 : "(short-range) nonbonded interactions. This also "// &
275 : "includes the real-space corrections for excluded "// &
276 : "or scaled 1-2, 1-3 and 1-4 interactions. When set "// &
277 : "to F, the neighborlists are not created and all "// &
278 : "interactions that depend on them are not computed.", &
279 8392 : usage="DO_NONBONDED T", default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
280 8392 : CALL section_add_keyword(section, keyword)
281 8392 : CALL keyword_release(keyword)
282 :
283 : CALL keyword_create(keyword, __LOCATION__, name="DO_ELECTROSTATICS", &
284 : description="Controls the computation of all the real-space "// &
285 : "(short-range) electrostatics interactions. This does not "// &
286 : "affect the QM/MM electrostatic coupling when turned off.", &
287 8392 : usage="DO_ELECTROSTATICS T", default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
288 8392 : CALL section_add_keyword(section, keyword)
289 8392 : CALL keyword_release(keyword)
290 :
291 : CALL keyword_create(keyword, __LOCATION__, name="IGNORE_MISSING_CRITICAL_PARAMS", &
292 : description="Do not abort when critical force-field parameters "// &
293 : "are missing. CP2K will run as if the terms containing the "// &
294 : "missing parameters are zero.", &
295 : usage="IGNORE_MISSING_BOND_PARAMS T", default_l_val=.FALSE., &
296 8392 : lone_keyword_l_val=.TRUE.)
297 8392 : CALL section_add_keyword(section, keyword)
298 8392 : CALL keyword_release(keyword)
299 :
300 : CALL keyword_create(keyword, __LOCATION__, name="MULTIPLE_POTENTIAL", &
301 : description="Enables the possibility to define NONBONDED and NONBONDED14 as a"// &
302 : " sum of different kinds of potential. Useful for piecewise defined potentials.", &
303 8392 : usage="MULTIPLE_POTENTIAL T", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
304 8392 : CALL section_add_keyword(section, keyword)
305 8392 : CALL keyword_release(keyword)
306 : !Universal scattering potential at very short distances
307 : CALL keyword_create(keyword, __LOCATION__, name="ZBL_SCATTERING", &
308 : description="A short range repulsive potential is added, to simulate "// &
309 : "collisions and scattering.", &
310 8392 : usage="ZBL_SCATTERING T", default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
311 8392 : CALL section_add_keyword(section, keyword)
312 8392 : CALL keyword_release(keyword)
313 :
314 : !
315 : ! subsections
316 : !
317 8392 : CALL create_SPLINE_section(subsection)
318 8392 : CALL section_add_subsection(section, subsection)
319 8392 : CALL section_release(subsection)
320 :
321 8392 : CALL create_NONBONDED_section(subsection)
322 8392 : CALL section_add_subsection(section, subsection)
323 8392 : CALL section_release(subsection)
324 :
325 8392 : CALL create_NONBONDED14_section(subsection)
326 8392 : CALL section_add_subsection(section, subsection)
327 8392 : CALL section_release(subsection)
328 :
329 8392 : CALL create_CHARGE_section(subsection)
330 8392 : CALL section_add_subsection(section, subsection)
331 8392 : CALL section_release(subsection)
332 :
333 8392 : CALL create_CHARGES_section(subsection)
334 8392 : CALL section_add_subsection(section, subsection)
335 8392 : CALL section_release(subsection)
336 :
337 8392 : CALL create_SHELL_section(subsection)
338 8392 : CALL section_add_subsection(section, subsection)
339 8392 : CALL section_release(subsection)
340 :
341 8392 : CALL create_BOND_section(subsection, "BOND")
342 8392 : CALL section_add_subsection(section, subsection)
343 8392 : CALL section_release(subsection)
344 :
345 8392 : CALL create_BEND_section(subsection)
346 8392 : CALL section_add_subsection(section, subsection)
347 8392 : CALL section_release(subsection)
348 :
349 8392 : CALL create_TORSION_section(subsection)
350 8392 : CALL section_add_subsection(section, subsection)
351 8392 : CALL section_release(subsection)
352 :
353 8392 : CALL create_IMPROPER_section(subsection)
354 8392 : CALL section_add_subsection(section, subsection)
355 8392 : CALL section_release(subsection)
356 :
357 8392 : CALL create_OPBEND_section(subsection)
358 8392 : CALL section_add_subsection(section, subsection)
359 8392 : CALL section_release(subsection)
360 :
361 8392 : CALL create_DIPOLE_section(subsection)
362 8392 : CALL section_add_subsection(section, subsection)
363 8392 : CALL section_release(subsection)
364 :
365 8392 : CALL create_QUADRUPOLE_section(subsection)
366 8392 : CALL section_add_subsection(section, subsection)
367 8392 : CALL section_release(subsection)
368 :
369 8392 : END SUBROUTINE create_forcefield_section
370 :
371 : ! **************************************************************************************************
372 : !> \brief This section specifies the parameters for the splines
373 : !> \param section the section to create
374 : !> \author teo
375 : ! **************************************************************************************************
376 8392 : SUBROUTINE create_SPLINE_section(section)
377 : TYPE(section_type), POINTER :: section
378 :
379 : TYPE(keyword_type), POINTER :: keyword
380 :
381 8392 : CPASSERT(.NOT. ASSOCIATED(section))
382 : CALL section_create(section, __LOCATION__, name="SPLINE", &
383 : description="specifies parameters to set up the splines used in the"// &
384 : " nonboned interactions (both pair body potential and many body potential)", &
385 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
386 :
387 8392 : NULLIFY (keyword)
388 :
389 : CALL keyword_create(keyword, __LOCATION__, name="R0_NB", &
390 : description="Specify the minimum value of the distance interval "// &
391 : "that brackets the value of emax_spline.", &
392 : usage="R0_NB <REAL>", default_r_val=cp_unit_to_cp2k(value=0.9_dp, &
393 : unit_str="bohr"), &
394 8392 : unit_str="angstrom")
395 8392 : CALL section_add_keyword(section, keyword)
396 8392 : CALL keyword_release(keyword)
397 :
398 : CALL keyword_create(keyword, __LOCATION__, name="RCUT_NB", &
399 : description="Cutoff radius for nonbonded interactions. This value overrides"// &
400 : " the value specified in the potential definition and is global for all potentials.", &
401 : usage="RCUT_NB {real}", default_r_val=cp_unit_to_cp2k(value=-1.0_dp, &
402 : unit_str="angstrom"), &
403 8392 : unit_str="angstrom")
404 8392 : CALL section_add_keyword(section, keyword)
405 8392 : CALL keyword_release(keyword)
406 :
407 : CALL keyword_create(keyword, __LOCATION__, name="EMAX_SPLINE", &
408 : description="Specify the maximum value of the potential up to which"// &
409 : " splines will be constructed", &
410 : usage="EMAX_SPLINE <REAL>", &
411 8392 : default_r_val=0.5_dp, unit_str="hartree")
412 8392 : CALL section_add_keyword(section, keyword)
413 8392 : CALL keyword_release(keyword)
414 :
415 : CALL keyword_create(keyword, __LOCATION__, name="EMAX_ACCURACY", &
416 : description="Specify the maximum value of energy used to check the accuracy"// &
417 : " requested through EPS_SPLINE. Energy values larger than EMAX_ACCURACY"// &
418 : " generally do not satisfy the requested accuracy", &
419 8392 : usage="EMAX_ACCURACY <REAL>", default_r_val=0.02_dp, unit_str="hartree")
420 8392 : CALL section_add_keyword(section, keyword)
421 8392 : CALL keyword_release(keyword)
422 :
423 : CALL keyword_create(keyword, __LOCATION__, name="EPS_SPLINE", &
424 : description="Specify the threshold for the choice of the number of"// &
425 : " points used in the splines (comparing the splined value with the"// &
426 : " analytically evaluated one)", &
427 8392 : usage="EPS_SPLINE <REAL>", default_r_val=1.0E-7_dp, unit_str="hartree")
428 8392 : CALL section_add_keyword(section, keyword)
429 8392 : CALL keyword_release(keyword)
430 :
431 : CALL keyword_create( &
432 : keyword, __LOCATION__, name="NPOINTS", &
433 : description="Override the default search for an accurate spline by specifying a fixed number of spline points.", &
434 8392 : usage="NPOINTS 1024", default_i_val=-1)
435 8392 : CALL section_add_keyword(section, keyword)
436 8392 : CALL keyword_release(keyword)
437 :
438 : CALL keyword_create(keyword, __LOCATION__, name="UNIQUE_SPLINE", &
439 : description="For few potentials (Lennard-Jones) one global optimal spline is generated instead"// &
440 : " of different optimal splines for each kind of potential", &
441 8392 : usage="UNIQUE_SPLINE <LOGICAL>", lone_keyword_l_val=.TRUE., default_l_val=.FALSE.)
442 8392 : CALL section_add_keyword(section, keyword)
443 8392 : CALL keyword_release(keyword)
444 :
445 8392 : END SUBROUTINE create_SPLINE_section
446 :
447 : ! **************************************************************************************************
448 : !> \brief This section specifies the torsion of the MM atoms
449 : !> \param section the section to create
450 : !> \author teo
451 : ! **************************************************************************************************
452 8392 : SUBROUTINE create_TORSION_section(section)
453 : TYPE(section_type), POINTER :: section
454 :
455 : TYPE(keyword_type), POINTER :: keyword
456 :
457 8392 : CPASSERT(.NOT. ASSOCIATED(section))
458 : CALL section_create(section, __LOCATION__, name="TORSION", &
459 : description="Specifies the torsion potential of the MM system.", &
460 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
461 :
462 8392 : NULLIFY (keyword)
463 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
464 : description="Defines the atomic kinds involved in the tors.", &
465 : usage="ATOMS {KIND1} {KIND2} {KIND3} {KIND4}", type_of_var=char_t, &
466 8392 : n_var=4)
467 8392 : CALL section_add_keyword(section, keyword)
468 8392 : CALL keyword_release(keyword)
469 :
470 : CALL keyword_create(keyword, __LOCATION__, name="KIND", &
471 : description="Define the kind of torsion potential", &
472 : usage="KIND CHARMM", &
473 : enum_c_vals=s2a("CHARMM", "G87", "G96", "AMBER", "OPLS"), &
474 : enum_desc=s2a("Functional Form (CHARMM|G87|G96|AMBER): K * [ 1 + cos[M*PHI - PHI0]]", &
475 : "Functional Form (CHARMM|G87|G96|AMBER): K * [ 1 + cos[M*PHI - PHI0]]", &
476 : "Functional Form (CHARMM|G87|G96|AMBER): K * [ 1 + cos[M*PHI - PHI0]]", &
477 : "Functional Form (CHARMM|G87|G96|AMBER): K * [ 1 + cos[M*PHI - PHI0]]", &
478 : "Functional Form: K / 2 * [ 1 + (-1)^(M-1) * cos[M*PHI]]"), &
479 : enum_i_vals=(/do_ff_charmm, &
480 : do_ff_g87, &
481 : do_ff_g96, &
482 : do_ff_amber, &
483 : do_ff_opls/), &
484 8392 : default_i_val=do_ff_charmm)
485 8392 : CALL section_add_keyword(section, keyword)
486 8392 : CALL keyword_release(keyword)
487 :
488 : CALL keyword_create(keyword, __LOCATION__, name="K", &
489 : description="Defines the force constant of the potential", &
490 : usage="K {real}", type_of_var=real_t, &
491 8392 : n_var=1, unit_str="hartree")
492 8392 : CALL section_add_keyword(section, keyword)
493 8392 : CALL keyword_release(keyword)
494 :
495 : CALL keyword_create(keyword, __LOCATION__, name="PHI0", &
496 : description="Defines the phase of the potential.", &
497 : usage="PHI0 {real}", type_of_var=real_t, &
498 8392 : n_var=1, unit_str="rad", default_r_val=0.0_dp)
499 8392 : CALL section_add_keyword(section, keyword)
500 8392 : CALL keyword_release(keyword)
501 :
502 : CALL keyword_create(keyword, __LOCATION__, name="M", &
503 : description="Defines the multiplicity of the potential.", &
504 : usage="M {integer}", type_of_var=integer_t, &
505 8392 : n_var=1)
506 8392 : CALL section_add_keyword(section, keyword)
507 8392 : CALL keyword_release(keyword)
508 :
509 8392 : END SUBROUTINE create_TORSION_section
510 :
511 : ! **************************************************************************************************
512 : !> \brief This section specifies the improper torsion of the MM atoms
513 : !> \param section the section to create
514 : !> \author louis vanduyfhuys
515 : ! **************************************************************************************************
516 8392 : SUBROUTINE create_IMPROPER_section(section)
517 : TYPE(section_type), POINTER :: section
518 :
519 : TYPE(keyword_type), POINTER :: keyword
520 :
521 8392 : CPASSERT(.NOT. ASSOCIATED(section))
522 : CALL section_create(section, __LOCATION__, name="IMPROPER", &
523 : description="Specifies the improper torsion potential of the MM system.", &
524 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
525 :
526 8392 : NULLIFY (keyword)
527 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
528 : description="Defines the atomic kinds involved in the improper tors.", &
529 : usage="ATOMS {KIND1} {KIND2} {KIND3} {KIND4}", type_of_var=char_t, &
530 8392 : n_var=4)
531 8392 : CALL section_add_keyword(section, keyword)
532 8392 : CALL keyword_release(keyword)
533 :
534 : CALL keyword_create(keyword, __LOCATION__, name="KIND", &
535 : description="Define the kind of improper torsion potential", &
536 : usage="KIND CHARMM", &
537 : enum_c_vals=s2a("CHARMM", "G87", "G96", "HARMONIC"), &
538 : enum_desc=s2a("Functional Form (CHARMM): K * [ PHI - PHI0 ]**2", &
539 : "Functional Form (G87|G96|HARMONIC): 0.5 * K * [ PHI - PHI0 ]**2", &
540 : "Functional Form (G87|G96|HARMONIC): 0.5 * K * [ PHI - PHI0 ]**2", &
541 : "Functional Form (G87|G96|HARMONIC): 0.5 * K * [ PHI - PHI0 ]**2"), &
542 : enum_i_vals=(/do_ff_charmm, &
543 : do_ff_g87, &
544 : do_ff_g96, &
545 : do_ff_harmonic/), &
546 8392 : default_i_val=do_ff_charmm)
547 8392 : CALL section_add_keyword(section, keyword)
548 8392 : CALL keyword_release(keyword)
549 :
550 : CALL keyword_create(keyword, __LOCATION__, name="K", &
551 : description="Defines the force constant of the potential", &
552 : usage="K {real}", type_of_var=real_t, &
553 8392 : n_var=1, unit_str="hartree*rad^-2")
554 8392 : CALL section_add_keyword(section, keyword)
555 8392 : CALL keyword_release(keyword)
556 :
557 : CALL keyword_create(keyword, __LOCATION__, name="PHI0", &
558 : description="Defines the phase of the potential.", &
559 : usage="PHI0 {real}", type_of_var=real_t, &
560 8392 : n_var=1, unit_str="rad")
561 8392 : CALL section_add_keyword(section, keyword)
562 8392 : CALL keyword_release(keyword)
563 :
564 8392 : END SUBROUTINE create_IMPROPER_section
565 :
566 : ! **************************************************************************************************
567 : !> \brief This section specifies the out of plane bend of the MM atoms
568 : !> \param section the section to create
569 : !> \author louis vanduyfhuys
570 : ! **************************************************************************************************
571 8392 : SUBROUTINE create_OPBEND_section(section)
572 : TYPE(section_type), POINTER :: section
573 :
574 : TYPE(keyword_type), POINTER :: keyword
575 :
576 8392 : CPASSERT(.NOT. ASSOCIATED(section))
577 : CALL section_create(section, __LOCATION__, name="OPBEND", &
578 : description="Specifies the out of plane bend potential of the MM system."// &
579 : " (Only defined for atom quadruples which are also defined as an improper"// &
580 : " pattern in the topology.)", &
581 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
582 :
583 8392 : NULLIFY (keyword)
584 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
585 : description="Defines the atomic kinds involved in the opbend.", &
586 : usage="ATOMS {KIND1} {KIND2} {KIND3} {KIND4}", type_of_var=char_t, &
587 8392 : n_var=4)
588 8392 : CALL section_add_keyword(section, keyword)
589 8392 : CALL keyword_release(keyword)
590 :
591 : CALL keyword_create(keyword, __LOCATION__, name="KIND", &
592 : description="Define the kind of out of plane bend potential", &
593 : usage="KIND HARMONIC", &
594 : enum_c_vals=s2a("HARMONIC", "MM2", "MM3", "MM4"), &
595 : enum_desc=s2a("Functional Form (HARMONIC): 0.5 * K * [ PHI - PHI0 ]**2", &
596 : "Functional Form (MM2|MM3|MM4): K * [ PHI - PHI0 ]**2", &
597 : "Functional Form (MM2|MM3|MM4): K * [ PHI - PHI0 ]**2", &
598 : "Functional Form (MM2|MM3|MM4): K * [ PHI - PHI0 ]**2"), &
599 : enum_i_vals=(/do_ff_harmonic, &
600 : do_ff_mm2, &
601 : do_ff_mm3, &
602 : do_ff_mm4/), &
603 8392 : default_i_val=do_ff_harmonic)
604 8392 : CALL section_add_keyword(section, keyword)
605 8392 : CALL keyword_release(keyword)
606 :
607 : CALL keyword_create(keyword, __LOCATION__, name="K", &
608 : description="Defines the force constant of the potential", &
609 : usage="K {real}", type_of_var=real_t, &
610 8392 : n_var=1, unit_str="hartree*rad^-2")
611 8392 : CALL section_add_keyword(section, keyword)
612 8392 : CALL keyword_release(keyword)
613 :
614 : CALL keyword_create(keyword, __LOCATION__, name="PHI0", &
615 : description="Defines the phase of the potential.", &
616 : usage="PHI0 {real}", type_of_var=real_t, &
617 8392 : n_var=1, unit_str="rad")
618 8392 : CALL section_add_keyword(section, keyword)
619 8392 : CALL keyword_release(keyword)
620 :
621 8392 : END SUBROUTINE create_OPBEND_section
622 :
623 : ! **************************************************************************************************
624 : !> \brief This section specifies the bend of the MM atoms
625 : !> \param section the section to create
626 : !> \author teo
627 : ! **************************************************************************************************
628 8392 : SUBROUTINE create_BEND_section(section)
629 : TYPE(section_type), POINTER :: section
630 :
631 : TYPE(keyword_type), POINTER :: keyword
632 : TYPE(section_type), POINTER :: subsection
633 :
634 8392 : CPASSERT(.NOT. ASSOCIATED(section))
635 : CALL section_create(section, __LOCATION__, name="BEND", &
636 : description="Specifies the bend potential of the MM system.", &
637 8392 : n_keywords=11, n_subsections=1, repeats=.TRUE.)
638 :
639 8392 : NULLIFY (keyword, subsection)
640 :
641 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
642 : description="Defines the atomic kinds involved in the bend.", &
643 : usage="ATOMS {KIND1} {KIND2} {KIND3}", type_of_var=char_t, &
644 8392 : n_var=3)
645 8392 : CALL section_add_keyword(section, keyword)
646 8392 : CALL keyword_release(keyword)
647 :
648 : CALL keyword_create( &
649 : keyword, __LOCATION__, name="KIND", &
650 : description="Define the kind of bend potential", &
651 : usage="KIND HARMONIC", &
652 : enum_c_vals=s2a("HARMONIC", "CHARMM", "AMBER", "G87", "G96", "CUBIC", "MIXED_BEND_STRETCH", "MM3", &
653 : "LEGENDRE"), &
654 : enum_desc=s2a("Functional Form (HARMONIC|G87): 1/2*K*(THETA-THETA0)^2", &
655 : "Functional Form (CHARMM|AMBER): K*(THETA-THETA0)^2", &
656 : "Functional Form (CHARMM|AMBER): K*(THETA-THETA0)^2", &
657 : "Functional Form (HARMONIC|G87): 1/2*K*(THETA-THETA0)^2", &
658 : "Functional Form (G96): 1/2*K*(COS(THETA)-THETA0)^2", &
659 : "Functional Form (CUBIC): K*(THETA-THETA0)**2*(1+CB*(THETA-THETA0))", &
660 : "Functional Form (MIXED_BEND_STRETCH): K*(THETA-THETA0)**2*(1+CB*(THETA-THETA0))+"// &
661 : " KSS*(R12-R012)*(R32-R032)+KBS12*(R12-R012)*(THETA-THETA0)+KBS32*(R32-R032)*(THETA-THETA0)", &
662 : "Functional Form (MM3): 1/2*K*(THETA-THETA0)**2*(1-0.014*(THETA-THETA0)+5.6E-5*(THETA-THETA0)**2"// &
663 : " -7.0E-7*(THETA-THETA0)**3+9.0E-10*(THETA-THETA0)**4)+KBS12*(R12-R012)*(THETA-THETA0)+"// &
664 : " KBS32*(R32-R032)*(THETA-THETA0)", &
665 : "Functional Form (LEGENDRE): sum_{i=0}^N c_i*P_i(COS(THETA)) "), &
666 : enum_i_vals=(/do_ff_harmonic, &
667 : do_ff_charmm, &
668 : do_ff_amber, &
669 : do_ff_g87, &
670 : do_ff_g96, &
671 : do_ff_cubic, &
672 : do_ff_mixed_bend_stretch, &
673 : do_ff_mm3, &
674 : do_ff_legendre/), &
675 8392 : default_i_val=do_ff_charmm)
676 8392 : CALL section_add_keyword(section, keyword)
677 8392 : CALL keyword_release(keyword)
678 :
679 : CALL keyword_create(keyword, __LOCATION__, name="K", &
680 : description="Defines the force constant of the potential", &
681 : usage="K {real}", type_of_var=real_t, &
682 8392 : n_var=1, unit_str="hartree*rad^-2")
683 8392 : CALL section_add_keyword(section, keyword)
684 8392 : CALL keyword_release(keyword)
685 :
686 : CALL keyword_create(keyword, __LOCATION__, name="CB", &
687 : description="Defines the the cubic force constant of the bend", &
688 : usage="CB {real}", default_r_val=0.0_dp, type_of_var=real_t, &
689 8392 : n_var=1, unit_str="rad^-1")
690 8392 : CALL section_add_keyword(section, keyword)
691 8392 : CALL keyword_release(keyword)
692 :
693 : CALL keyword_create(keyword, __LOCATION__, name="R012", &
694 : description="Mixed bend stretch parameter", &
695 : usage="R012 {real}", default_r_val=0.0_dp, type_of_var=real_t, &
696 8392 : n_var=1, unit_str="bohr")
697 8392 : CALL section_add_keyword(section, keyword)
698 8392 : CALL keyword_release(keyword)
699 : CALL keyword_create(keyword, __LOCATION__, name="R032", &
700 : description="Mixed bend stretch parameter", &
701 : usage="R032 {real}", default_r_val=0.0_dp, type_of_var=real_t, &
702 8392 : n_var=1, unit_str="bohr")
703 8392 : CALL section_add_keyword(section, keyword)
704 8392 : CALL keyword_release(keyword)
705 : CALL keyword_create(keyword, __LOCATION__, name="KBS12", &
706 : description="Mixed bend stretch parameter", &
707 : usage="KBS12 {real}", default_r_val=0.0_dp, type_of_var=real_t, &
708 8392 : n_var=1, unit_str="hartree*bohr^-1*rad^-1")
709 8392 : CALL section_add_keyword(section, keyword)
710 8392 : CALL keyword_release(keyword)
711 : CALL keyword_create(keyword, __LOCATION__, name="KBS32", &
712 : description="Mixed bend stretch parameter", &
713 : usage="KBS32 {real}", default_r_val=0.0_dp, type_of_var=real_t, &
714 8392 : n_var=1, unit_str="hartree*bohr^-1*rad^-1")
715 8392 : CALL section_add_keyword(section, keyword)
716 8392 : CALL keyword_release(keyword)
717 : CALL keyword_create(keyword, __LOCATION__, name="KSS", &
718 : description="Mixed bend stretch parameter", &
719 : usage="KSS {real}", default_r_val=0.0_dp, type_of_var=real_t, &
720 8392 : n_var=1, unit_str="hartree*bohr^-2")
721 8392 : CALL section_add_keyword(section, keyword)
722 8392 : CALL keyword_release(keyword)
723 :
724 : CALL keyword_create(keyword, __LOCATION__, name="THETA0", &
725 : description="Defines the equilibrium angle.", &
726 : usage="THETA0 {real}", type_of_var=real_t, &
727 8392 : n_var=1, unit_str='rad')
728 8392 : CALL section_add_keyword(section, keyword)
729 8392 : CALL keyword_release(keyword)
730 :
731 : CALL keyword_create(keyword, __LOCATION__, name="LEGENDRE", &
732 : description="Specifies the coefficients for the legendre"// &
733 : " expansion of the bending potential."// &
734 : " 'THETA0' and 'K' are not used, but need to be specified."// &
735 : " Use an arbitrary value.", usage="LEGENDRE {REAL} {REAL} ...", &
736 : default_r_val=0.0d0, type_of_var=real_t, &
737 8392 : n_var=-1, unit_str="hartree")
738 8392 : CALL section_add_keyword(section, keyword)
739 8392 : CALL keyword_release(keyword)
740 :
741 : ! Create the Urey-Bradley section
742 8392 : CALL create_BOND_section(subsection, "UB")
743 8392 : CALL section_add_subsection(section, subsection)
744 8392 : CALL section_release(subsection)
745 :
746 8392 : END SUBROUTINE create_BEND_section
747 :
748 : ! **************************************************************************************************
749 : !> \brief This section specifies the bond of the MM atoms
750 : !> \param section the section to create
751 : !> \param label ...
752 : !> \author teo
753 : ! **************************************************************************************************
754 16784 : SUBROUTINE create_BOND_section(section, label)
755 : TYPE(section_type), POINTER :: section
756 : CHARACTER(LEN=*), INTENT(IN) :: label
757 :
758 : CHARACTER(LEN=default_string_length) :: tag
759 : TYPE(keyword_type), POINTER :: keyword
760 :
761 16784 : CPASSERT(.NOT. ASSOCIATED(section))
762 16784 : NULLIFY (keyword)
763 :
764 16784 : IF (TRIM(label) == "UB") THEN
765 8392 : tag = " Urey-Bradley "
766 : CALL section_create(section, __LOCATION__, name=TRIM(label), &
767 : description="Specifies the Urey-Bradley potential between the external atoms"// &
768 : " defining the angle", &
769 8392 : n_keywords=1, n_subsections=0, repeats=.FALSE.)
770 :
771 : ELSE
772 8392 : tag = " Bond "
773 : CALL section_create(section, __LOCATION__, name=TRIM(label), &
774 : description="Specifies the bond potential", &
775 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
776 :
777 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
778 : description="Defines the atomic kinds involved in the bond.", &
779 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
780 8392 : n_var=2)
781 8392 : CALL section_add_keyword(section, keyword)
782 8392 : CALL keyword_release(keyword)
783 : END IF
784 :
785 : CALL keyword_create(keyword, __LOCATION__, name="KIND", &
786 : description="Define the kind of"//TRIM(tag)//"potential.", &
787 : usage="KIND HARMONIC", &
788 : enum_c_vals=s2a("HARMONIC", "CHARMM", "AMBER", "G87", "G96", "QUARTIC", &
789 : "MORSE", "CUBIC", "FUES"), &
790 : enum_desc=s2a("Functional Form (HARMONIC|G87): 1/2*K*(R-R0)^2", &
791 : "Functional Form (CHARMM|AMBER): K*(R-R0)^2", &
792 : "Functional Form (CHARMM|AMBER): K*(R-R0)^2", &
793 : "Functional Form (HARMONIC|G87): 1/2*K*(R-R0)^2", &
794 : "Functional Form (G96): 1/4*K*(R^2-R0^2)^2", &
795 : "Functional Form (QUARTIC): (1/2*K1+[1/3*K2+1/4*K3*|R-R0|]*|R-R0|)(R-R0)^2", &
796 : "Functional Form (MORSE): K1*[(1-exp(-K2*(R-R0)))^2-1])", &
797 : "Functional Form (CUBIC): K*(R-R0)^2*(1+cs*(R-R0)+7/12*(cs^2*(R-R0)^2))", &
798 : "Functional Form (FUES): 1/2*K*R0^2*(1+R0/R*(R0/R-2))"), &
799 : enum_i_vals=(/do_ff_harmonic, &
800 : do_ff_charmm, &
801 : do_ff_amber, &
802 : do_ff_g87, &
803 : do_ff_g96, &
804 : do_ff_quartic, &
805 : do_ff_morse, &
806 : do_ff_cubic, &
807 : do_ff_fues/), &
808 16784 : default_i_val=do_ff_charmm)
809 16784 : CALL section_add_keyword(section, keyword)
810 16784 : CALL keyword_release(keyword)
811 :
812 : CALL keyword_create(keyword, __LOCATION__, name="K", &
813 : description="Defines the force constant of the potential. "// &
814 : "For MORSE potentials 2 numbers are expected. "// &
815 : "For QUARTIC potentials 3 numbers are expected.", &
816 : usage="K {real}", type_of_var=real_t, &
817 16784 : n_var=-1, unit_str="internal_cp2k")
818 16784 : CALL section_add_keyword(section, keyword)
819 16784 : CALL keyword_release(keyword)
820 :
821 : CALL keyword_create(keyword, __LOCATION__, name="CS", &
822 : description="Defines the cubic stretch term.", &
823 : usage="CS {real}", default_r_val=0.0_dp, type_of_var=real_t, &
824 16784 : n_var=1, unit_str="bohr^-1")
825 16784 : CALL section_add_keyword(section, keyword)
826 16784 : CALL keyword_release(keyword)
827 :
828 : CALL keyword_create(keyword, __LOCATION__, name="R0", &
829 : description="Defines the equilibrium distance.", &
830 : usage="R0 {real}", type_of_var=real_t, &
831 16784 : n_var=1, unit_str="bohr")
832 16784 : CALL section_add_keyword(section, keyword)
833 16784 : CALL keyword_release(keyword)
834 :
835 16784 : END SUBROUTINE create_BOND_section
836 :
837 : ! **************************************************************************************************
838 : !> \brief This section specifies the charge of the MM atoms
839 : !> \param section the section to create
840 : !> \author teo
841 : ! **************************************************************************************************
842 8392 : SUBROUTINE create_charges_section(section)
843 : TYPE(section_type), POINTER :: section
844 :
845 : TYPE(keyword_type), POINTER :: keyword
846 :
847 8392 : CPASSERT(.NOT. ASSOCIATED(section))
848 : CALL section_create(section, __LOCATION__, name="charges", &
849 : description="Allow to specify an array of classical charges, thus avoiding the"// &
850 : " packing and permitting the usage of different charges for same atomic types.", &
851 8392 : n_keywords=1, n_subsections=0, repeats=.FALSE.)
852 :
853 8392 : NULLIFY (keyword)
854 : CALL keyword_create(keyword, __LOCATION__, name="_DEFAULT_KEYWORD_", &
855 : description="Value of the charge for the individual atom. Order MUST reflect"// &
856 : " the one specified for the geometry.", repeats=.TRUE., usage="{Real}", &
857 8392 : type_of_var=real_t)
858 8392 : CALL section_add_keyword(section, keyword)
859 8392 : CALL keyword_release(keyword)
860 :
861 8392 : END SUBROUTINE create_charges_section
862 :
863 : ! **************************************************************************************************
864 : !> \brief This section specifies the charge of the MM atoms
865 : !> \param section the section to create
866 : !> \author teo
867 : ! **************************************************************************************************
868 25176 : SUBROUTINE create_charge_section(section)
869 : TYPE(section_type), POINTER :: section
870 :
871 : TYPE(keyword_type), POINTER :: keyword
872 :
873 25176 : CPASSERT(.NOT. ASSOCIATED(section))
874 : CALL section_create(section, __LOCATION__, name="charge", &
875 : description="This section specifies the charge of the MM atoms", &
876 25176 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
877 :
878 25176 : NULLIFY (keyword)
879 :
880 : CALL keyword_create(keyword, __LOCATION__, name="ATOM", &
881 : description="Defines the atomic kind of the charge.", &
882 : usage="ATOM {KIND1}", type_of_var=char_t, &
883 25176 : n_var=1)
884 25176 : CALL section_add_keyword(section, keyword)
885 25176 : CALL keyword_release(keyword)
886 :
887 : CALL keyword_create(keyword, __LOCATION__, name="CHARGE", &
888 : description="Defines the charge of the MM atom in electron charge unit.", &
889 : usage="CHARGE {real}", type_of_var=real_t, &
890 25176 : n_var=1)
891 25176 : CALL section_add_keyword(section, keyword)
892 25176 : CALL keyword_release(keyword)
893 :
894 25176 : END SUBROUTINE create_charge_section
895 :
896 : ! **************************************************************************************************
897 : !> \brief This section specifies the isotropic polarizability of the MM atoms
898 : !> \param section the section to create
899 : !> \author Marcel Baer
900 : ! **************************************************************************************************
901 8392 : SUBROUTINE create_quadrupole_section(section)
902 : TYPE(section_type), POINTER :: section
903 :
904 : TYPE(keyword_type), POINTER :: keyword
905 :
906 8392 : CPASSERT(.NOT. ASSOCIATED(section))
907 : CALL section_create( &
908 : section, __LOCATION__, name="QUADRUPOLE", &
909 : description="This section specifies that we will perform an SCF quadrupole calculation of the MM atoms. "// &
910 : "Needs KEYWORD POL_SCF in POISSON secton", &
911 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
912 :
913 8392 : NULLIFY (keyword)
914 :
915 : CALL keyword_create(keyword, __LOCATION__, name="ATOM", &
916 : description="Defines the atomic kind of the SCF quadrupole.", &
917 : usage="ATOM {KIND1}", type_of_var=char_t, &
918 8392 : n_var=1)
919 8392 : CALL section_add_keyword(section, keyword)
920 8392 : CALL keyword_release(keyword)
921 :
922 : CALL keyword_create(keyword, __LOCATION__, name="CPOL", &
923 : description="Defines the isotropic polarizability of the MM atom.", &
924 : usage="CPOL {real}", type_of_var=real_t, &
925 8392 : n_var=1, unit_str='internal_cp2k')
926 8392 : CALL section_add_keyword(section, keyword)
927 8392 : CALL keyword_release(keyword)
928 :
929 8392 : END SUBROUTINE create_quadrupole_section
930 :
931 : ! **************************************************************************************************
932 : !> \brief This section specifies the isotropic polarizability of the MM atoms
933 : !> \param section the section to create
934 : !> \author Marcel Baer
935 : ! **************************************************************************************************
936 8392 : SUBROUTINE create_dipole_section(section)
937 : TYPE(section_type), POINTER :: section
938 :
939 : TYPE(keyword_type), POINTER :: keyword
940 : TYPE(section_type), POINTER :: subsection
941 :
942 8392 : CPASSERT(.NOT. ASSOCIATED(section))
943 : CALL section_create(section, __LOCATION__, name="DIPOLE", &
944 : description="This section specifies that we will perform an SCF dipole calculation of the MM atoms. "// &
945 : "Needs KEYWORD POL_SCF in POISSON secton", &
946 8392 : n_keywords=1, n_subsections=1, repeats=.TRUE.)
947 :
948 8392 : NULLIFY (subsection, keyword)
949 :
950 : CALL keyword_create(keyword, __LOCATION__, name="ATOM", &
951 : description="Defines the atomic kind of the SCF dipole.", &
952 : usage="ATOM {KIND1}", type_of_var=char_t, &
953 8392 : n_var=1)
954 8392 : CALL section_add_keyword(section, keyword)
955 8392 : CALL keyword_release(keyword)
956 :
957 : CALL keyword_create(keyword, __LOCATION__, name="APOL", &
958 : description="Defines the isotropic polarizability of the MM atom.", &
959 : usage="APOL {real}", type_of_var=real_t, &
960 8392 : n_var=1, unit_str='angstrom^3')
961 8392 : CALL section_add_keyword(section, keyword)
962 8392 : CALL keyword_release(keyword)
963 :
964 8392 : CALL create_DAMPING_section(subsection)
965 8392 : CALL section_add_subsection(section, subsection)
966 8392 : CALL section_release(subsection)
967 8392 : END SUBROUTINE create_dipole_section
968 :
969 : ! **************************************************************************************************
970 : !> \brief This section specifies the idamping parameters for polarizable atoms
971 : !> \param section the section to create
972 : !> \author Rodolphe Vuilleumier
973 : ! **************************************************************************************************
974 8392 : SUBROUTINE create_damping_section(section)
975 : TYPE(section_type), POINTER :: section
976 :
977 : TYPE(keyword_type), POINTER :: keyword
978 :
979 8392 : CPASSERT(.NOT. ASSOCIATED(section))
980 : CALL section_create(section, __LOCATION__, name="DAMPING", &
981 : description="This section specifies optional electric field damping for the polarizable atoms. ", &
982 8392 : n_keywords=4, n_subsections=0, repeats=.TRUE.)
983 :
984 8392 : NULLIFY (keyword)
985 :
986 : CALL keyword_create(keyword, __LOCATION__, name="ATOM", &
987 : description="Defines the atomic kind for this damping function.", &
988 : usage="ATOM {KIND1}", type_of_var=char_t, &
989 8392 : n_var=1)
990 8392 : CALL section_add_keyword(section, keyword)
991 8392 : CALL keyword_release(keyword)
992 :
993 : CALL keyword_create(keyword, __LOCATION__, name="TYPE", &
994 : description="Defines the damping type.", &
995 : usage="TYPE {string}", type_of_var=char_t, &
996 8392 : n_var=1, default_c_val="TANG-TOENNIES")
997 8392 : CALL section_add_keyword(section, keyword)
998 8392 : CALL keyword_release(keyword)
999 :
1000 : CALL keyword_create(keyword, __LOCATION__, name="ORDER", &
1001 : description="Defines the order for this damping.", &
1002 : usage="ORDER {integer}", type_of_var=integer_t, &
1003 8392 : n_var=1, default_i_val=3)
1004 8392 : CALL section_add_keyword(section, keyword)
1005 8392 : CALL keyword_release(keyword)
1006 :
1007 : CALL keyword_create(keyword, __LOCATION__, name="BIJ", &
1008 : description="Defines the BIJ parameter for this damping.", &
1009 : usage="BIJ {real}", type_of_var=real_t, &
1010 8392 : n_var=1, unit_str='angstrom^-1')
1011 8392 : CALL section_add_keyword(section, keyword)
1012 8392 : CALL keyword_release(keyword)
1013 :
1014 : CALL keyword_create(keyword, __LOCATION__, name="CIJ", &
1015 : description="Defines the CIJ parameter for this damping.", &
1016 : usage="CIJ {real}", type_of_var=real_t, &
1017 8392 : n_var=1, unit_str='')
1018 8392 : CALL section_add_keyword(section, keyword)
1019 8392 : CALL keyword_release(keyword)
1020 :
1021 8392 : END SUBROUTINE create_damping_section
1022 :
1023 : ! **************************************************************************************************
1024 : !> \brief This section specifies the charge of the MM atoms
1025 : !> \param section the section to create
1026 : !> \author teo
1027 : ! **************************************************************************************************
1028 8392 : SUBROUTINE create_shell_section(section)
1029 : TYPE(section_type), POINTER :: section
1030 :
1031 : TYPE(keyword_type), POINTER :: keyword
1032 :
1033 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1034 : CALL section_create(section, __LOCATION__, name="SHELL", &
1035 : description="This section specifies the parameters for shell-model potentials", &
1036 : n_keywords=6, n_subsections=0, repeats=.TRUE., &
1037 33568 : citations=(/Dick1958, Mitchell1993, Devynck2012/))
1038 :
1039 8392 : NULLIFY (keyword)
1040 :
1041 : CALL keyword_create(keyword, __LOCATION__, name="_SECTION_PARAMETERS_", &
1042 : description="The kind for which the shell potential parameters are given ", &
1043 8392 : usage="H", default_c_val="DEFAULT")
1044 8392 : CALL section_add_keyword(section, keyword)
1045 8392 : CALL keyword_release(keyword)
1046 :
1047 : CALL keyword_create(keyword, __LOCATION__, name="CORE_CHARGE", &
1048 : variants=(/"CORE"/), &
1049 : description="Partial charge assigned to the core (electron charge units)", &
1050 : usage="CORE_CHARGE {real}", &
1051 16784 : default_r_val=0.0_dp)
1052 8392 : CALL section_add_keyword(section, keyword)
1053 8392 : CALL keyword_release(keyword)
1054 :
1055 : CALL keyword_create(keyword, __LOCATION__, name="SHELL_CHARGE", &
1056 : variants=(/"SHELL"/), &
1057 : description="Partial charge assigned to the shell (electron charge units)", &
1058 : usage="SHELL_CHARGE {real}", &
1059 16784 : default_r_val=0.0_dp)
1060 8392 : CALL section_add_keyword(section, keyword)
1061 8392 : CALL keyword_release(keyword)
1062 :
1063 : CALL keyword_create(keyword, __LOCATION__, name="MASS_FRACTION", &
1064 : variants=(/"MASS"/), &
1065 : description="Fraction of the mass of the atom to be assigned to the shell", &
1066 : usage="MASS_FRACTION {real}", &
1067 16784 : default_r_val=0.1_dp)
1068 8392 : CALL section_add_keyword(section, keyword)
1069 8392 : CALL keyword_release(keyword)
1070 :
1071 : CALL keyword_create(keyword, __LOCATION__, name="K2_SPRING", &
1072 : variants=s2a("K2", "SPRING"), &
1073 : description="Force constant k2 of the spring potential 1/2*k2*r^2 + 1/24*k4*r^4 "// &
1074 : "binding a core-shell pair when a core-shell potential is employed.", &
1075 : repeats=.FALSE., &
1076 : usage="K2_SPRING {real}", &
1077 : default_r_val=-1.0_dp, &
1078 8392 : unit_str="hartree*bohr^-2")
1079 8392 : CALL section_add_keyword(section, keyword)
1080 8392 : CALL keyword_release(keyword)
1081 :
1082 : CALL keyword_create(keyword, __LOCATION__, name="K4_SPRING", &
1083 : variants=s2a("K4"), &
1084 : description="Force constant k4 of the spring potential 1/2*k2*r^2 + 1/24*k4*r^4 "// &
1085 : "binding a core-shell pair when a core-shell potential is employed. "// &
1086 : "By default a harmonic spring potential is used, i.e. k4 is zero.", &
1087 : repeats=.FALSE., &
1088 : usage="K4_SPRING {real}", &
1089 : default_r_val=0.0_dp, &
1090 8392 : unit_str="hartree*bohr^-4")
1091 8392 : CALL section_add_keyword(section, keyword)
1092 8392 : CALL keyword_release(keyword)
1093 :
1094 : CALL keyword_create(keyword, __LOCATION__, name="MAX_DISTANCE", &
1095 : description="Assign a maximum elongation of the spring, "// &
1096 : "if negative no limit is imposed", &
1097 : usage="MAX_DISTANCE 0.0", &
1098 : default_r_val=-1.0_dp, &
1099 8392 : unit_str="angstrom")
1100 8392 : CALL section_add_keyword(section, keyword)
1101 8392 : CALL keyword_release(keyword)
1102 :
1103 : CALL keyword_create(keyword, __LOCATION__, name="SHELL_CUTOFF", &
1104 : description="Define a screening function to exclude some neighbors "// &
1105 : "of the shell when electrostatic interaction are considered, "// &
1106 : "if negative no screening is operated", &
1107 : usage="SHELL_CUTOFF -1.0", &
1108 : default_r_val=-1.0_dp, &
1109 8392 : unit_str="angstrom")
1110 8392 : CALL section_add_keyword(section, keyword)
1111 8392 : CALL keyword_release(keyword)
1112 :
1113 8392 : END SUBROUTINE create_shell_section
1114 :
1115 : ! **************************************************************************************************
1116 : !> \brief This section specifies the input parameters for 1-4 NON-BONDED
1117 : !> Interactions
1118 : !> \param section the section to create
1119 : !> \author teo
1120 : ! **************************************************************************************************
1121 16784 : SUBROUTINE create_NONBONDED14_section(section)
1122 : TYPE(section_type), POINTER :: section
1123 :
1124 : TYPE(section_type), POINTER :: subsection
1125 :
1126 16784 : CPASSERT(.NOT. ASSOCIATED(section))
1127 : CALL section_create(section, __LOCATION__, name="nonbonded14", &
1128 : description="This section specifies the input parameters for 1-4 NON-BONDED interactions.", &
1129 16784 : n_keywords=1, n_subsections=0, repeats=.FALSE.)
1130 :
1131 16784 : NULLIFY (subsection)
1132 16784 : CALL create_LJ_section(subsection)
1133 16784 : CALL section_add_subsection(section, subsection)
1134 16784 : CALL section_release(subsection)
1135 :
1136 16784 : CALL create_Williams_section(subsection)
1137 16784 : CALL section_add_subsection(section, subsection)
1138 16784 : CALL section_release(subsection)
1139 :
1140 16784 : CALL create_Goodwin_section(subsection)
1141 16784 : CALL section_add_subsection(section, subsection)
1142 16784 : CALL section_release(subsection)
1143 :
1144 16784 : CALL create_GENPOT_section(subsection)
1145 16784 : CALL section_add_subsection(section, subsection)
1146 16784 : CALL section_release(subsection)
1147 :
1148 16784 : END SUBROUTINE create_NONBONDED14_section
1149 :
1150 : ! **************************************************************************************************
1151 : !> \brief This section specifies the input parameters for 1-4 NON-BONDED
1152 : !> Interactions
1153 : !> \param section the section to create
1154 : !> \author teo
1155 : ! **************************************************************************************************
1156 8392 : SUBROUTINE create_NONBONDED_section(section)
1157 : TYPE(section_type), POINTER :: section
1158 :
1159 : TYPE(section_type), POINTER :: subsection
1160 :
1161 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1162 : CALL section_create(section, __LOCATION__, name="nonbonded", &
1163 : description="This section specifies the input parameters for NON-BONDED interactions.", &
1164 8392 : n_keywords=1, n_subsections=0, repeats=.FALSE.)
1165 :
1166 8392 : NULLIFY (subsection)
1167 8392 : CALL create_LJ_section(subsection)
1168 8392 : CALL section_add_subsection(section, subsection)
1169 8392 : CALL section_release(subsection)
1170 :
1171 8392 : CALL create_Williams_section(subsection)
1172 8392 : CALL section_add_subsection(section, subsection)
1173 8392 : CALL section_release(subsection)
1174 :
1175 8392 : CALL create_EAM_section(subsection)
1176 8392 : CALL section_add_subsection(section, subsection)
1177 8392 : CALL section_release(subsection)
1178 :
1179 8392 : CALL create_QUIP_section(subsection)
1180 8392 : CALL section_add_subsection(section, subsection)
1181 8392 : CALL section_release(subsection)
1182 :
1183 8392 : CALL create_NEQUIP_section(subsection)
1184 8392 : CALL section_add_subsection(section, subsection)
1185 8392 : CALL section_release(subsection)
1186 :
1187 8392 : CALL create_ALLEGRO_section(subsection)
1188 8392 : CALL section_add_subsection(section, subsection)
1189 8392 : CALL section_release(subsection)
1190 :
1191 8392 : CALL create_DEEPMD_section(subsection)
1192 8392 : CALL section_add_subsection(section, subsection)
1193 8392 : CALL section_release(subsection)
1194 :
1195 8392 : CALL create_Goodwin_section(subsection)
1196 8392 : CALL section_add_subsection(section, subsection)
1197 8392 : CALL section_release(subsection)
1198 :
1199 8392 : CALL create_IPBV_section(subsection)
1200 8392 : CALL section_add_subsection(section, subsection)
1201 8392 : CALL section_release(subsection)
1202 :
1203 8392 : CALL create_BMHFT_section(subsection)
1204 8392 : CALL section_add_subsection(section, subsection)
1205 8392 : CALL section_release(subsection)
1206 :
1207 8392 : CALL create_BMHFTD_section(subsection)
1208 8392 : CALL section_add_subsection(section, subsection)
1209 8392 : CALL section_release(subsection)
1210 :
1211 8392 : CALL create_Buck4r_section(subsection)
1212 8392 : CALL section_add_subsection(section, subsection)
1213 8392 : CALL section_release(subsection)
1214 :
1215 8392 : CALL create_Buckmorse_section(subsection)
1216 8392 : CALL section_add_subsection(section, subsection)
1217 8392 : CALL section_release(subsection)
1218 :
1219 8392 : CALL create_GENPOT_section(subsection)
1220 8392 : CALL section_add_subsection(section, subsection)
1221 8392 : CALL section_release(subsection)
1222 :
1223 8392 : CALL create_Tersoff_section(subsection)
1224 8392 : CALL section_add_subsection(section, subsection)
1225 8392 : CALL section_release(subsection)
1226 :
1227 8392 : CALL create_Siepmann_section(subsection)
1228 8392 : CALL section_add_subsection(section, subsection)
1229 8392 : CALL section_release(subsection)
1230 :
1231 8392 : CALL create_Gal_section(subsection)
1232 8392 : CALL section_add_subsection(section, subsection)
1233 8392 : CALL section_release(subsection)
1234 :
1235 8392 : CALL create_Gal21_section(subsection)
1236 8392 : CALL section_add_subsection(section, subsection)
1237 8392 : CALL section_release(subsection)
1238 :
1239 8392 : CALL create_TABPOT_section(subsection)
1240 8392 : CALL section_add_subsection(section, subsection)
1241 8392 : CALL section_release(subsection)
1242 :
1243 8392 : END SUBROUTINE create_NONBONDED_section
1244 :
1245 : ! **************************************************************************************************
1246 : !> \brief This section specifies the input parameters for generation of
1247 : !> neighbor lists
1248 : !> \param section the section to create
1249 : !> \author teo [07.2007] - Zurich University
1250 : ! **************************************************************************************************
1251 25192 : SUBROUTINE create_neighbor_lists_section(section)
1252 : TYPE(section_type), POINTER :: section
1253 :
1254 : TYPE(keyword_type), POINTER :: keyword
1255 :
1256 25192 : NULLIFY (keyword)
1257 25192 : CPASSERT(.NOT. ASSOCIATED(section))
1258 : CALL section_create(section, __LOCATION__, name="neighbor_lists", &
1259 : description="This section specifies the input parameters for the construction of"// &
1260 : " neighbor lists.", &
1261 25192 : n_keywords=1, n_subsections=0, repeats=.FALSE.)
1262 :
1263 : CALL keyword_create(keyword, __LOCATION__, name="VERLET_SKIN", &
1264 : description="Defines the Verlet Skin for the generation of the neighbor lists", &
1265 : usage="VERLET_SKIN {real}", default_r_val=cp_unit_to_cp2k(value=1.0_dp, &
1266 : unit_str="angstrom"), &
1267 25192 : unit_str="angstrom")
1268 25192 : CALL section_add_keyword(section, keyword)
1269 25192 : CALL keyword_release(keyword)
1270 :
1271 : CALL keyword_create(keyword, __LOCATION__, name="neighbor_lists_from_scratch", &
1272 : description="This keyword enables the building of the neighbouring list from scratch.", &
1273 : usage="neighbor_lists_from_scratch logical", &
1274 25192 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
1275 25192 : CALL section_add_keyword(section, keyword)
1276 25192 : CALL keyword_release(keyword)
1277 :
1278 : CALL keyword_create(keyword, __LOCATION__, name="GEO_CHECK", &
1279 : description="This keyword enables the check that two atoms are never below the minimum"// &
1280 : " value used to construct the splines during the construction of the neighbouring list."// &
1281 : " Disabling this keyword avoids CP2K to abort in case two atoms are below the minimum"// &
1282 : " value of the radius used to generate the splines.", &
1283 : usage="GEO_CHECK", &
1284 25192 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
1285 25192 : CALL section_add_keyword(section, keyword)
1286 25192 : CALL keyword_release(keyword)
1287 :
1288 25192 : END SUBROUTINE create_neighbor_lists_section
1289 :
1290 : ! **************************************************************************************************
1291 : !> \brief This section specifies the input parameters for a generic potential form
1292 : !> \param section the section to create
1293 : !> \author teo
1294 : ! **************************************************************************************************
1295 41976 : SUBROUTINE create_GENPOT_section(section)
1296 : TYPE(section_type), POINTER :: section
1297 :
1298 : TYPE(keyword_type), POINTER :: keyword
1299 :
1300 41976 : CPASSERT(.NOT. ASSOCIATED(section))
1301 : CALL section_create(section, __LOCATION__, name="GENPOT", &
1302 : description="This section specifies the input parameters for a generic potential type. "// &
1303 : "A functional form is specified. Mathematical Operators recognized are +, -, *, /, ** "// &
1304 : "or alternatively ^, whereas symbols for brackets must be (). "// &
1305 : "The function parser recognizes the (single argument) Fortran 90 intrinsic functions "// &
1306 : "abs, exp, log10, log, sqrt, sinh, cosh, tanh, sin, cos, tan, asin, acos, atan, erf, erfc. "// &
1307 : "Parsing for intrinsic functions is not case sensitive.", &
1308 41976 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
1309 :
1310 41976 : NULLIFY (keyword)
1311 :
1312 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1313 : description="Defines the atomic kind involved in the generic potential", &
1314 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1315 41976 : n_var=2)
1316 41976 : CALL section_add_keyword(section, keyword)
1317 41976 : CALL keyword_release(keyword)
1318 :
1319 : CALL keyword_create(keyword, __LOCATION__, name="FUNCTION", &
1320 : description="Specifies the functional form in mathematical notation.", &
1321 : usage="FUNCTION a*EXP(-b*x^2)/x+D*log10(x)", type_of_var=lchar_t, &
1322 41976 : n_var=1)
1323 41976 : CALL section_add_keyword(section, keyword)
1324 41976 : CALL keyword_release(keyword)
1325 :
1326 : CALL keyword_create(keyword, __LOCATION__, name="VARIABLES", &
1327 : description="Defines the variable of the functional form.", &
1328 : usage="VARIABLES x", type_of_var=char_t, &
1329 41976 : n_var=-1)
1330 41976 : CALL section_add_keyword(section, keyword)
1331 41976 : CALL keyword_release(keyword)
1332 :
1333 : CALL keyword_create(keyword, __LOCATION__, name="PARAMETERS", &
1334 : description="Defines the parameters of the functional form", &
1335 : usage="PARAMETERS a b D", type_of_var=char_t, &
1336 41976 : n_var=-1, repeats=.TRUE.)
1337 41976 : CALL section_add_keyword(section, keyword)
1338 41976 : CALL keyword_release(keyword)
1339 :
1340 : CALL keyword_create(keyword, __LOCATION__, name="VALUES", &
1341 : description="Defines the values of parameter of the functional form", &
1342 : usage="VALUES ", type_of_var=real_t, &
1343 41976 : n_var=-1, repeats=.TRUE., unit_str="internal_cp2k")
1344 41976 : CALL section_add_keyword(section, keyword)
1345 41976 : CALL keyword_release(keyword)
1346 :
1347 : CALL keyword_create(keyword, __LOCATION__, name="UNITS", &
1348 : description="Optionally, allows to define valid CP2K unit strings for each parameter value. "// &
1349 : "It is assumed that the corresponding parameter value is specified in this unit.", &
1350 : usage="UNITS angstrom eV*angstrom^-1 angstrom^1 K", type_of_var=char_t, &
1351 41976 : n_var=-1, repeats=.TRUE.)
1352 41976 : CALL section_add_keyword(section, keyword)
1353 41976 : CALL keyword_release(keyword)
1354 :
1355 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
1356 : description="Defines the cutoff parameter of the generic potential", &
1357 : usage="RCUT {real}", default_r_val=cp_unit_to_cp2k(value=10.0_dp, &
1358 : unit_str="angstrom"), &
1359 41976 : unit_str="angstrom")
1360 41976 : CALL section_add_keyword(section, keyword)
1361 41976 : CALL keyword_release(keyword)
1362 :
1363 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
1364 : description="Defines the lower bound of the potential. If not set the range is the"// &
1365 : " full range generate by the spline", usage="RMIN {real}", &
1366 41976 : type_of_var=real_t, unit_str="angstrom")
1367 41976 : CALL section_add_keyword(section, keyword)
1368 41976 : CALL keyword_release(keyword)
1369 :
1370 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
1371 : description="Defines the upper bound of the potential. If not set the range is the"// &
1372 : " full range generate by the spline", usage="RMAX {real}", &
1373 41976 : type_of_var=real_t, unit_str="angstrom")
1374 41976 : CALL section_add_keyword(section, keyword)
1375 41976 : CALL keyword_release(keyword)
1376 :
1377 41976 : END SUBROUTINE create_GENPOT_section
1378 :
1379 : ! **************************************************************************************************
1380 : !> \brief This section specifies the input parameters for EAM potential type
1381 : !> \param section the section to create
1382 : !> \author teo
1383 : ! **************************************************************************************************
1384 8392 : SUBROUTINE create_EAM_section(section)
1385 : TYPE(section_type), POINTER :: section
1386 :
1387 : TYPE(keyword_type), POINTER :: keyword
1388 :
1389 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1390 : CALL section_create(section, __LOCATION__, name="EAM", &
1391 : description="This section specifies the input parameters for EAM potential type.", &
1392 16784 : citations=(/Foiles1986/), n_keywords=1, n_subsections=0, repeats=.TRUE.)
1393 :
1394 8392 : NULLIFY (keyword)
1395 :
1396 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1397 : description="Defines the atomic kind involved in the nonbond potential", &
1398 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1399 8392 : n_var=2)
1400 8392 : CALL section_add_keyword(section, keyword)
1401 8392 : CALL keyword_release(keyword)
1402 :
1403 : CALL keyword_create(keyword, __LOCATION__, name="PARM_FILE_NAME", &
1404 : variants=(/"PARMFILE"/), &
1405 : description="Specifies the filename that contains the tabulated EAM potential. "// &
1406 : "File structure: the first line of the potential file contains a title. "// &
1407 : "The second line contains: atomic number, mass and lattice constant. "// &
1408 : "These information are parsed but not used in CP2K. The third line contains: "// &
1409 : "dr: increment of r for the tabulated values of density and phi (assuming r starts in 0) [angstrom]; "// &
1410 : "drho: increment of density for the tabulated values of the embedding function (assuming rho starts "// &
1411 : "in 0) [au_c]; cutoff: cutoff of the EAM potential; npoints: number of points in tabulated. Follow "// &
1412 : "in order npoints lines for rho [au_c] and its derivative [au_c*angstrom^-1]; npoints lines for "// &
1413 : "PHI [ev] and its derivative [ev*angstrom^-1] and npoint lines for the embedded function [ev] "// &
1414 : "and its derivative [ev*au_c^-1].", &
1415 16784 : usage="PARM_FILE_NAME {FILENAME}", default_lc_val=" ")
1416 8392 : CALL section_add_keyword(section, keyword)
1417 8392 : CALL keyword_release(keyword)
1418 :
1419 8392 : END SUBROUTINE create_EAM_section
1420 :
1421 : ! **************************************************************************************************
1422 : !> \brief This section specifies the input parameters for QUIP potential type
1423 : !> \param section the section to create
1424 : !> \author teo
1425 : ! **************************************************************************************************
1426 8392 : SUBROUTINE create_QUIP_section(section)
1427 : TYPE(section_type), POINTER :: section
1428 :
1429 : TYPE(keyword_type), POINTER :: keyword
1430 :
1431 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1432 : CALL section_create(section, __LOCATION__, name="QUIP", &
1433 : description="This section specifies the input parameters for QUIP potential type. "// &
1434 : "Mainly intended for things like GAP corrections to DFT "// &
1435 : "to achieve correlated-wavefunction-like accuracy. "// &
1436 : "Requires linking with quip library from <http://www.libatoms.org>.", &
1437 16784 : citations=(/QUIP_ref/), n_keywords=1, n_subsections=0, repeats=.TRUE.)
1438 :
1439 8392 : NULLIFY (keyword)
1440 :
1441 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1442 : description="Defines the atomic kinds involved in the QUIP potential. "// &
1443 : "For more than 2 elements, &QUIP section must be repeated until each element "// &
1444 : "has been mentioned at least once. Set IGNORE_MISSING_CRITICAL_PARAMS to T "// &
1445 : "in enclosing &FORCEFIELD section to avoid having to list every pair of elements separately.", &
1446 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1447 8392 : n_var=2)
1448 8392 : CALL section_add_keyword(section, keyword)
1449 8392 : CALL keyword_release(keyword)
1450 :
1451 : CALL keyword_create(keyword, __LOCATION__, name="PARM_FILE_NAME", &
1452 : variants=(/"PARMFILE"/), &
1453 : description="Specifies the filename that contains the QUIP potential.", &
1454 16784 : usage="PARM_FILE_NAME {FILENAME}", default_lc_val="quip_params.xml")
1455 8392 : CALL section_add_keyword(section, keyword)
1456 8392 : CALL keyword_release(keyword)
1457 :
1458 : CALL keyword_create(keyword, __LOCATION__, name="INIT_ARGS", &
1459 : description="Specifies the potential initialization arguments for the QUIP potential. "// &
1460 : "If blank (default) first potential defined in QUIP parameter file will be used.", &
1461 : usage="INIT_ARGS", default_c_vals=(/""/), &
1462 16784 : n_var=-1, type_of_var=char_t)
1463 8392 : CALL section_add_keyword(section, keyword)
1464 8392 : CALL keyword_release(keyword)
1465 :
1466 : CALL keyword_create(keyword, __LOCATION__, name="CALC_ARGS", &
1467 : description="Specifies the potential calculation arguments for the QUIP potential.", &
1468 : usage="CALC_ARGS", default_c_vals=(/""/), &
1469 16784 : n_var=-1, type_of_var=char_t)
1470 8392 : CALL section_add_keyword(section, keyword)
1471 8392 : CALL keyword_release(keyword)
1472 :
1473 8392 : END SUBROUTINE create_QUIP_section
1474 :
1475 : ! **************************************************************************************************
1476 : !> \brief This section specifies the input parameters for NEQUIP potential type
1477 : !> \param section the section to create
1478 : !> \author teo
1479 : ! **************************************************************************************************
1480 8392 : SUBROUTINE create_NEQUIP_section(section)
1481 : TYPE(section_type), POINTER :: section
1482 :
1483 : TYPE(keyword_type), POINTER :: keyword
1484 :
1485 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1486 : CALL section_create(section, __LOCATION__, name="NEQUIP", &
1487 : description="This section specifies the input parameters for NEQUIP potential type "// &
1488 : "based on equivariant neural networks with message passing. "// &
1489 : "Requires linking with libtorch library from <https://pytorch.org/cppdocs/installing.html>.", &
1490 16784 : citations=(/Batzner2022/), n_keywords=1, n_subsections=0, repeats=.FALSE.)
1491 :
1492 8392 : NULLIFY (keyword)
1493 :
1494 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1495 : description="Defines the atomic kinds involved in the NEQUIP potential. "// &
1496 : "Provide a list of each element, making sure that the mapping from the ATOMS list "// &
1497 : "to NequIP atom types is correct. This mapping should also be consistent for the "// &
1498 : "atomic coordinates as specified in the sections COORDS or TOPOLOGY.", &
1499 : usage="ATOMS {KIND 1} {KIND 2} .. {KIND N}", type_of_var=char_t, &
1500 8392 : n_var=-1)
1501 8392 : CALL section_add_keyword(section, keyword)
1502 8392 : CALL keyword_release(keyword)
1503 :
1504 : CALL keyword_create(keyword, __LOCATION__, name="PARM_FILE_NAME", &
1505 : variants=(/"PARMFILE"/), &
1506 : description="Specifies the filename that contains the NEQUIP model.", &
1507 16784 : usage="PARM_FILE_NAME {FILENAME}", default_lc_val="model.pth")
1508 8392 : CALL section_add_keyword(section, keyword)
1509 8392 : CALL keyword_release(keyword)
1510 :
1511 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_COORDS", &
1512 : description="Units of coordinates in the NEQUIP model.pth file.", &
1513 8392 : usage="UNIT angstrom", default_c_val="angstrom")
1514 8392 : CALL section_add_keyword(section, keyword)
1515 8392 : CALL keyword_release(keyword)
1516 :
1517 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_ENERGY", &
1518 : description="Units of energy in the NEQUIP model.pth file.", &
1519 8392 : usage="UNIT hartree", default_c_val="hartree")
1520 8392 : CALL section_add_keyword(section, keyword)
1521 8392 : CALL keyword_release(keyword)
1522 :
1523 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_FORCES", &
1524 : description="Units of the forces in the NEQUIP model.pth file.", &
1525 8392 : usage="UNIT hartree/bohr", default_c_val="hartree/bohr")
1526 8392 : CALL section_add_keyword(section, keyword)
1527 8392 : CALL keyword_release(keyword)
1528 :
1529 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_CELL", &
1530 : description="Units of the cell vectors in the NEQUIP model.pth file.", &
1531 8392 : usage="UNIT angstrom", default_c_val="angstrom")
1532 8392 : CALL section_add_keyword(section, keyword)
1533 8392 : CALL keyword_release(keyword)
1534 :
1535 8392 : END SUBROUTINE create_NEQUIP_section
1536 :
1537 : ! **************************************************************************************************
1538 : !> \brief This section specifies the input parameters for ALLEGRO potential type
1539 : !> \param section the section to create
1540 : !> \author teo
1541 : ! **************************************************************************************************
1542 8392 : SUBROUTINE create_ALLEGRO_section(section)
1543 : TYPE(section_type), POINTER :: section
1544 :
1545 : TYPE(keyword_type), POINTER :: keyword
1546 :
1547 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1548 : CALL section_create(section, __LOCATION__, name="ALLEGRO", &
1549 : description="This section specifies the input parameters for ALLEGRO potential type "// &
1550 : "based on equivariant neural network potentials. "// &
1551 : "Requires linking with libtorch library from <https://pytorch.org/cppdocs/installing.html>.", &
1552 16784 : citations=(/Musaelian2023/), n_keywords=1, n_subsections=0, repeats=.FALSE.)
1553 :
1554 8392 : NULLIFY (keyword)
1555 :
1556 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1557 : description="Defines the atomic kinds involved in the ALLEGRO potential. "// &
1558 : "Provide a list of each element, making sure that the mapping from the ATOMS list "// &
1559 : "to NequIP atom types is correct. This mapping should also be consistent for the "// &
1560 : "atomic coordinates as specified in the sections COORDS or TOPOLOGY.", &
1561 : usage="ATOMS {KIND 1} {KIND 2} .. {KIND N}", type_of_var=char_t, &
1562 8392 : n_var=-1)
1563 8392 : CALL section_add_keyword(section, keyword)
1564 8392 : CALL keyword_release(keyword)
1565 :
1566 : CALL keyword_create(keyword, __LOCATION__, name="PARM_FILE_NAME", &
1567 : variants=(/"PARMFILE"/), &
1568 : description="Specifies the filename that contains the ALLEGRO model.", &
1569 16784 : usage="PARM_FILE_NAME {FILENAME}", default_lc_val="model.pth")
1570 8392 : CALL section_add_keyword(section, keyword)
1571 8392 : CALL keyword_release(keyword)
1572 :
1573 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_COORDS", &
1574 : description="Units of coordinates in the ALLEGRO model.pth file.", &
1575 8392 : usage="UNIT angstrom", default_c_val="angstrom")
1576 8392 : CALL section_add_keyword(section, keyword)
1577 8392 : CALL keyword_release(keyword)
1578 :
1579 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_ENERGY", &
1580 : description="Units of energy in the ALLEGRO model.pth file.", &
1581 8392 : usage="UNIT hartree", default_c_val="hartree")
1582 8392 : CALL section_add_keyword(section, keyword)
1583 8392 : CALL keyword_release(keyword)
1584 :
1585 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_FORCES", &
1586 : description="Units of the forces in the ALLEGRO model.pth file.", &
1587 8392 : usage="UNIT hartree/bohr", default_c_val="hartree/bohr")
1588 8392 : CALL section_add_keyword(section, keyword)
1589 8392 : CALL keyword_release(keyword)
1590 :
1591 : CALL keyword_create(keyword, __LOCATION__, name="UNIT_CELL", &
1592 : description="Units of the cell vectors in the ALLEGRO model.pth file.", &
1593 8392 : usage="UNIT angstrom", default_c_val="angstrom")
1594 8392 : CALL section_add_keyword(section, keyword)
1595 8392 : CALL keyword_release(keyword)
1596 :
1597 8392 : END SUBROUTINE create_ALLEGRO_section
1598 :
1599 : ! **************************************************************************************************
1600 : !> \brief This section specifies the input parameters for DEEPMD potential type
1601 : !> \param section the section to create
1602 : !> \author ybzhuang
1603 : ! **************************************************************************************************
1604 8392 : SUBROUTINE create_DEEPMD_section(section)
1605 : TYPE(section_type), POINTER :: section
1606 :
1607 : TYPE(keyword_type), POINTER :: keyword
1608 :
1609 : CALL section_create(section, __LOCATION__, name="DEEPMD", &
1610 : description="This section specifies the input parameters for Deep Potential type. "// &
1611 : "Mainly intended for things like neural network to DFT "// &
1612 : "to achieve correlated-wavefunction-like accuracy. "// &
1613 : "Requires linking with DeePMD-kit library from "// &
1614 : "<a href=""https://docs.deepmodeling.com/projects/deepmd/en/master"" "// &
1615 : "target=""_blank"">https://docs.deepmodeling.com/projects/deepmd/en/master</a> .", &
1616 25176 : citations=(/Wang2018, Zeng2023/), n_keywords=1, n_subsections=0, repeats=.FALSE.)
1617 8392 : NULLIFY (keyword)
1618 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1619 : description="Defines the atomic kinds involved in the Deep Potential. "// &
1620 : "Provide a list of each element, "// &
1621 : "making sure that the mapping from the ATOMS list to DeePMD atom types is correct.", &
1622 : usage="ATOMS {KIND 1} {KIND 2} .. {KIND N}", type_of_var=char_t, &
1623 8392 : n_var=-1)
1624 8392 : CALL section_add_keyword(section, keyword)
1625 8392 : CALL keyword_release(keyword)
1626 : CALL keyword_create(keyword, __LOCATION__, name="POT_FILE_NAME", &
1627 : variants=(/"PARMFILE"/), &
1628 : description="Specifies the filename that contains the DeePMD-kit potential.", &
1629 16784 : usage="POT_FILE_NAME {FILENAME}", default_lc_val="graph.pb")
1630 8392 : CALL section_add_keyword(section, keyword)
1631 8392 : CALL keyword_release(keyword)
1632 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS_DEEPMD_TYPE", &
1633 : description="Specifies the atomic TYPE for the DeePMD-kit potential. "// &
1634 : "Provide a list of index, making sure that the mapping "// &
1635 : "from the ATOMS list to DeePMD atom types is correct. ", &
1636 : usage="ATOMS_DEEPMD_TYPE {TYPE INTEGER 1} {TYPE INTEGER 2} .. "// &
1637 : "{TYPE INTEGER N}", type_of_var=integer_t, &
1638 8392 : n_var=-1)
1639 8392 : CALL section_add_keyword(section, keyword)
1640 8392 : CALL keyword_release(keyword)
1641 8392 : END SUBROUTINE create_DEEPMD_section
1642 :
1643 : ! **************************************************************************************************
1644 : !> \brief This section specifies the input parameters for Lennard-Jones potential type
1645 : !> \param section the section to create
1646 : !> \author teo
1647 : ! **************************************************************************************************
1648 33568 : SUBROUTINE create_LJ_section(section)
1649 : TYPE(section_type), POINTER :: section
1650 :
1651 : TYPE(keyword_type), POINTER :: keyword
1652 :
1653 33568 : CPASSERT(.NOT. ASSOCIATED(section))
1654 : CALL section_create(section, __LOCATION__, name="lennard-jones", &
1655 : description="This section specifies the input parameters for LENNARD-JONES potential type. "// &
1656 : "Functional form: V(r) = 4.0 * EPSILON * [(SIGMA/r)^12-(SIGMA/r)^6].", &
1657 33568 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
1658 :
1659 33568 : NULLIFY (keyword)
1660 :
1661 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1662 : description="Defines the atomic kind involved in the nonbond potential", &
1663 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1664 33568 : n_var=2)
1665 33568 : CALL section_add_keyword(section, keyword)
1666 33568 : CALL keyword_release(keyword)
1667 :
1668 : CALL keyword_create(keyword, __LOCATION__, name="EPSILON", &
1669 : description="Defines the EPSILON parameter of the LJ potential", &
1670 : usage="EPSILON {real}", type_of_var=real_t, &
1671 33568 : n_var=1, unit_str="K_e")
1672 33568 : CALL section_add_keyword(section, keyword)
1673 33568 : CALL keyword_release(keyword)
1674 :
1675 : CALL keyword_create(keyword, __LOCATION__, name="SIGMA", &
1676 : description="Defines the SIGMA parameter of the LJ potential", &
1677 : usage="SIGMA {real}", type_of_var=real_t, &
1678 33568 : n_var=1, unit_str="angstrom")
1679 33568 : CALL section_add_keyword(section, keyword)
1680 33568 : CALL keyword_release(keyword)
1681 :
1682 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
1683 : description="Defines the cutoff parameter of the LJ potential", &
1684 : usage="RCUT {real}", default_r_val=cp_unit_to_cp2k(value=10.0_dp, &
1685 : unit_str="angstrom"), &
1686 33568 : unit_str="angstrom")
1687 33568 : CALL section_add_keyword(section, keyword)
1688 33568 : CALL keyword_release(keyword)
1689 :
1690 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
1691 : description="Defines the lower bound of the potential. If not set the range is the"// &
1692 : " full range generate by the spline", usage="RMIN {real}", &
1693 33568 : type_of_var=real_t, unit_str="angstrom")
1694 33568 : CALL section_add_keyword(section, keyword)
1695 33568 : CALL keyword_release(keyword)
1696 :
1697 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
1698 : description="Defines the upper bound of the potential. If not set the range is the"// &
1699 : " full range generate by the spline", usage="RMAX {real}", &
1700 33568 : type_of_var=real_t, unit_str="angstrom")
1701 33568 : CALL section_add_keyword(section, keyword)
1702 33568 : CALL keyword_release(keyword)
1703 :
1704 33568 : END SUBROUTINE create_LJ_section
1705 :
1706 : ! **************************************************************************************************
1707 : !> \brief This section specifies the input parameters for Williams potential type
1708 : !> \param section the section to create
1709 : !> \author teo
1710 : ! **************************************************************************************************
1711 33568 : SUBROUTINE create_Williams_section(section)
1712 : TYPE(section_type), POINTER :: section
1713 :
1714 : TYPE(keyword_type), POINTER :: keyword
1715 :
1716 33568 : CPASSERT(.NOT. ASSOCIATED(section))
1717 : CALL section_create(section, __LOCATION__, name="williams", &
1718 : description="This section specifies the input parameters for WILLIAMS potential type. "// &
1719 : "Functional form: V(r) = A*EXP(-B*r) - C / r^6 .", &
1720 33568 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
1721 :
1722 33568 : NULLIFY (keyword)
1723 :
1724 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1725 : description="Defines the atomic kind involved in the nonbond potential", &
1726 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1727 33568 : n_var=2)
1728 33568 : CALL section_add_keyword(section, keyword)
1729 33568 : CALL keyword_release(keyword)
1730 :
1731 : CALL keyword_create(keyword, __LOCATION__, name="A", &
1732 : description="Defines the A parameter of the Williams potential", &
1733 : usage="A {real}", type_of_var=real_t, &
1734 33568 : n_var=1, unit_str="K_e")
1735 33568 : CALL section_add_keyword(section, keyword)
1736 33568 : CALL keyword_release(keyword)
1737 :
1738 : CALL keyword_create(keyword, __LOCATION__, name="B", &
1739 : description="Defines the B parameter of the Williams potential", &
1740 : usage="B {real}", type_of_var=real_t, &
1741 33568 : n_var=1, unit_str="angstrom^-1")
1742 33568 : CALL section_add_keyword(section, keyword)
1743 33568 : CALL keyword_release(keyword)
1744 :
1745 : CALL keyword_create(keyword, __LOCATION__, name="C", &
1746 : description="Defines the C parameter of the Williams potential", &
1747 : usage="C {real}", type_of_var=real_t, &
1748 33568 : n_var=1, unit_str="K_e*angstrom^6")
1749 33568 : CALL section_add_keyword(section, keyword)
1750 33568 : CALL keyword_release(keyword)
1751 :
1752 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
1753 : description="Defines the cutoff parameter of the Williams potential", &
1754 : usage="RCUT {real}", default_r_val=cp_unit_to_cp2k(value=10.0_dp, &
1755 : unit_str="angstrom"), &
1756 33568 : unit_str="angstrom")
1757 33568 : CALL section_add_keyword(section, keyword)
1758 33568 : CALL keyword_release(keyword)
1759 :
1760 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
1761 : description="Defines the lower bound of the potential. If not set the range is the"// &
1762 : " full range generate by the spline", usage="RMIN {real}", &
1763 33568 : type_of_var=real_t, unit_str="angstrom")
1764 33568 : CALL section_add_keyword(section, keyword)
1765 33568 : CALL keyword_release(keyword)
1766 :
1767 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
1768 : description="Defines the upper bound of the potential. If not set the range is the"// &
1769 : " full range generate by the spline", usage="RMAX {real}", &
1770 33568 : type_of_var=real_t, unit_str="angstrom")
1771 33568 : CALL section_add_keyword(section, keyword)
1772 33568 : CALL keyword_release(keyword)
1773 :
1774 33568 : END SUBROUTINE create_Williams_section
1775 :
1776 : ! **************************************************************************************************
1777 : !> \brief This section specifies the input parameters for Goodwin potential type
1778 : !> \param section the section to create
1779 : !> \author teo
1780 : ! **************************************************************************************************
1781 33568 : SUBROUTINE create_Goodwin_section(section)
1782 : TYPE(section_type), POINTER :: section
1783 :
1784 : TYPE(keyword_type), POINTER :: keyword
1785 :
1786 33568 : CPASSERT(.NOT. ASSOCIATED(section))
1787 : CALL section_create(section, __LOCATION__, name="goodwin", &
1788 : description="This section specifies the input parameters for GOODWIN potential type. "// &
1789 : "Functional form: V(r) = EXP(M*(-(r/DC)**MC+(D/DC)**MC))*VR0*(D/r)**M.", &
1790 33568 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
1791 :
1792 33568 : NULLIFY (keyword)
1793 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1794 : description="Defines the atomic kind involved in the nonbond potential", &
1795 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1796 33568 : n_var=2)
1797 33568 : CALL section_add_keyword(section, keyword)
1798 33568 : CALL keyword_release(keyword)
1799 :
1800 : CALL keyword_create(keyword, __LOCATION__, name="VR0", &
1801 : description="Defines the VR0 parameter of the Goodwin potential", &
1802 : usage="VR0 {real}", type_of_var=real_t, &
1803 33568 : n_var=1, unit_str="K_e")
1804 33568 : CALL section_add_keyword(section, keyword)
1805 33568 : CALL keyword_release(keyword)
1806 :
1807 : CALL keyword_create(keyword, __LOCATION__, name="D", &
1808 : description="Defines the D parameter of the Goodwin potential", &
1809 : usage="D {real}", type_of_var=real_t, &
1810 33568 : n_var=1, unit_str="angstrom")
1811 33568 : CALL section_add_keyword(section, keyword)
1812 33568 : CALL keyword_release(keyword)
1813 :
1814 : CALL keyword_create(keyword, __LOCATION__, name="DC", &
1815 : description="Defines the DC parameter of the Goodwin potential", &
1816 : usage="DC {real}", type_of_var=real_t, &
1817 33568 : n_var=1, unit_str="angstrom")
1818 33568 : CALL section_add_keyword(section, keyword)
1819 33568 : CALL keyword_release(keyword)
1820 :
1821 : CALL keyword_create(keyword, __LOCATION__, name="M", &
1822 : description="Defines the M parameter of the Goodwin potential", &
1823 : usage="M {real}", type_of_var=integer_t, &
1824 33568 : n_var=1)
1825 33568 : CALL section_add_keyword(section, keyword)
1826 33568 : CALL keyword_release(keyword)
1827 :
1828 : CALL keyword_create(keyword, __LOCATION__, name="MC", &
1829 : description="Defines the MC parameter of the Goodwin potential", &
1830 : usage="MC {real}", type_of_var=integer_t, &
1831 33568 : n_var=1)
1832 33568 : CALL section_add_keyword(section, keyword)
1833 33568 : CALL keyword_release(keyword)
1834 :
1835 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
1836 : description="Defines the cutoff parameter of the Goodwin potential", &
1837 : usage="RCUT {real}", default_r_val=cp_unit_to_cp2k(value=10.0_dp, &
1838 : unit_str="angstrom"), &
1839 33568 : unit_str="angstrom")
1840 33568 : CALL section_add_keyword(section, keyword)
1841 33568 : CALL keyword_release(keyword)
1842 :
1843 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
1844 : description="Defines the lower bound of the potential. If not set the range is the"// &
1845 : " full range generate by the spline", usage="RMIN {real}", &
1846 33568 : type_of_var=real_t, unit_str="angstrom")
1847 33568 : CALL section_add_keyword(section, keyword)
1848 33568 : CALL keyword_release(keyword)
1849 :
1850 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
1851 : description="Defines the upper bound of the potential. If not set the range is the"// &
1852 : " full range generate by the spline", usage="RMAX {real}", &
1853 33568 : type_of_var=real_t, unit_str="angstrom")
1854 33568 : CALL section_add_keyword(section, keyword)
1855 33568 : CALL keyword_release(keyword)
1856 :
1857 33568 : END SUBROUTINE create_Goodwin_section
1858 :
1859 : ! **************************************************************************************************
1860 : !> \brief This section specifies the input parameters for IPBV potential type
1861 : !> \param section the section to create
1862 : !> \author teo
1863 : ! **************************************************************************************************
1864 8392 : SUBROUTINE create_ipbv_section(section)
1865 : TYPE(section_type), POINTER :: section
1866 :
1867 : TYPE(keyword_type), POINTER :: keyword
1868 :
1869 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1870 : CALL section_create(section, __LOCATION__, name="ipbv", &
1871 : description="This section specifies the input parameters for IPBV potential type. "// &
1872 : "Functional form: Implicit table function.", &
1873 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
1874 :
1875 8392 : NULLIFY (keyword)
1876 :
1877 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1878 : description="Defines the atomic kind involved in the IPBV nonbond potential", &
1879 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1880 8392 : n_var=2)
1881 8392 : CALL section_add_keyword(section, keyword)
1882 8392 : CALL keyword_release(keyword)
1883 :
1884 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
1885 : description="Defines the cutoff parameter of the IPBV potential", &
1886 : usage="RCUT {real}", default_r_val=cp_unit_to_cp2k(value=10.0_dp, &
1887 : unit_str="angstrom"), &
1888 8392 : unit_str="angstrom")
1889 8392 : CALL section_add_keyword(section, keyword)
1890 8392 : CALL keyword_release(keyword)
1891 :
1892 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
1893 : description="Defines the lower bound of the potential. If not set the range is the"// &
1894 : " full range generate by the spline", usage="RMIN {real}", &
1895 8392 : type_of_var=real_t, unit_str="angstrom")
1896 8392 : CALL section_add_keyword(section, keyword)
1897 8392 : CALL keyword_release(keyword)
1898 :
1899 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
1900 : description="Defines the upper bound of the potential. If not set the range is the"// &
1901 : " full range generate by the spline", usage="RMAX {real}", &
1902 8392 : type_of_var=real_t, unit_str="angstrom")
1903 8392 : CALL section_add_keyword(section, keyword)
1904 8392 : CALL keyword_release(keyword)
1905 :
1906 8392 : END SUBROUTINE create_ipbv_section
1907 :
1908 : ! **************************************************************************************************
1909 : !> \brief This section specifies the input parameters for BMHFT potential type
1910 : !> \param section the section to create
1911 : !> \author teo
1912 : ! **************************************************************************************************
1913 8392 : SUBROUTINE create_BMHFT_section(section)
1914 : TYPE(section_type), POINTER :: section
1915 :
1916 : TYPE(keyword_type), POINTER :: keyword
1917 :
1918 8392 : CPASSERT(.NOT. ASSOCIATED(section))
1919 : CALL section_create(section, __LOCATION__, name="BMHFT", &
1920 : description="This section specifies the input parameters for BMHFT potential type. "// &
1921 : "Functional form: V(r) = A * EXP(-B*r) - C/r^6 - D/r^8. "// &
1922 : "Values available inside cp2k only for the Na/Cl pair.", &
1923 25176 : citations=(/Tosi1964a, Tosi1964b/), n_keywords=1, n_subsections=0, repeats=.TRUE.)
1924 :
1925 8392 : NULLIFY (keyword)
1926 :
1927 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
1928 : description="Defines the atomic kind involved in the BMHFT nonbond potential", &
1929 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1930 8392 : n_var=2)
1931 8392 : CALL section_add_keyword(section, keyword)
1932 8392 : CALL keyword_release(keyword)
1933 :
1934 : CALL keyword_create(keyword, __LOCATION__, name="MAP_ATOMS", &
1935 : description="Defines the kinds for which internally is defined the BMHFT nonbond potential"// &
1936 : " at the moment only Na and Cl.", &
1937 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
1938 8392 : n_var=2)
1939 8392 : CALL section_add_keyword(section, keyword)
1940 8392 : CALL keyword_release(keyword)
1941 :
1942 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
1943 : description="Defines the cutoff parameter of the BMHFT potential", &
1944 : usage="RCUT {real}", default_r_val=7.8_dp, &
1945 8392 : unit_str="angstrom")
1946 8392 : CALL section_add_keyword(section, keyword)
1947 8392 : CALL keyword_release(keyword)
1948 :
1949 : CALL keyword_create(keyword, __LOCATION__, name="A", &
1950 : description="Defines the A parameter of the Fumi-Tosi Potential", &
1951 : usage="A {real}", type_of_var=real_t, &
1952 8392 : n_var=1, unit_str="hartree")
1953 8392 : CALL section_add_keyword(section, keyword)
1954 8392 : CALL keyword_release(keyword)
1955 :
1956 : CALL keyword_create(keyword, __LOCATION__, name="B", &
1957 : description="Defines the B parameter of the Fumi-Tosi Potential", &
1958 : usage="B {real}", type_of_var=real_t, &
1959 8392 : n_var=1, unit_str="angstrom^-1")
1960 8392 : CALL section_add_keyword(section, keyword)
1961 8392 : CALL keyword_release(keyword)
1962 :
1963 : CALL keyword_create(keyword, __LOCATION__, name="C", &
1964 : description="Defines the C parameter of the Fumi-Tosi Potential", &
1965 : usage="C {real}", type_of_var=real_t, &
1966 8392 : n_var=1, unit_str="hartree*angstrom^6")
1967 8392 : CALL section_add_keyword(section, keyword)
1968 8392 : CALL keyword_release(keyword)
1969 :
1970 : CALL keyword_create(keyword, __LOCATION__, name="D", &
1971 : description="Defines the D parameter of the Fumi-Tosi Potential", &
1972 : usage="D {real}", type_of_var=real_t, &
1973 8392 : n_var=1, unit_str="hartree*angstrom^8")
1974 8392 : CALL section_add_keyword(section, keyword)
1975 8392 : CALL keyword_release(keyword)
1976 :
1977 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
1978 : description="Defines the lower bound of the potential. If not set the range is the"// &
1979 : " full range generate by the spline", usage="RMIN {real}", &
1980 8392 : type_of_var=real_t, unit_str="angstrom")
1981 8392 : CALL section_add_keyword(section, keyword)
1982 8392 : CALL keyword_release(keyword)
1983 :
1984 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
1985 : description="Defines the upper bound of the potential. If not set the range is the"// &
1986 : " full range generate by the spline", usage="RMAX {real}", &
1987 8392 : type_of_var=real_t, unit_str="angstrom")
1988 8392 : CALL section_add_keyword(section, keyword)
1989 8392 : CALL keyword_release(keyword)
1990 :
1991 8392 : END SUBROUTINE create_BMHFT_section
1992 :
1993 : ! **************************************************************************************************
1994 : !> \brief This section specifies the input parameters for BMHFTD potential type
1995 : !> \param section the section to create
1996 : !> \par History
1997 : !> - Unused input keyword ORDER removed (18.10.2021, MK)
1998 : !> \author Mathieu Salanne 05.2010
1999 : ! **************************************************************************************************
2000 8392 : SUBROUTINE create_BMHFTD_section(section)
2001 : TYPE(section_type), POINTER :: section
2002 :
2003 : TYPE(keyword_type), POINTER :: keyword
2004 :
2005 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2006 : CALL section_create(section, __LOCATION__, name="BMHFTD", &
2007 : description="This section specifies the input parameters for the BMHFTD potential type. "// &
2008 : "Functional form: V(r) = A*exp(-B*r) - f_6*(r)C/r^6 - f_8(r)*D/r^8 "// &
2009 : "where f_order(r) = 1 - exp(-BD*r)*\sum_{k=0}^order (BD*r)^k/k! "// &
2010 : "(Tang-Toennies damping function). No pre-defined parameter values are available.", &
2011 25176 : citations=(/Tosi1964a, Tosi1964b/), n_keywords=1, n_subsections=0, repeats=.TRUE.)
2012 :
2013 8392 : NULLIFY (keyword)
2014 :
2015 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2016 : description="Defines the atomic kind involved in the BMHFTD nonbond potential", &
2017 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2018 8392 : n_var=2)
2019 8392 : CALL section_add_keyword(section, keyword)
2020 8392 : CALL keyword_release(keyword)
2021 :
2022 : CALL keyword_create(keyword, __LOCATION__, name="MAP_ATOMS", &
2023 : description="Defines the kinds for which internally is defined the BMHFTD nonbond potential"// &
2024 : " at the moment no species included.", &
2025 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2026 8392 : n_var=2)
2027 8392 : CALL section_add_keyword(section, keyword)
2028 8392 : CALL keyword_release(keyword)
2029 :
2030 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
2031 : description="Defines the cutoff parameter of the BMHFTD potential", &
2032 : usage="RCUT {real}", default_r_val=7.8_dp, &
2033 8392 : unit_str="angstrom")
2034 8392 : CALL section_add_keyword(section, keyword)
2035 8392 : CALL keyword_release(keyword)
2036 :
2037 : CALL keyword_create(keyword, __LOCATION__, name="A", &
2038 : description="Defines the A parameter of the dispersion-damped Fumi-Tosi potential", &
2039 : usage="A {real}", type_of_var=real_t, &
2040 8392 : n_var=1, unit_str="hartree")
2041 8392 : CALL section_add_keyword(section, keyword)
2042 8392 : CALL keyword_release(keyword)
2043 :
2044 : CALL keyword_create(keyword, __LOCATION__, name="B", &
2045 : description="Defines the B parameter of the dispersion-damped Fumi-Tosi potential", &
2046 : usage="B {real}", type_of_var=real_t, &
2047 8392 : n_var=1, unit_str="angstrom^-1")
2048 8392 : CALL section_add_keyword(section, keyword)
2049 8392 : CALL keyword_release(keyword)
2050 :
2051 : CALL keyword_create(keyword, __LOCATION__, name="C", &
2052 : description="Defines the C parameter of the dispersion-damped Fumi-Tosi potential", &
2053 : usage="C {real}", type_of_var=real_t, &
2054 8392 : n_var=1, unit_str="hartree*angstrom^6")
2055 8392 : CALL section_add_keyword(section, keyword)
2056 8392 : CALL keyword_release(keyword)
2057 :
2058 : CALL keyword_create(keyword, __LOCATION__, name="D", &
2059 : description="Defines the D parameter of the dispersion-damped Fumi-Tosi potential", &
2060 : usage="D {real}", type_of_var=real_t, &
2061 8392 : n_var=1, unit_str="hartree*angstrom^8")
2062 8392 : CALL section_add_keyword(section, keyword)
2063 8392 : CALL keyword_release(keyword)
2064 :
2065 : CALL keyword_create(keyword, __LOCATION__, name="BD", &
2066 : description="Defines the BD parameters of the dispersion-damped Fumi-Tosi potential. "// &
2067 : "One or two parameter values are expected. If only one value is provided, then this "// &
2068 : "value will be used both for the 6th and the 8th order term.", &
2069 : usage="BD {real} {real}", type_of_var=real_t, &
2070 8392 : n_var=-1, unit_str="angstrom^-1")
2071 8392 : CALL section_add_keyword(section, keyword)
2072 8392 : CALL keyword_release(keyword)
2073 :
2074 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
2075 : description="Defines the lower bound of the potential. If not set the range is the"// &
2076 : " full range generate by the spline", usage="RMIN {real}", &
2077 8392 : type_of_var=real_t, unit_str="angstrom")
2078 8392 : CALL section_add_keyword(section, keyword)
2079 8392 : CALL keyword_release(keyword)
2080 :
2081 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
2082 : description="Defines the upper bound of the potential. If not set the range is the"// &
2083 : " full range generate by the spline", usage="RMAX {real}", &
2084 8392 : type_of_var=real_t, unit_str="angstrom")
2085 8392 : CALL section_add_keyword(section, keyword)
2086 8392 : CALL keyword_release(keyword)
2087 :
2088 8392 : END SUBROUTINE create_BMHFTD_section
2089 :
2090 : ! **************************************************************************************************
2091 : !> \brief This section specifies the input parameters for Buckingham 4 ranges potential type
2092 : !> \param section the section to create
2093 : !> \author MI
2094 : ! **************************************************************************************************
2095 8392 : SUBROUTINE create_Buck4r_section(section)
2096 : TYPE(section_type), POINTER :: section
2097 :
2098 : TYPE(keyword_type), POINTER :: keyword
2099 :
2100 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2101 : CALL section_create(section, __LOCATION__, name="BUCK4RANGES", &
2102 : description="This section specifies the input parameters for the Buckingham 4-ranges"// &
2103 : " potential type."//newline// &
2104 : "| Range | Functional Form |"//newline// &
2105 : "| ----- | --------------- |"//newline// &
2106 : "| $ r < r_1 $ | $ V(r) = A\exp(-Br) $ |"//newline// &
2107 : "| $ r_1 \leq r < r_2 $ | $ V(r) = \sum_n \operatorname{POLY1}(n)r_n $ |"//newline// &
2108 : "| $ r_2 \leq r < r_3 $ | $ V(r) = \sum_n \operatorname{POLY2}(n)r_n $ |"//newline// &
2109 : "| $ r \geq r_3 $ | $ V(r) = -C/r_6 $ |"//newline, &
2110 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
2111 :
2112 8392 : NULLIFY (keyword)
2113 :
2114 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2115 : description="Defines the atomic kind involved in the nonbond potential", &
2116 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2117 8392 : n_var=2)
2118 8392 : CALL section_add_keyword(section, keyword)
2119 8392 : CALL keyword_release(keyword)
2120 :
2121 : CALL keyword_create(keyword, __LOCATION__, name="A", &
2122 : description="Defines the A parameter of the Buckingham potential", &
2123 : usage="A {real}", type_of_var=real_t, &
2124 8392 : n_var=1, unit_str="K_e")
2125 8392 : CALL section_add_keyword(section, keyword)
2126 8392 : CALL keyword_release(keyword)
2127 :
2128 : CALL keyword_create(keyword, __LOCATION__, name="B", &
2129 : description="Defines the B parameter of the Buckingham potential", &
2130 : usage="B {real}", type_of_var=real_t, &
2131 8392 : n_var=1, unit_str="angstrom^-1")
2132 8392 : CALL section_add_keyword(section, keyword)
2133 8392 : CALL keyword_release(keyword)
2134 :
2135 : CALL keyword_create(keyword, __LOCATION__, name="C", &
2136 : description="Defines the C parameter of the Buckingham potential", &
2137 : usage="C {real}", type_of_var=real_t, &
2138 8392 : n_var=1, unit_str="K_e*angstrom^6")
2139 8392 : CALL section_add_keyword(section, keyword)
2140 8392 : CALL keyword_release(keyword)
2141 :
2142 : CALL keyword_create(keyword, __LOCATION__, name="R1", &
2143 : description="Defines the upper bound of the first range ", &
2144 : usage="R1 {real}", type_of_var=real_t, &
2145 8392 : n_var=1, unit_str="angstrom")
2146 8392 : CALL section_add_keyword(section, keyword)
2147 8392 : CALL keyword_release(keyword)
2148 :
2149 : CALL keyword_create(keyword, __LOCATION__, name="R2", &
2150 : description="Defines the upper bound of the second range ", &
2151 : usage="R2 {real}", type_of_var=real_t, &
2152 8392 : n_var=1, unit_str="angstrom")
2153 8392 : CALL section_add_keyword(section, keyword)
2154 8392 : CALL keyword_release(keyword)
2155 :
2156 : CALL keyword_create(keyword, __LOCATION__, name="R3", &
2157 : description="Defines the upper bound of the third range ", &
2158 : usage="R3 {real}", type_of_var=real_t, &
2159 8392 : n_var=1, unit_str="angstrom")
2160 8392 : CALL section_add_keyword(section, keyword)
2161 8392 : CALL keyword_release(keyword)
2162 :
2163 : CALL keyword_create(keyword, __LOCATION__, name="POLY1", &
2164 : description="Coefficients of the polynomial used in the second range "// &
2165 : "This keyword can be repeated several times.", &
2166 : usage="POLY1 C1 C2 C3 ..", &
2167 8392 : n_var=-1, unit_str="K_e", type_of_var=real_t, repeats=.TRUE.)
2168 8392 : CALL section_add_keyword(section, keyword)
2169 8392 : CALL keyword_release(keyword)
2170 :
2171 : CALL keyword_create(keyword, __LOCATION__, name="POLY2", &
2172 : description="Coefficients of the polynomial used in the third range "// &
2173 : "This keyword can be repeated several times.", &
2174 : usage="POLY1 C1 C2 C3 ..", &
2175 8392 : n_var=-1, unit_str="K_e", type_of_var=real_t, repeats=.TRUE.)
2176 8392 : CALL section_add_keyword(section, keyword)
2177 8392 : CALL keyword_release(keyword)
2178 :
2179 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
2180 : description="Defines the cutoff parameter of the Buckingham potential", &
2181 : usage="RCUT {real}", default_r_val=cp_unit_to_cp2k(value=10.0_dp, &
2182 : unit_str="angstrom"), &
2183 8392 : unit_str="angstrom")
2184 8392 : CALL section_add_keyword(section, keyword)
2185 8392 : CALL keyword_release(keyword)
2186 :
2187 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
2188 : description="Defines the lower bound of the potential. If not set the range is the"// &
2189 : " full range generate by the spline", usage="RMIN {real}", &
2190 8392 : type_of_var=real_t, unit_str="angstrom")
2191 8392 : CALL section_add_keyword(section, keyword)
2192 8392 : CALL keyword_release(keyword)
2193 :
2194 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
2195 : description="Defines the upper bound of the potential. If not set the range is the"// &
2196 : " full range generate by the spline", usage="RMAX {real}", &
2197 8392 : type_of_var=real_t, unit_str="angstrom")
2198 8392 : CALL section_add_keyword(section, keyword)
2199 8392 : CALL keyword_release(keyword)
2200 :
2201 8392 : END SUBROUTINE create_Buck4r_section
2202 :
2203 : ! **************************************************************************************************
2204 : !> \brief This section specifies the input parameters for Buckingham + Morse potential type
2205 : !> \param section the section to create
2206 : !> \author MI
2207 : ! **************************************************************************************************
2208 8392 : SUBROUTINE create_Buckmorse_section(section)
2209 : TYPE(section_type), POINTER :: section
2210 :
2211 : TYPE(keyword_type), POINTER :: keyword
2212 :
2213 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2214 : CALL section_create( &
2215 : section, __LOCATION__, name="BUCKMORSE", &
2216 : description="This section specifies the input parameters for"// &
2217 : " Buckingham plus Morse potential type"// &
2218 : " Functional Form: V(r) = F0*(B1+B2)*EXP([A1+A2-r]/[B1+B2])-C/r^6+D*{EXP[-2*beta*(r-R0)]-2*EXP[-beta*(r-R0)]}.", &
2219 16784 : citations=(/Yamada2000/), n_keywords=1, n_subsections=0, repeats=.TRUE.)
2220 :
2221 8392 : NULLIFY (keyword)
2222 :
2223 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2224 : description="Defines the atomic kind involved in the nonbond potential", &
2225 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2226 8392 : n_var=2)
2227 8392 : CALL section_add_keyword(section, keyword)
2228 8392 : CALL keyword_release(keyword)
2229 :
2230 : CALL keyword_create(keyword, __LOCATION__, name="F0", &
2231 : description="Defines the f0 parameter of Buckingham+Morse potential", &
2232 : usage="F0 {real}", type_of_var=real_t, &
2233 8392 : n_var=1, unit_str="K_e*angstrom^-1")
2234 8392 : CALL section_add_keyword(section, keyword)
2235 8392 : CALL keyword_release(keyword)
2236 :
2237 : CALL keyword_create(keyword, __LOCATION__, name="A1", &
2238 : description="Defines the A1 parameter of Buckingham+Morse potential", &
2239 : usage="A1 {real}", type_of_var=real_t, &
2240 8392 : n_var=1, unit_str="angstrom")
2241 8392 : CALL section_add_keyword(section, keyword)
2242 8392 : CALL keyword_release(keyword)
2243 :
2244 : CALL keyword_create(keyword, __LOCATION__, name="A2", &
2245 : description="Defines the A2 parameter of Buckingham+Morse potential", &
2246 : usage="A2 {real}", type_of_var=real_t, &
2247 8392 : n_var=1, unit_str="angstrom")
2248 8392 : CALL section_add_keyword(section, keyword)
2249 8392 : CALL keyword_release(keyword)
2250 :
2251 : CALL keyword_create(keyword, __LOCATION__, name="B1", &
2252 : description="Defines the B1 parameter of Buckingham+Morse potential", &
2253 : usage="B1 {real}", type_of_var=real_t, &
2254 8392 : n_var=1, unit_str="angstrom")
2255 8392 : CALL section_add_keyword(section, keyword)
2256 8392 : CALL keyword_release(keyword)
2257 :
2258 : CALL keyword_create(keyword, __LOCATION__, name="B2", &
2259 : description="Defines the B2 parameter of Buckingham+Morse potential", &
2260 : usage="B2 {real}", type_of_var=real_t, &
2261 8392 : n_var=1, unit_str="angstrom")
2262 8392 : CALL section_add_keyword(section, keyword)
2263 8392 : CALL keyword_release(keyword)
2264 :
2265 : CALL keyword_create(keyword, __LOCATION__, name="C", &
2266 : description="Defines the C parameter of Buckingham+Morse potential", &
2267 : usage="C {real}", type_of_var=real_t, &
2268 8392 : n_var=1, unit_str="K_e*angstrom^6")
2269 8392 : CALL section_add_keyword(section, keyword)
2270 8392 : CALL keyword_release(keyword)
2271 :
2272 : CALL keyword_create(keyword, __LOCATION__, name="D", &
2273 : description="Defines the amplitude for the Morse part ", &
2274 : usage="D {real}", type_of_var=real_t, &
2275 8392 : n_var=1, unit_str="K_e")
2276 8392 : CALL section_add_keyword(section, keyword)
2277 8392 : CALL keyword_release(keyword)
2278 :
2279 : CALL keyword_create(keyword, __LOCATION__, name="R0", &
2280 : description="Defines the equilibrium distance for the Morse part ", &
2281 : usage="R0 {real}", type_of_var=real_t, &
2282 8392 : n_var=1, unit_str="angstrom")
2283 8392 : CALL section_add_keyword(section, keyword)
2284 8392 : CALL keyword_release(keyword)
2285 :
2286 : CALL keyword_create(keyword, __LOCATION__, name="Beta", &
2287 : description="Defines the width for the Morse part ", &
2288 : usage="Beta {real}", type_of_var=real_t, &
2289 8392 : n_var=1, unit_str="angstrom^-1")
2290 8392 : CALL section_add_keyword(section, keyword)
2291 8392 : CALL keyword_release(keyword)
2292 :
2293 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
2294 : description="Defines the cutoff parameter of the Buckingham potential", &
2295 : usage="RCUT {real}", default_r_val=cp_unit_to_cp2k(value=10.0_dp, &
2296 : unit_str="angstrom"), &
2297 8392 : unit_str="angstrom")
2298 8392 : CALL section_add_keyword(section, keyword)
2299 8392 : CALL keyword_release(keyword)
2300 :
2301 : CALL keyword_create(keyword, __LOCATION__, name="RMIN", &
2302 : description="Defines the lower bound of the potential. If not set the range is the"// &
2303 : " full range generate by the spline", usage="RMIN {real}", &
2304 8392 : type_of_var=real_t, unit_str="angstrom")
2305 8392 : CALL section_add_keyword(section, keyword)
2306 8392 : CALL keyword_release(keyword)
2307 :
2308 : CALL keyword_create(keyword, __LOCATION__, name="RMAX", &
2309 : description="Defines the upper bound of the potential. If not set the range is the"// &
2310 : " full range generate by the spline", usage="RMAX {real}", &
2311 8392 : type_of_var=real_t, unit_str="angstrom")
2312 8392 : CALL section_add_keyword(section, keyword)
2313 8392 : CALL keyword_release(keyword)
2314 :
2315 8392 : END SUBROUTINE create_Buckmorse_section
2316 :
2317 : ! **************************************************************************************************
2318 : !> \brief This section specifies the input parameters for Tersoff potential type
2319 : !> (Tersoff, J. PRB 39(8), 5566, 1989)
2320 : !> \param section ...
2321 : ! **************************************************************************************************
2322 8392 : SUBROUTINE create_Tersoff_section(section)
2323 : TYPE(section_type), POINTER :: section
2324 :
2325 : TYPE(keyword_type), POINTER :: keyword
2326 :
2327 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2328 : CALL section_create(section, __LOCATION__, name="TERSOFF", &
2329 : description="This section specifies the input parameters for Tersoff potential type.", &
2330 16784 : citations=(/Tersoff1988/), n_keywords=1, n_subsections=0, repeats=.TRUE.)
2331 :
2332 8392 : NULLIFY (keyword)
2333 :
2334 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2335 : description="Defines the atomic kind involved in the nonbond potential", &
2336 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2337 8392 : n_var=2)
2338 8392 : CALL section_add_keyword(section, keyword)
2339 8392 : CALL keyword_release(keyword)
2340 :
2341 : CALL keyword_create(keyword, __LOCATION__, name="A", &
2342 : description="Defines the A parameter of Tersoff potential", &
2343 : usage="A {real}", type_of_var=real_t, &
2344 : default_r_val=cp_unit_to_cp2k(value=1.8308E3_dp, &
2345 : unit_str="eV"), &
2346 8392 : n_var=1, unit_str="eV")
2347 8392 : CALL section_add_keyword(section, keyword)
2348 8392 : CALL keyword_release(keyword)
2349 :
2350 : CALL keyword_create(keyword, __LOCATION__, name="B", &
2351 : description="Defines the B parameter of Tersoff potential", &
2352 : usage="B {real}", type_of_var=real_t, &
2353 : default_r_val=cp_unit_to_cp2k(value=4.7118E2_dp, &
2354 : unit_str="eV"), &
2355 8392 : n_var=1, unit_str="eV")
2356 8392 : CALL section_add_keyword(section, keyword)
2357 8392 : CALL keyword_release(keyword)
2358 :
2359 : CALL keyword_create(keyword, __LOCATION__, name="lambda1", &
2360 : description="Defines the lambda1 parameter of Tersoff potential", &
2361 : usage="lambda1 {real}", type_of_var=real_t, &
2362 : default_r_val=cp_unit_to_cp2k(value=2.4799_dp, &
2363 : unit_str="angstrom^-1"), &
2364 8392 : n_var=1, unit_str="angstrom^-1")
2365 8392 : CALL section_add_keyword(section, keyword)
2366 8392 : CALL keyword_release(keyword)
2367 :
2368 : CALL keyword_create(keyword, __LOCATION__, name="lambda2", &
2369 : description="Defines the lambda2 parameter of Tersoff potential", &
2370 : usage="lambda2 {real}", type_of_var=real_t, &
2371 : default_r_val=cp_unit_to_cp2k(value=1.7322_dp, &
2372 : unit_str="angstrom^-1"), &
2373 8392 : n_var=1, unit_str="angstrom^-1")
2374 8392 : CALL section_add_keyword(section, keyword)
2375 8392 : CALL keyword_release(keyword)
2376 :
2377 : CALL keyword_create(keyword, __LOCATION__, name="alpha", &
2378 : description="Defines the alpha parameter of Tersoff potential", &
2379 : usage="alpha {real}", type_of_var=real_t, &
2380 : default_r_val=0.0_dp, &
2381 8392 : n_var=1)
2382 8392 : CALL section_add_keyword(section, keyword)
2383 8392 : CALL keyword_release(keyword)
2384 :
2385 : CALL keyword_create(keyword, __LOCATION__, name="beta", &
2386 : description="Defines the beta parameter of Tersoff potential", &
2387 : usage="beta {real}", type_of_var=real_t, &
2388 : default_r_val=1.0999E-6_dp, &
2389 8392 : n_var=1, unit_str="")
2390 8392 : CALL section_add_keyword(section, keyword)
2391 8392 : CALL keyword_release(keyword)
2392 :
2393 : CALL keyword_create(keyword, __LOCATION__, name="n", &
2394 : description="Defines the n parameter of Tersoff potential", &
2395 : usage="n {real}", type_of_var=real_t, &
2396 : default_r_val=7.8734E-1_dp, &
2397 8392 : n_var=1, unit_str="")
2398 8392 : CALL section_add_keyword(section, keyword)
2399 8392 : CALL keyword_release(keyword)
2400 :
2401 : CALL keyword_create(keyword, __LOCATION__, name="c", &
2402 : description="Defines the c parameter of Tersoff potential", &
2403 : usage="c {real}", type_of_var=real_t, &
2404 : default_r_val=1.0039E5_dp, &
2405 8392 : n_var=1, unit_str="")
2406 8392 : CALL section_add_keyword(section, keyword)
2407 8392 : CALL keyword_release(keyword)
2408 :
2409 : CALL keyword_create(keyword, __LOCATION__, name="d", &
2410 : description="Defines the d parameter of Tersoff potential", &
2411 : usage="d {real}", type_of_var=real_t, &
2412 : default_r_val=1.6218E1_dp, &
2413 8392 : n_var=1, unit_str="")
2414 8392 : CALL section_add_keyword(section, keyword)
2415 8392 : CALL keyword_release(keyword)
2416 :
2417 : CALL keyword_create(keyword, __LOCATION__, name="h", &
2418 : description="Defines the h parameter of Tersoff potential", &
2419 : usage="h {real}", type_of_var=real_t, &
2420 : default_r_val=-5.9826E-1_dp, &
2421 8392 : n_var=1, unit_str="")
2422 8392 : CALL section_add_keyword(section, keyword)
2423 8392 : CALL keyword_release(keyword)
2424 :
2425 : CALL keyword_create(keyword, __LOCATION__, name="lambda3", &
2426 : description="Defines the lambda3 parameter of Tersoff potential", &
2427 : usage="lambda3 {real}", type_of_var=real_t, &
2428 : default_r_val=cp_unit_to_cp2k(value=1.7322_dp, &
2429 : unit_str="angstrom^-1"), &
2430 8392 : n_var=1, unit_str="angstrom^-1")
2431 8392 : CALL section_add_keyword(section, keyword)
2432 8392 : CALL keyword_release(keyword)
2433 :
2434 : CALL keyword_create(keyword, __LOCATION__, name="bigR", &
2435 : description="Defines the bigR parameter of Tersoff potential", &
2436 : usage="bigR {real}", type_of_var=real_t, &
2437 : default_r_val=cp_unit_to_cp2k(value=2.85_dp, &
2438 : unit_str="angstrom"), &
2439 8392 : n_var=1, unit_str="angstrom")
2440 8392 : CALL section_add_keyword(section, keyword)
2441 8392 : CALL keyword_release(keyword)
2442 :
2443 : CALL keyword_create(keyword, __LOCATION__, name="bigD", &
2444 : description="Defines the D parameter of Tersoff potential", &
2445 : usage="bigD {real}", type_of_var=real_t, &
2446 : default_r_val=cp_unit_to_cp2k(value=0.15_dp, &
2447 : unit_str="angstrom"), &
2448 8392 : n_var=1, unit_str="angstrom")
2449 8392 : CALL section_add_keyword(section, keyword)
2450 8392 : CALL keyword_release(keyword)
2451 :
2452 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
2453 : description="Defines the cutoff parameter of the tersoff potential."// &
2454 : " This parameter is in principle already defined by the values of"// &
2455 : " bigD and bigR. But it is necessary to define it when using the tersoff"// &
2456 : " in conjunction with other potentials (for the same atomic pair) in order to have"// &
2457 : " the same consistent definition of RCUT for all potentials.", &
2458 : usage="RCUT {real}", type_of_var=real_t, &
2459 8392 : n_var=1, unit_str="angstrom")
2460 8392 : CALL section_add_keyword(section, keyword)
2461 8392 : CALL keyword_release(keyword)
2462 :
2463 8392 : END SUBROUTINE create_Tersoff_section
2464 :
2465 : ! **************************************************************************************************
2466 : !> \brief This section specifies the input parameters for Siepmann-Sprik
2467 : !> potential type
2468 : !> (Siepmann and Sprik, J. Chem. Phys. 102(1) 511, 1995)
2469 : !> \param section ...
2470 : ! **************************************************************************************************
2471 8392 : SUBROUTINE create_Siepmann_section(section)
2472 : TYPE(section_type), POINTER :: section
2473 :
2474 : TYPE(keyword_type), POINTER :: keyword
2475 :
2476 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2477 : CALL section_create(section, __LOCATION__, name="SIEPMANN", &
2478 : description="This section specifies the input parameters for the"// &
2479 : " Siepmann-Sprik potential type. Consists of 4 terms:"// &
2480 : " T1+T2+T3+T4. The terms T1=A/rij^alpha and T2=-C/rij^6"// &
2481 : " have to be given via the GENPOT section. The terms T3+T4"// &
2482 : " are obtained from the SIEPMANN section. The Siepmann-Sprik"// &
2483 : " potential is designed for water-metal chemisorption.", &
2484 16784 : citations=(/Siepmann1995/), n_keywords=1, n_subsections=0, repeats=.TRUE.)
2485 :
2486 8392 : NULLIFY (keyword)
2487 :
2488 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2489 : description="Defines the atomic kind involved in the nonbond potential", &
2490 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2491 8392 : n_var=2)
2492 8392 : CALL section_add_keyword(section, keyword)
2493 8392 : CALL keyword_release(keyword)
2494 :
2495 : CALL keyword_create(keyword, __LOCATION__, name="B", &
2496 : description="Defines the B parameter of Siepmann potential", &
2497 : usage="B {real}", type_of_var=real_t, &
2498 : default_r_val=cp_unit_to_cp2k(value=0.6_dp, &
2499 : unit_str="angstrom"), &
2500 8392 : n_var=1, unit_str="angstrom")
2501 8392 : CALL section_add_keyword(section, keyword)
2502 8392 : CALL keyword_release(keyword)
2503 :
2504 : CALL keyword_create(keyword, __LOCATION__, name="D", &
2505 : description="Defines the D parameter of Siepmann potential", &
2506 : usage="D {real}", type_of_var=real_t, &
2507 : default_r_val=cp_unit_to_cp2k(value=3.688388_dp, &
2508 : unit_str="internal_cp2k"), &
2509 8392 : n_var=1, unit_str="internal_cp2k")
2510 8392 : CALL section_add_keyword(section, keyword)
2511 8392 : CALL keyword_release(keyword)
2512 :
2513 : CALL keyword_create(keyword, __LOCATION__, name="E", &
2514 : description="Defines the E parameter of Siepmann potential", &
2515 : usage="E {real}", type_of_var=real_t, &
2516 : default_r_val=cp_unit_to_cp2k(value=9.069025_dp, &
2517 : unit_str="internal_cp2k"), &
2518 8392 : n_var=1, unit_str="internal_cp2k")
2519 8392 : CALL section_add_keyword(section, keyword)
2520 8392 : CALL keyword_release(keyword)
2521 :
2522 : CALL keyword_create(keyword, __LOCATION__, name="F", &
2523 : description="Defines the F parameter of Siepmann potential", &
2524 : usage="B {real}", type_of_var=real_t, &
2525 8392 : default_r_val=13.3_dp, n_var=1)
2526 8392 : CALL section_add_keyword(section, keyword)
2527 8392 : CALL keyword_release(keyword)
2528 : !
2529 : CALL keyword_create(keyword, __LOCATION__, name="beta", &
2530 : description="Defines the beta parameter of Siepmann potential", &
2531 : usage="beta {real}", type_of_var=real_t, &
2532 8392 : default_r_val=10.0_dp, n_var=1)
2533 8392 : CALL section_add_keyword(section, keyword)
2534 8392 : CALL keyword_release(keyword)
2535 : !
2536 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
2537 : description="Defines the cutoff parameter of Siepmann potential", &
2538 : usage="RCUT {real}", type_of_var=real_t, &
2539 : default_r_val=cp_unit_to_cp2k(value=3.2_dp, &
2540 : unit_str="angstrom"), &
2541 8392 : n_var=1, unit_str="angstrom")
2542 8392 : CALL section_add_keyword(section, keyword)
2543 8392 : CALL keyword_release(keyword)
2544 : !
2545 : CALL keyword_create(keyword, __LOCATION__, name="ALLOW_OH_FORMATION", &
2546 : description=" The Siepmann-Sprik potential is actually designed for intact"// &
2547 : " water molecules only. If water is treated at the QM level,"// &
2548 : " water molecules can potentially dissociate, i.e."// &
2549 : " some O-H bonds might be stretched leading temporarily"// &
2550 : " to the formation of OH- ions. This keyword allows the"// &
2551 : " the formation of such ions. The T3 term (dipole term)"// &
2552 : " is then switched off for evaluating the interaction"// &
2553 : " between the OH- ion and the metal.", &
2554 : usage="ALLOW_OH_FORMATION TRUE", &
2555 8392 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2556 8392 : CALL section_add_keyword(section, keyword)
2557 8392 : CALL keyword_release(keyword)
2558 :
2559 : CALL keyword_create(keyword, __LOCATION__, name="ALLOW_H3O_FORMATION", &
2560 : description=" The Siepmann-Sprik potential is designed for intact water"// &
2561 : " molecules only. If water is treated at the QM level"// &
2562 : " and an acid is present, hydronium ions might occur."// &
2563 : " This keyword allows the formation of hydronium ions."// &
2564 : " The T3 term (dipole term) is switched off for evaluating"// &
2565 : " the interaction between hydronium and the metal.", &
2566 : usage="ALLOW_H3O_FORMATION TRUE", &
2567 8392 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2568 8392 : CALL section_add_keyword(section, keyword)
2569 8392 : CALL keyword_release(keyword)
2570 :
2571 : CALL keyword_create(keyword, __LOCATION__, name="ALLOW_O_FORMATION", &
2572 : description=" The Siepmann-Sprik potential is actually designed for intact"// &
2573 : " water molecules only. If water is treated at the QM level,"// &
2574 : " water molecules can potentially dissociate, i.e."// &
2575 : " some O-H bonds might be stretched leading temporarily"// &
2576 : " to the formation of O^2- ions. This keyword allows the"// &
2577 : " the formation of such ions. The T3 term (dipole term)"// &
2578 : " is then switched off for evaluating the interaction"// &
2579 : " between the O^2- ion and the metal.", &
2580 : usage="ALLOW_O2-_FORMATION TRUE", &
2581 8392 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2582 8392 : CALL section_add_keyword(section, keyword)
2583 8392 : CALL keyword_release(keyword)
2584 :
2585 8392 : END SUBROUTINE create_Siepmann_section
2586 :
2587 : ! **************************************************************************************************
2588 : !> \brief This section specifies the input parameters for GAL19
2589 : !> potential type
2590 : !> (??)
2591 : !> \param section ...
2592 : ! **************************************************************************************************
2593 8392 : SUBROUTINE create_Gal_section(section)
2594 : TYPE(section_type), POINTER :: section
2595 :
2596 : TYPE(keyword_type), POINTER :: keyword
2597 : TYPE(section_type), POINTER :: subsection
2598 :
2599 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2600 : CALL section_create(section, __LOCATION__, name="GAL19", &
2601 : description="Implementation of the GAL19 forcefield, see associated paper", &
2602 16784 : citations=(/Clabaut2020/), n_keywords=1, n_subsections=1, repeats=.TRUE.)
2603 :
2604 8392 : NULLIFY (keyword, subsection)
2605 :
2606 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2607 : description="Defines the atomic kind involved in the nonbond potential", &
2608 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2609 8392 : n_var=2)
2610 8392 : CALL section_add_keyword(section, keyword)
2611 8392 : CALL keyword_release(keyword)
2612 :
2613 : CALL keyword_create(keyword, __LOCATION__, name="METALS", &
2614 : description="Defines the two atomic kinds to be considered as part of the metallic phase in the system", &
2615 : usage="METALS {KIND1} {KIND2} ..", type_of_var=char_t, &
2616 8392 : n_var=2)
2617 8392 : CALL section_add_keyword(section, keyword)
2618 8392 : CALL keyword_release(keyword)
2619 :
2620 : CALL keyword_create(keyword, __LOCATION__, name="epsilon", &
2621 : description="Defines the epsilon_a parameter of GAL19 potential", &
2622 : usage="epsilon {real}", type_of_var=real_t, &
2623 : default_r_val=cp_unit_to_cp2k(value=0.6_dp, &
2624 : unit_str="kcalmol"), &
2625 8392 : n_var=1, unit_str="kcalmol")
2626 8392 : CALL section_add_keyword(section, keyword)
2627 8392 : CALL keyword_release(keyword)
2628 :
2629 : CALL keyword_create(keyword, __LOCATION__, name="bxy", &
2630 : description="Defines the b perpendicular parameter of GAL19 potential", &
2631 : usage="bxy {real}", type_of_var=real_t, &
2632 : default_r_val=cp_unit_to_cp2k(value=3.688388_dp, &
2633 : unit_str="internal_cp2k"), &
2634 8392 : n_var=1, unit_str="angstrom^-2")
2635 8392 : CALL section_add_keyword(section, keyword)
2636 8392 : CALL keyword_release(keyword)
2637 :
2638 : CALL keyword_create(keyword, __LOCATION__, name="bz", &
2639 : description="Defines the b parallel parameter of GAL19 potential", &
2640 : usage="bz {real}", type_of_var=real_t, &
2641 : default_r_val=cp_unit_to_cp2k(value=9.069025_dp, &
2642 : unit_str="internal_cp2k"), &
2643 8392 : n_var=1, unit_str="angstrom^-2")
2644 8392 : CALL section_add_keyword(section, keyword)
2645 8392 : CALL keyword_release(keyword)
2646 :
2647 : CALL keyword_create(keyword, __LOCATION__, name="r", &
2648 : description="Defines the R_0 parameters of GAL19 potential for the two METALS. "// &
2649 : "This is the only parameter that is shared between the two section of the "// &
2650 : "forcefield in the case of two metals (alloy). "// &
2651 : "If one metal only is present, a second number should be given but won't be read", &
2652 8392 : usage="r {real} {real}", type_of_var=real_t, n_var=2, unit_str="angstrom")
2653 8392 : CALL section_add_keyword(section, keyword)
2654 8392 : CALL keyword_release(keyword)
2655 :
2656 : CALL keyword_create(keyword, __LOCATION__, name="a1", &
2657 : description="Defines the a1 parameter of GAL19 potential", &
2658 : usage="a1 {real}", type_of_var=real_t, &
2659 8392 : default_r_val=10.0_dp, n_var=1, unit_str="kcalmol")
2660 8392 : CALL section_add_keyword(section, keyword)
2661 8392 : CALL keyword_release(keyword)
2662 :
2663 : CALL keyword_create(keyword, __LOCATION__, name="a2", &
2664 : description="Defines the a2 parameter of GAL19 potential", &
2665 : usage="a2 {real}", type_of_var=real_t, &
2666 8392 : default_r_val=10.0_dp, n_var=1, unit_str="kcalmol")
2667 8392 : CALL section_add_keyword(section, keyword)
2668 8392 : CALL keyword_release(keyword)
2669 :
2670 : CALL keyword_create(keyword, __LOCATION__, name="a3", &
2671 : description="Defines the a3 parameter of GAL19 potential", &
2672 : usage="a3 {real}", type_of_var=real_t, &
2673 8392 : default_r_val=10.0_dp, n_var=1, unit_str="kcalmol")
2674 8392 : CALL section_add_keyword(section, keyword)
2675 8392 : CALL keyword_release(keyword)
2676 :
2677 : CALL keyword_create(keyword, __LOCATION__, name="a4", &
2678 : description="Defines the a4 parameter of GAL19 potential", &
2679 : usage="a4 {real}", type_of_var=real_t, &
2680 8392 : default_r_val=10.0_dp, n_var=1, unit_str="kcalmol")
2681 8392 : CALL section_add_keyword(section, keyword)
2682 8392 : CALL keyword_release(keyword)
2683 :
2684 : CALL keyword_create(keyword, __LOCATION__, name="A", &
2685 : description="Defines the A parameter of GAL19 potential", &
2686 : usage="A {real}", type_of_var=real_t, &
2687 8392 : default_r_val=10.0_dp, n_var=1, unit_str="kcalmol")
2688 8392 : CALL section_add_keyword(section, keyword)
2689 8392 : CALL keyword_release(keyword)
2690 :
2691 : CALL keyword_create(keyword, __LOCATION__, name="B", &
2692 : description="Defines the B parameter of GAL19 potential", &
2693 : usage="B {real}", type_of_var=real_t, &
2694 8392 : default_r_val=10.0_dp, n_var=1, unit_str="angstrom^-1")
2695 8392 : CALL section_add_keyword(section, keyword)
2696 8392 : CALL keyword_release(keyword)
2697 :
2698 : CALL keyword_create(keyword, __LOCATION__, name="C", &
2699 : description="Defines the C parameter of GAL19 potential", &
2700 : usage="C {real}", type_of_var=real_t, &
2701 8392 : default_r_val=10.0_dp, n_var=1, unit_str="angstrom^6*kcalmol")
2702 8392 : CALL section_add_keyword(section, keyword)
2703 8392 : CALL keyword_release(keyword)
2704 :
2705 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
2706 : description="Defines the cutoff parameter of GAL19 potential", &
2707 : usage="RCUT {real}", type_of_var=real_t, &
2708 : default_r_val=cp_unit_to_cp2k(value=3.2_dp, &
2709 : unit_str="angstrom"), &
2710 8392 : n_var=1, unit_str="angstrom")
2711 8392 : CALL section_add_keyword(section, keyword)
2712 8392 : CALL keyword_release(keyword)
2713 : CALL keyword_create(keyword, __LOCATION__, name="Fit_express", &
2714 : description="Demands the particular output needed to a least square fit", &
2715 : usage="Fit_express TRUE", &
2716 8392 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2717 8392 : CALL section_add_keyword(section, keyword)
2718 8392 : CALL keyword_release(keyword)
2719 8392 : CALL create_GCN_section(subsection)
2720 8392 : CALL section_add_subsection(section, subsection)
2721 8392 : CALL section_release(subsection)
2722 :
2723 8392 : END SUBROUTINE create_Gal_section
2724 :
2725 : ! **************************************************************************************************
2726 : !> \brief This section specifies the input parameters for GAL21
2727 : !> potential type
2728 : !> (??)
2729 : !> \param section ...
2730 : ! **************************************************************************************************
2731 8392 : SUBROUTINE create_Gal21_section(section)
2732 : TYPE(section_type), POINTER :: section
2733 :
2734 : TYPE(keyword_type), POINTER :: keyword
2735 : TYPE(section_type), POINTER :: subsection
2736 :
2737 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2738 : CALL section_create(section, __LOCATION__, name="GAL21", &
2739 : description="Implementation of the GAL21 forcefield, see associated paper", &
2740 16784 : citations=(/Clabaut2021/), n_keywords=1, n_subsections=1, repeats=.TRUE.)
2741 :
2742 8392 : NULLIFY (keyword, subsection)
2743 :
2744 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2745 : description="Defines the atomic kind involved in the nonbond potential", &
2746 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2747 8392 : n_var=2)
2748 8392 : CALL section_add_keyword(section, keyword)
2749 8392 : CALL keyword_release(keyword)
2750 :
2751 : CALL keyword_create(keyword, __LOCATION__, name="METALS", &
2752 : description="Defines the two atomic kinds to be considered as part of the metallic phase in the system", &
2753 : usage="METALS {KIND1} {KIND2} ..", type_of_var=char_t, &
2754 8392 : n_var=2)
2755 8392 : CALL section_add_keyword(section, keyword)
2756 8392 : CALL keyword_release(keyword)
2757 :
2758 : CALL keyword_create(keyword, __LOCATION__, name="epsilon", &
2759 : description="Defines the epsilon parameter of GAL21 potential", &
2760 : usage="epsilon {real} {real} {real}", type_of_var=real_t, &
2761 8392 : n_var=3, unit_str="kcalmol")
2762 8392 : CALL section_add_keyword(section, keyword)
2763 8392 : CALL keyword_release(keyword)
2764 :
2765 : CALL keyword_create(keyword, __LOCATION__, name="bxy", &
2766 : description="Defines the b perpendicular parameter of GAL21 potential", &
2767 : usage="bxy {real} {real}", type_of_var=real_t, &
2768 8392 : n_var=2, unit_str="angstrom^-2")
2769 8392 : CALL section_add_keyword(section, keyword)
2770 8392 : CALL keyword_release(keyword)
2771 :
2772 : CALL keyword_create(keyword, __LOCATION__, name="bz", &
2773 : description="Defines the b parallel parameter of GAL21 potential", &
2774 : usage="bz {real} {real}", type_of_var=real_t, &
2775 8392 : n_var=2, unit_str="angstrom^-2")
2776 8392 : CALL section_add_keyword(section, keyword)
2777 8392 : CALL keyword_release(keyword)
2778 :
2779 : CALL keyword_create(keyword, __LOCATION__, name="r", &
2780 : description="Defines the R_0 parameters of GAL21 potential for the two METALS. "// &
2781 : "This is the only parameter that is shared between the two section of "// &
2782 : "the forcefield in the case of two metals (alloy). "// &
2783 : "If one metal only is present, a second number should be given but won't be read", &
2784 8392 : usage="r {real} {real}", type_of_var=real_t, n_var=2, unit_str="angstrom")
2785 8392 : CALL section_add_keyword(section, keyword)
2786 8392 : CALL keyword_release(keyword)
2787 :
2788 : CALL keyword_create(keyword, __LOCATION__, name="a1", &
2789 : description="Defines the a1 parameter of GAL21 potential", &
2790 : usage="a1 {real} {real} {real}", type_of_var=real_t, &
2791 8392 : n_var=3, unit_str="kcalmol")
2792 8392 : CALL section_add_keyword(section, keyword)
2793 8392 : CALL keyword_release(keyword)
2794 :
2795 : CALL keyword_create(keyword, __LOCATION__, name="a2", &
2796 : description="Defines the a2 parameter of GAL21 potential", &
2797 : usage="a2 {real} {real} {real}", type_of_var=real_t, &
2798 8392 : n_var=3, unit_str="kcalmol")
2799 8392 : CALL section_add_keyword(section, keyword)
2800 8392 : CALL keyword_release(keyword)
2801 :
2802 : CALL keyword_create(keyword, __LOCATION__, name="a3", &
2803 : description="Defines the a3 parameter of GAL21 potential", &
2804 : usage="a3 {real} {real} {real}", type_of_var=real_t, &
2805 8392 : n_var=3, unit_str="kcalmol")
2806 8392 : CALL section_add_keyword(section, keyword)
2807 8392 : CALL keyword_release(keyword)
2808 :
2809 : CALL keyword_create(keyword, __LOCATION__, name="a4", &
2810 : description="Defines the a4 parameter of GAL21 potential", &
2811 : usage="a4 {real} {real} {real}", type_of_var=real_t, &
2812 8392 : n_var=3, unit_str="kcalmol")
2813 8392 : CALL section_add_keyword(section, keyword)
2814 8392 : CALL keyword_release(keyword)
2815 :
2816 : CALL keyword_create(keyword, __LOCATION__, name="A", &
2817 : description="Defines the A parameter of GAL21 potential", &
2818 : usage="A {real} {real}", type_of_var=real_t, &
2819 8392 : n_var=2, unit_str="kcalmol")
2820 8392 : CALL section_add_keyword(section, keyword)
2821 8392 : CALL keyword_release(keyword)
2822 :
2823 : CALL keyword_create(keyword, __LOCATION__, name="B", &
2824 : description="Defines the B parameter of GAL21 potential", &
2825 : usage="B {real} {real}", type_of_var=real_t, &
2826 8392 : n_var=2, unit_str="angstrom^-1")
2827 8392 : CALL section_add_keyword(section, keyword)
2828 8392 : CALL keyword_release(keyword)
2829 :
2830 : CALL keyword_create(keyword, __LOCATION__, name="C", &
2831 : description="Defines the C parameter of GAL21 potential", &
2832 : usage="C {real}", type_of_var=real_t, &
2833 8392 : n_var=1, unit_str="angstrom^6*kcalmol")
2834 8392 : CALL section_add_keyword(section, keyword)
2835 8392 : CALL keyword_release(keyword)
2836 :
2837 : CALL keyword_create(keyword, __LOCATION__, name="AH", &
2838 : description="Defines the AH parameter of GAL21 potential", &
2839 : usage="AH {real} {real}", type_of_var=real_t, &
2840 8392 : n_var=2, unit_str="kcalmol")
2841 8392 : CALL section_add_keyword(section, keyword)
2842 8392 : CALL keyword_release(keyword)
2843 :
2844 : CALL keyword_create(keyword, __LOCATION__, name="BH", &
2845 : description="Defines the BH parameter of GAL21 potential", &
2846 : usage="BH {real} {real}", type_of_var=real_t, &
2847 8392 : n_var=2, unit_str="angstrom^-1")
2848 8392 : CALL section_add_keyword(section, keyword)
2849 8392 : CALL keyword_release(keyword)
2850 :
2851 : CALL keyword_create(keyword, __LOCATION__, name="RCUT", &
2852 : description="Defines the cutoff parameter of GAL21 potential", &
2853 : usage="RCUT {real}", type_of_var=real_t, &
2854 : default_r_val=cp_unit_to_cp2k(value=3.2_dp, &
2855 : unit_str="angstrom"), &
2856 8392 : n_var=1, unit_str="angstrom")
2857 8392 : CALL section_add_keyword(section, keyword)
2858 8392 : CALL keyword_release(keyword)
2859 :
2860 : CALL keyword_create(keyword, __LOCATION__, name="Fit_express", &
2861 : description="Demands the particular output needed to a least square fit", &
2862 : usage="Fit_express TRUE", &
2863 8392 : default_l_val=.FALSE., lone_keyword_l_val=.TRUE.)
2864 8392 : CALL section_add_keyword(section, keyword)
2865 8392 : CALL keyword_release(keyword)
2866 :
2867 8392 : CALL create_GCN_section(subsection)
2868 8392 : CALL section_add_subsection(section, subsection)
2869 8392 : CALL section_release(subsection)
2870 :
2871 8392 : END SUBROUTINE create_Gal21_section
2872 :
2873 : ! **************************************************************************************************
2874 : !> \brief This section specifies the input parameters for TABPOT potential type
2875 : !> \param section the section to create
2876 : !> \author teo, Alex Mironenko, Da Teng
2877 : ! **************************************************************************************************
2878 8392 : SUBROUTINE create_TABPOT_section(section)
2879 :
2880 : TYPE(section_type), POINTER :: section
2881 :
2882 : TYPE(keyword_type), POINTER :: keyword
2883 :
2884 8392 : CPASSERT(.NOT. ASSOCIATED(section))
2885 :
2886 : CALL section_create(section, __LOCATION__, name="TABPOT", &
2887 : description="This section specifies the input parameters for TABPOT potential type.", &
2888 8392 : n_keywords=1, n_subsections=0, repeats=.TRUE.)
2889 :
2890 8392 : NULLIFY (keyword)
2891 : CALL keyword_create(keyword, __LOCATION__, name="ATOMS", &
2892 : description="Defines the atomic kind involved", &
2893 : usage="ATOMS {KIND1} {KIND2}", type_of_var=char_t, &
2894 8392 : n_var=2)
2895 8392 : CALL section_add_keyword(section, keyword)
2896 8392 : CALL keyword_release(keyword)
2897 :
2898 : CALL keyword_create(keyword, __LOCATION__, name="PARM_FILE_NAME", &
2899 : variants=(/"PARMFILE"/), &
2900 : description="Specifies the filename that contains the tabulated NONBONDED potential. "// &
2901 : "File structure: the third line of the potential file contains a title. "// &
2902 : "The 4th line contains: 'N', number of data points, 'R', lower bound of distance, distance cutoff. "// &
2903 : "Follow "// &
2904 : "in order npoints lines for index, distance [A], energy [kcal/mol], and force [kcal/mol/A]", &
2905 16784 : usage="PARM_FILE_NAME {FILENAME}", default_lc_val="")
2906 8392 : CALL section_add_keyword(section, keyword)
2907 8392 : CALL keyword_release(keyword)
2908 :
2909 8392 : END SUBROUTINE create_TABPOT_section
2910 :
2911 : ! **************************************************************************************************
2912 : !> \brief This section specifies the input parameters for the subsection GCN of GAL19 and GAL21
2913 : !> potential type
2914 : !> (??)
2915 : !> \param section ...
2916 : ! **************************************************************************************************
2917 16784 : SUBROUTINE create_GCN_section(section)
2918 : TYPE(section_type), POINTER :: section
2919 :
2920 : TYPE(keyword_type), POINTER :: keyword
2921 :
2922 16784 : CPASSERT(.NOT. ASSOCIATED(section))
2923 : CALL section_create(section, __LOCATION__, name="GCN", &
2924 : description="Allow to specify the generalized coordination number of the atoms. "// &
2925 : "Those numbers msust be generated by another program ", &
2926 16784 : n_keywords=1, n_subsections=0, repeats=.FALSE.)
2927 :
2928 16784 : NULLIFY (keyword)
2929 : CALL keyword_create(keyword, __LOCATION__, name="_DEFAULT_KEYWORD_", &
2930 : description="Value of the GCN for the individual atom. Order MUST reflect"// &
2931 : " the one specified for the geometry.", repeats=.TRUE., usage="{Real}", &
2932 16784 : default_r_val=0.0_dp, type_of_var=real_t)
2933 16784 : CALL section_add_keyword(section, keyword)
2934 16784 : CALL keyword_release(keyword)
2935 :
2936 16784 : END SUBROUTINE create_GCN_section
2937 :
2938 : ! **************************************************************************************************
2939 : !> \brief creates the input section for the qs part
2940 : !> \param print_key ...
2941 : !> \param label ...
2942 : !> \param print_level ...
2943 : !> \author teo
2944 : ! **************************************************************************************************
2945 92536 : SUBROUTINE create_dipoles_section(print_key, label, print_level)
2946 : TYPE(section_type), POINTER :: print_key
2947 : CHARACTER(LEN=*), INTENT(IN) :: label
2948 : INTEGER, INTENT(IN) :: print_level
2949 :
2950 : TYPE(keyword_type), POINTER :: keyword
2951 :
2952 92536 : CPASSERT(.NOT. ASSOCIATED(print_key))
2953 : CALL cp_print_key_section_create(print_key, __LOCATION__, name=TRIM(label), &
2954 : description="Section controlling the calculation of "//TRIM(label)//"."// &
2955 : " Note that the result in the periodic case might be defined modulo a certain period,"// &
2956 : " determined by the lattice vectors. During MD, this can lead to jumps.", &
2957 92536 : print_level=print_level, filename="__STD_OUT__")
2958 :
2959 92536 : NULLIFY (keyword)
2960 : CALL keyword_create(keyword, __LOCATION__, &
2961 : name="PERIODIC", &
2962 : description="Use Berry phase formula (PERIODIC=T) or simple operator (PERIODIC=F). "// &
2963 : "The latter normally requires that the CELL is periodic NONE.", &
2964 : usage="PERIODIC {logical}", &
2965 : repeats=.FALSE., &
2966 : n_var=1, &
2967 92536 : default_l_val=.TRUE., lone_keyword_l_val=.TRUE.)
2968 92536 : CALL section_add_keyword(print_key, keyword)
2969 92536 : CALL keyword_release(keyword)
2970 :
2971 : CALL keyword_create(keyword, __LOCATION__, name="REFERENCE", &
2972 : variants=s2a("REF"), &
2973 : description="Define the reference point for the calculation of the electrostatic moment.", &
2974 : usage="REFERENCE COM", &
2975 : enum_c_vals=s2a("COM", "COAC", "USER_DEFINED", "ZERO"), &
2976 : enum_desc=s2a("Use Center of Mass", &
2977 : "Use Center of Atomic Charges", &
2978 : "Use User Defined Point (Keyword:REF_POINT)", &
2979 : "Use Origin of Coordinate System"), &
2980 : enum_i_vals=(/use_mom_ref_com, &
2981 : use_mom_ref_coac, &
2982 : use_mom_ref_user, &
2983 : use_mom_ref_zero/), &
2984 92536 : default_i_val=use_mom_ref_zero)
2985 92536 : CALL section_add_keyword(print_key, keyword)
2986 92536 : CALL keyword_release(keyword)
2987 :
2988 : CALL keyword_create(keyword, __LOCATION__, name="REFERENCE_POINT", &
2989 : variants=s2a("REF_POINT"), &
2990 : description="Fixed reference point for the calculations of the electrostatic moment.", &
2991 : usage="REFERENCE_POINT x y z", &
2992 : repeats=.FALSE., &
2993 : n_var=3, default_r_vals=(/0._dp, 0._dp, 0._dp/), &
2994 : type_of_var=real_t, &
2995 92536 : unit_str='bohr')
2996 92536 : CALL section_add_keyword(print_key, keyword)
2997 92536 : CALL keyword_release(keyword)
2998 92536 : END SUBROUTINE create_dipoles_section
2999 :
3000 : END MODULE input_cp2k_mm
|