(git:fd7f302)
Loading...
Searching...
No Matches
xc_derivatives.F
Go to the documentation of this file.
1!--------------------------------------------------------------------------------------------------!
2! CP2K: A general program to perform molecular dynamics simulations !
3! Copyright 2000-2026 CP2K developers group <https://cp2k.org> !
4! !
5! SPDX-License-Identifier: GPL-2.0-or-later !
6!--------------------------------------------------------------------------------------------------!
7
8! **************************************************************************************************
10
14 USE kinds, ONLY: default_string_length,&
15 dp
17 USE xc_b97, ONLY: b97_lda_eval,&
21 USE xc_cs1, ONLY: cs1_lda_eval,&
26 USE xc_exchange_gga, ONLY: xgga_eval,&
29 USE xc_hcth, ONLY: hcth_lda_eval,&
31 USE xc_ke_gga, ONLY: ke_gga_info,&
38 USE xc_lyp, ONLY: lyp_lda_eval,&
46 USE xc_optx, ONLY: optx_lda_eval,&
50 USE xc_pade, ONLY: pade_info,&
51 pade_init,&
54 USE xc_pbe, ONLY: pbe_lda_eval,&
58 USE xc_perdew86, ONLY: p86_lda_eval,&
63 USE xc_perdew_zunger, ONLY: pz_info,&
70 USE xc_tfw, ONLY: tfw_lda_eval,&
77 USE xc_tpss, ONLY: tpss_lda_eval,&
79 USE xc_vwn, ONLY: vwn_lda_eval,&
83 USE xc_xalpha, ONLY: xalpha_info,&
86 USE xc_xbecke88, ONLY: xb88_lda_eval,&
102 USE xc_xbeef, ONLY: xbeef_lda_eval,&
118 USE xc_xwpbe, ONLY: xwpbe_lda_eval,&
122#include "../base/base_uses.f90"
123
124 IMPLICIT NONE
125
126 PRIVATE
127
128 LOGICAL, PARAMETER :: debug_this_module = .false.
129 CHARACTER(len=*), PARAMETER, PRIVATE :: moduleN = 'xc_derivatives'
130
132
133CONTAINS
134
135! **************************************************************************************************
136!> \brief get the information about the given functional
137!> \param functional the functional you want info about
138!> \param lsd if you are using lsd or lda
139!> \param reference the reference to the acticle where the functional is
140!> explained
141!> \param shortform the short definition of the functional
142!> \param needs the flags corresponding to the inputs needed by this
143!> functional are set to true (the flags not needed aren't touched)
144!> \param max_deriv the maximal derivative available
145!> \param print_warn whether to print warnings (mainly relevant for libxc)
146!> \author fawzi
147! **************************************************************************************************
148 SUBROUTINE xc_functional_get_info(functional, lsd, reference, shortform, &
149 needs, max_deriv, print_warn)
150 TYPE(section_vals_type), POINTER :: functional
151 LOGICAL, INTENT(in) :: lsd
152 CHARACTER(LEN=*), INTENT(OUT), OPTIONAL :: reference, shortform
153 TYPE(xc_rho_cflags_type), INTENT(inout), OPTIONAL :: needs
154 INTEGER, INTENT(out), OPTIONAL :: max_deriv
155 LOGICAL, INTENT(IN), OPTIONAL :: print_warn
156
157 INTEGER :: i_param
158 REAL(kind=dp) :: r_param
159
160 cpassert(ASSOCIATED(functional))
161 SELECT CASE (functional%section%name)
162 CASE ("BECKE97")
163 IF (lsd) THEN
164 CALL b97_lsd_info(reference=reference, shortform=shortform, &
165 needs=needs, max_deriv=max_deriv, b97_params=functional)
166 ELSE
167 CALL b97_lda_info(reference=reference, shortform=shortform, &
168 needs=needs, max_deriv=max_deriv, b97_params=functional)
169 END IF
170 CASE ("BECKE88_LR_ADIABATIC")
171 IF (lsd) THEN
172 CALL xb88_lr_adiabatic_lsd_info(reference=reference, shortform=shortform, &
173 needs=needs, max_deriv=max_deriv)
174 ELSE
175 CALL xb88_lr_adiabatic_lda_info(reference=reference, shortform=shortform, &
176 needs=needs, max_deriv=max_deriv)
177 END IF
178 CASE ("LYP_ADIABATIC")
179 IF (lsd) THEN
180 CALL lyp_adiabatic_lsd_info(reference=reference, shortform=shortform, &
181 needs=needs, max_deriv=max_deriv)
182 ELSE
183 CALL lyp_adiabatic_lda_info(reference=reference, shortform=shortform, &
184 needs=needs, max_deriv=max_deriv)
185 END IF
186 CASE ("BEEF")
187 IF (lsd) THEN
188 CALL xbeef_lsd_info(reference=reference, shortform=shortform, &
189 needs=needs, max_deriv=max_deriv)
190 ELSE
191 CALL xbeef_lda_info(reference=reference, shortform=shortform, &
192 needs=needs, max_deriv=max_deriv)
193 END IF
194 CASE ("BECKE88")
195 IF (lsd) THEN
196 CALL xb88_lsd_info(reference=reference, shortform=shortform, &
197 needs=needs, max_deriv=max_deriv)
198 ELSE
199 CALL xb88_lda_info(reference=reference, shortform=shortform, &
200 needs=needs, max_deriv=max_deriv)
201 END IF
202 CASE ("BECKE88_LR")
203 IF (lsd) THEN
204 CALL xb88_lr_lsd_info(reference=reference, shortform=shortform, &
205 needs=needs, max_deriv=max_deriv)
206 ELSE
207 CALL xb88_lr_lda_info(reference=reference, shortform=shortform, &
208 needs=needs, max_deriv=max_deriv)
209 END IF
210 CASE ("LYP")
211 IF (lsd) THEN
212 CALL lyp_lsd_info(reference=reference, shortform=shortform, &
213 needs=needs, max_deriv=max_deriv)
214 ELSE
215 CALL lyp_lda_info(reference=reference, shortform=shortform, &
216 needs=needs, max_deriv=max_deriv)
217 END IF
218 CASE ("PADE")
219 CALL pade_info(reference, shortform, lsd=lsd, needs=needs)
220 CASE ("HCTH")
221 CALL section_vals_val_get(functional, "PARAMETER_SET", i_val=i_param)
222 cpassert(.NOT. lsd)
223 CALL hcth_lda_info(i_param, reference, shortform, needs, max_deriv)
224 CASE ("OPTX")
225 IF (lsd) THEN
226 CALL optx_lsd_info(reference, shortform, needs, max_deriv)
227 ELSE
228 CALL optx_lda_info(reference, shortform, needs, max_deriv)
229 END IF
230 CASE ("CS1")
231 IF (lsd) THEN
232 CALL cs1_lsd_info(reference, shortform, needs, max_deriv)
233 ELSE
234 CALL cs1_lda_info(reference, shortform, needs=needs, max_deriv=max_deriv)
235 END IF
236 CASE ("XGGA")
237 CALL section_vals_val_get(functional, "FUNCTIONAL", i_val=i_param)
238 CALL xgga_info(i_param, lsd, reference, shortform, needs, max_deriv)
239 CASE ("KE_GGA")
240 CALL section_vals_val_get(functional, "FUNCTIONAL", i_val=i_param)
241 CALL ke_gga_info(i_param, lsd, reference, shortform, needs, max_deriv)
242 CASE ("P86C")
243 IF (lsd) THEN
244 cpabort("BP functional not implemented with LSD")
245 END IF
246 CALL p86_lda_info(reference, shortform, needs, max_deriv)
247 CASE ("PW92")
248 CALL section_vals_val_get(functional, "PARAMETRIZATION", i_val=i_param)
249 CALL section_vals_val_get(functional, "SCALE", r_val=r_param)
250 CALL perdew_wang_info(i_param, lsd, reference, shortform, needs, max_deriv, &
251 r_param)
252 CASE ("PZ81")
253 CALL section_vals_val_get(functional, "PARAMETRIZATION", i_val=i_param)
254 CALL pz_info(i_param, lsd, reference, shortform, needs, max_deriv)
255 CASE ("TFW")
256 IF (lsd) THEN
257 CALL tfw_lsd_info(reference, shortform, needs, max_deriv)
258 ELSE
259 CALL tfw_lda_info(reference, shortform, needs, max_deriv)
260 END IF
261 CASE ("TF")
262 CALL thomas_fermi_info(lsd, reference, shortform, needs, max_deriv)
263 CASE ("VWN")
264 IF (lsd) THEN
265 CALL vwn_lsd_info(reference, shortform, needs, max_deriv)
266 ELSE
267 CALL vwn_lda_info(reference, shortform, needs, max_deriv)
268 END IF
269 CASE ("XALPHA")
270 CALL section_vals_val_get(functional, "XA", r_val=r_param)
271 CALL xalpha_info(lsd, reference, shortform, needs, max_deriv, &
272 xa_parameter=r_param)
273 CASE ("TPSS")
274 IF (lsd) THEN
275 cpabort("TPSS functional not implemented with LSD. Use the LIBXC version instead.")
276 ELSE
277 CALL tpss_lda_info(functional, reference, shortform, needs, max_deriv)
278 END IF
279 CASE ("PBE")
280 IF (lsd) THEN
281 CALL pbe_lsd_info(functional, reference, shortform, needs, max_deriv)
282 ELSE
283 CALL pbe_lda_info(functional, reference, shortform, needs, max_deriv)
284 END IF
285 CASE ("GAUXC")
286 IF (gauxc_model_none_selected(functional)) THEN
287 CALL gauxc_model_none_xc_info(functional, lsd, reference, shortform, &
288 needs, max_deriv, print_warn)
289 ELSE
290 CALL skala_info(functional, lsd, reference, shortform, needs, max_deriv)
291 ! Note: SKALA functional routes through apply_gauxc in qs_ks_methods.F
292 ! when USE_GAUXC = .TRUE. (requires dft_control%use_gauxc to be set)
293 END IF
294 CASE ("XWPBE")
295 IF (lsd) THEN
296 CALL xwpbe_lsd_info(reference, shortform, needs, max_deriv)
297 ELSE
298 CALL xwpbe_lda_info(reference, shortform, needs, max_deriv)
299 END IF
300 CASE ("BECKE_ROUSSEL")
301 IF (lsd) THEN
302 CALL xbecke_roussel_lsd_info(reference, shortform, needs, max_deriv)
303 ELSE
304 CALL xbecke_roussel_lda_info(reference, shortform, needs, max_deriv)
305 END IF
306 CASE ("LDA_HOLE_T_C_LR")
307 IF (lsd) THEN
308 CALL xlda_hole_t_c_lr_lsd_info(reference, shortform, needs, max_deriv)
309 ELSE
310 CALL xlda_hole_t_c_lr_lda_info(reference, shortform, needs, max_deriv)
311 END IF
312 CASE ("PBE_HOLE_T_C_LR")
313 IF (lsd) THEN
314 CALL xpbe_hole_t_c_lr_lsd_info(reference, shortform, needs, max_deriv)
315 ELSE
316 CALL xpbe_hole_t_c_lr_lda_info(reference, shortform, needs, max_deriv)
317 END IF
318 CASE ("GV09")
319 IF (lsd) THEN
320 CALL xbr_pbe_lda_hole_tc_lr_lsd_info(reference, shortform, needs, max_deriv)
321 ELSE
322 CALL xbr_pbe_lda_hole_tc_lr_lda_info(reference, shortform, needs, max_deriv)
323 END IF
324 CASE default
325 ! If the functional has not been implemented internally, it's from LibXC
326 IF (lsd) THEN
327 CALL libxc_spin_polarized_info(functional, reference, shortform, needs, max_deriv, print_warn)
328 ELSE
329 CALL libxc_spin_unpolarized_info(functional, reference, shortform, needs, max_deriv, print_warn)
330 END IF
331 END SELECT
332 END SUBROUTINE xc_functional_get_info
333
334! **************************************************************************************************
335!> \brief evaluate a functional (and its derivatives)
336!> \param functional a section that describes the functional to be added
337!> \param lsd if a local spin desnity is performed
338!> \param rho_set a rho set where all the arguments needed by this functional
339!> should be valid (which argument are needed can be found with
340!> xc_functional_get_info)
341!> \param deriv_set place where to store the functional derivatives (they are
342!> added to the derivatives)
343!> \param deriv_order degree of the derivative that should be evaluated,
344!> if positive all the derivatives up to the given degree are evaluated,
345!> if negative only the given degree is requested (but to simplify
346!> the code all the derivatives might be calculated, you should ignore
347!> them when adding derivatives of various functionals they might contain
348!> the derivative of just one functional)
349!> \par History
350!> 11.2003 created [fawzi]
351!> \author fawzi
352! **************************************************************************************************
353 SUBROUTINE xc_functional_eval(functional, lsd, rho_set, deriv_set, deriv_order)
354
355 TYPE(section_vals_type), POINTER :: functional
356 LOGICAL, INTENT(in) :: lsd
357 TYPE(xc_rho_set_type), INTENT(IN) :: rho_set
358 TYPE(xc_derivative_set_type), INTENT(IN) :: deriv_set
359 INTEGER, INTENT(IN) :: deriv_order
360
361 CHARACTER(len=*), PARAMETER :: abort_message_skala = &
362 "GauXC functionals are evaluated only through the QS GauXC path. "// &
363 "Higher XC derivatives for response and kernel properties are not implemented.", &
364 routinen = 'xc_functional_eval'
365
366 INTEGER :: handle, i_param
367 LOGICAL :: fun_active
368 REAL(kind=dp) :: density_cut, gradient_cut, r_param
369
370 CALL timeset(routinen, handle)
371
372 CALL xc_rho_set_get(rho_set, rho_cutoff=density_cut, &
373 drho_cutoff=gradient_cut)
374 CALL section_vals_val_get(functional, "_SECTION_PARAMETERS_", &
375 l_val=fun_active)
376 IF (.NOT. fun_active) THEN
377 CALL timestop(handle)
378 RETURN
379 END IF
380
381 SELECT CASE (functional%section%name)
382 CASE ("BECKE97")
383 IF (lsd) THEN
384 CALL b97_lsd_eval(rho_set, deriv_set, deriv_order, functional)
385 ELSE
386 CALL b97_lda_eval(rho_set, deriv_set, deriv_order, functional)
387 END IF
388 CASE ("BECKE88_LR_ADIABATIC")
389 IF (lsd) THEN
390 CALL xb88_lr_adiabatic_lsd_eval(rho_set, deriv_set, deriv_order, functional)
391 ELSE
392 CALL xb88_lr_adiabatic_lda_eval(rho_set, deriv_set, deriv_order, functional)
393 END IF
394 CASE ("LYP_ADIABATIC")
395 IF (lsd) THEN
396 CALL lyp_adiabatic_lsd_eval(rho_set, deriv_set, deriv_order, functional)
397 ELSE
398 CALL lyp_adiabatic_lda_eval(rho_set, deriv_set, deriv_order, functional)
399 END IF
400 CASE ("BECKE88")
401 IF (lsd) THEN
402 CALL xb88_lsd_eval(rho_set, deriv_set, deriv_order, functional)
403 ELSE
404 CALL xb88_lda_eval(rho_set, deriv_set, deriv_order, functional)
405 END IF
406 CASE ("BEEF")
407 IF (lsd) THEN
408 CALL xbeef_lsd_eval(rho_set, deriv_set, deriv_order, functional)
409 ELSE
410 CALL xbeef_lda_eval(rho_set, deriv_set, deriv_order, functional)
411 END IF
412 CASE ("BECKE88_LR")
413 IF (lsd) THEN
414 CALL xb88_lr_lsd_eval(rho_set, deriv_set, deriv_order, functional)
415 ELSE
416 CALL xb88_lr_lda_eval(rho_set, deriv_set, deriv_order, functional)
417 END IF
418 CASE ("LYP")
419 IF (lsd) THEN
420 CALL lyp_lsd_eval(rho_set, deriv_set, deriv_order, functional)
421 ELSE
422 CALL lyp_lda_eval(rho_set, deriv_set, deriv_order, functional)
423 END IF
424 CASE ("PADE")
425 CALL pade_init(density_cut)
426 IF (lsd) THEN
427 CALL pade_lsd_pw_eval(deriv_set, rho_set, deriv_order)
428 ELSE
429 CALL pade_lda_pw_eval(deriv_set, rho_set, deriv_order)
430 END IF
431 CASE ("HCTH")
432 cpassert(.NOT. lsd)
433 CALL section_vals_val_get(functional, "PARAMETER_SET", i_val=i_param)
434 CALL hcth_lda_eval(i_param, rho_set, deriv_set, deriv_order)
435 CASE ("OPTX")
436 IF (lsd) THEN
437 CALL optx_lsd_eval(rho_set, deriv_set, deriv_order, functional)
438 ELSE
439 CALL optx_lda_eval(rho_set, deriv_set, deriv_order, functional)
440 END IF
441 CASE ("CS1")
442 IF (lsd) THEN
443 CALL cs1_lsd_eval(rho_set, deriv_set, deriv_order)
444 ELSE
445 CALL cs1_lda_eval(rho_set, deriv_set, deriv_order)
446 END IF
447 CASE ("XGGA")
448 CALL section_vals_val_get(functional, "FUNCTIONAL", i_val=i_param)
449 CALL xgga_eval(i_param, lsd, rho_set, deriv_set, deriv_order)
450 CASE ("KE_GGA")
451 CALL section_vals_val_get(functional, "FUNCTIONAL", i_val=i_param)
452 IF (lsd) THEN
453 CALL ke_gga_lsd_eval(i_param, rho_set, deriv_set, deriv_order)
454 ELSE
455 CALL ke_gga_lda_eval(i_param, rho_set, deriv_set, deriv_order)
456 END IF
457 CASE ("P86C")
458 cpassert(.NOT. lsd)
459 CALL p86_lda_eval(rho_set, deriv_set, deriv_order, functional)
460 CASE ("PW92")
461 CALL section_vals_val_get(functional, "PARAMETRIZATION", i_val=i_param)
462 CALL section_vals_val_get(functional, "SCALE", r_val=r_param)
463 IF (lsd) THEN
464 CALL perdew_wang_lsd_eval(i_param, rho_set, deriv_set, deriv_order, &
465 r_param)
466 ELSE
467 CALL perdew_wang_lda_eval(i_param, rho_set, deriv_set, deriv_order, &
468 r_param)
469 END IF
470 CASE ("PZ81")
471 CALL section_vals_val_get(functional, "PARAMETRIZATION", i_val=i_param)
472 IF (lsd) THEN
473 CALL pz_lsd_eval(i_param, rho_set, deriv_set, deriv_order, functional)
474 ELSE
475 CALL pz_lda_eval(i_param, rho_set, deriv_set, deriv_order, functional)
476 END IF
477 CASE ("TFW")
478 IF (lsd) THEN
479 CALL tfw_lsd_eval(rho_set, deriv_set, deriv_order)
480 ELSE
481 CALL tfw_lda_eval(rho_set, deriv_set, deriv_order)
482 END IF
483 CASE ("TF")
484 IF (lsd) THEN
485 CALL thomas_fermi_lsd_eval(rho_set, deriv_set, deriv_order)
486 ELSE
487 CALL thomas_fermi_lda_eval(rho_set, deriv_set, deriv_order)
488 END IF
489 CASE ("VWN")
490 IF (lsd) THEN
491 CALL vwn_lsd_eval(rho_set, deriv_set, deriv_order, functional)
492 ELSE
493 CALL vwn_lda_eval(rho_set, deriv_set, deriv_order, functional)
494 END IF
495 CASE ("XALPHA")
496 CALL section_vals_val_get(functional, "XA", r_val=r_param)
497 IF (lsd) THEN
498 CALL xalpha_lsd_eval(rho_set, deriv_set, deriv_order, &
499 xa_parameter=r_param, xa_params=functional)
500 ELSE
501 CALL xalpha_lda_eval(rho_set, deriv_set, deriv_order, &
502 xa_parameter=r_param, xa_params=functional)
503 END IF
504 CASE ("TPSS")
505 IF (lsd) THEN
506 cpabort("TPSS functional not implemented with LSD. Use the LIBXC version instead.")
507 ELSE
508 CALL tpss_lda_eval(rho_set, deriv_set, deriv_order, functional)
509 END IF
510 CASE ("PBE")
511 IF (lsd) THEN
512 CALL pbe_lsd_eval(rho_set, deriv_set, deriv_order, functional)
513 ELSE
514 CALL pbe_lda_eval(rho_set, deriv_set, deriv_order, functional)
515 END IF
516 CASE ("GAUXC")
517 IF (gauxc_model_none_selected(functional)) THEN
518 CALL gauxc_model_none_xc_eval(functional, lsd, rho_set, deriv_set, deriv_order)
519 ELSE
520 cpabort(abort_message_skala)
521 END IF
522 CASE ("XWPBE")
523 IF (lsd) THEN
524 CALL xwpbe_lsd_eval(rho_set, deriv_set, deriv_order, functional)
525 ELSE
526 CALL xwpbe_lda_eval(rho_set, deriv_set, deriv_order, functional)
527 END IF
528 CASE ("BECKE_ROUSSEL")
529 IF (lsd) THEN
530 CALL xbecke_roussel_lsd_eval(rho_set, deriv_set, deriv_order, functional)
531 ELSE
532 CALL xbecke_roussel_lda_eval(rho_set, deriv_set, deriv_order, functional)
533 END IF
534 CASE ("LDA_HOLE_T_C_LR")
535 IF (lsd) THEN
536 CALL xlda_hole_t_c_lr_lsd_eval(rho_set, deriv_set, deriv_order, functional)
537 ELSE
538 CALL xlda_hole_t_c_lr_lda_eval(rho_set, deriv_set, deriv_order, functional)
539 END IF
540 CASE ("PBE_HOLE_T_C_LR")
541 IF (lsd) THEN
542 CALL xpbe_hole_t_c_lr_lsd_eval(rho_set, deriv_set, deriv_order, functional)
543 ELSE
544 CALL xpbe_hole_t_c_lr_lda_eval(rho_set, deriv_set, deriv_order, functional)
545 END IF
546 CASE ("GV09")
547 IF (lsd) THEN
548 CALL xbr_pbe_lda_hole_tc_lr_lsd_eval(rho_set, deriv_set, deriv_order, &
549 functional)
550 ELSE
551 CALL xbr_pbe_lda_hole_tc_lr_lda_eval(rho_set, deriv_set, deriv_order, &
552 functional)
553 END IF
554 CASE default
555 ! If functional not natively supported, ask LibXC
556 IF (lsd) THEN
557 CALL libxc_spin_polarized_eval(rho_set, deriv_set, deriv_order, functional)
558 ELSE
559 CALL libxc_spin_unpolarized_eval(rho_set, deriv_set, deriv_order, functional)
560 END IF
561 END SELECT
562
563 CALL timestop(handle)
564 END SUBROUTINE xc_functional_eval
565
566! **************************************************************************************************
567!> \brief true for GAUXC sections that wrap a conventional LibXC functional
568!> \param functional the GAUXC section
569!> \return whether MODEL NONE is active
570! **************************************************************************************************
571 FUNCTION gauxc_model_none_selected(functional)
572 TYPE(section_vals_type), POINTER :: functional
573 LOGICAL :: gauxc_model_none_selected
574
575 CHARACTER(LEN=default_string_length) :: model_key, model_name, xc_fun_name, &
576 xc_key
577
578 CALL section_vals_val_get(functional, "MODEL", c_val=model_name)
579 CALL section_vals_val_get(functional, "FUNCTIONAL", c_val=xc_fun_name)
580 model_key = adjustl(model_name)
581 xc_key = adjustl(xc_fun_name)
582 CALL uppercase(model_key)
583 CALL uppercase(xc_key)
584 gauxc_model_none_selected = (trim(model_key) == "" .OR. trim(model_key) == "NONE" .OR. &
585 trim(model_key) == trim(xc_key))
586 END FUNCTION gauxc_model_none_selected
587
588! **************************************************************************************************
589!> \brief map GAUXC MODEL NONE shorthand names to LibXC exchange/correlation components
590!> \param functional the GAUXC section
591!> \param xc_fun_name the GAUXC FUNCTIONAL value
592!> \param libxc_names LibXC section names to evaluate and add
593!> \param nfunc number of LibXC components
594! **************************************************************************************************
595 SUBROUTINE gauxc_model_none_libxc_names(functional, xc_fun_name, libxc_names, nfunc)
596 TYPE(section_vals_type), POINTER :: functional
597 CHARACTER(LEN=*), INTENT(OUT) :: xc_fun_name
598 CHARACTER(LEN=*), DIMENSION(:), INTENT(OUT) :: libxc_names
599 INTEGER, INTENT(OUT) :: nfunc
600
601 CHARACTER(LEN=default_string_length) :: xc_key
602
603 CALL section_vals_val_get(functional, "FUNCTIONAL", c_val=xc_fun_name)
604 xc_key = adjustl(xc_fun_name)
605 CALL uppercase(xc_key)
606 libxc_names(:) = ""
607 SELECT CASE (trim(xc_key))
608 CASE ("LDA", "PADE")
609 nfunc = 2
610 libxc_names(1) = "LDA_X"
611 libxc_names(2) = "LDA_C_PW"
612 CASE ("VWN")
613 nfunc = 2
614 libxc_names(1) = "LDA_X"
615 libxc_names(2) = "LDA_C_VWN"
616 CASE ("PBE")
617 nfunc = 2
618 libxc_names(1) = "GGA_X_PBE"
619 libxc_names(2) = "GGA_C_PBE"
620 CASE ("BLYP")
621 nfunc = 2
622 libxc_names(1) = "GGA_X_B88"
623 libxc_names(2) = "GGA_C_LYP"
624 CASE ("BP")
625 nfunc = 2
626 libxc_names(1) = "GGA_X_B88"
627 libxc_names(2) = "GGA_C_P86"
628 CASE ("TPSS")
629 nfunc = 2
630 libxc_names(1) = "MGGA_X_TPSS"
631 libxc_names(2) = "MGGA_C_TPSS"
632 CASE ("R2SCAN")
633 nfunc = 2
634 libxc_names(1) = "MGGA_X_R2SCAN"
635 libxc_names(2) = "MGGA_C_R2SCAN"
636 CASE DEFAULT
637 nfunc = 1
638 libxc_names(1) = trim(xc_key)
639 END SELECT
640 END SUBROUTINE gauxc_model_none_libxc_names
641
642! **************************************************************************************************
643!> \brief needs information for GAUXC MODEL NONE one-center GAPW corrections
644!> \param functional the GAUXC section
645!> \param lsd whether spin-polarized derivatives are needed
646!> \param reference reference string for the wrapped functional
647!> \param shortform short name for printout
648!> \param needs density ingredients needed by the wrapped functional
649!> \param max_deriv maximum implemented derivative order
650!> \param print_warn whether LibXC should print development warnings
651! **************************************************************************************************
652 SUBROUTINE gauxc_model_none_xc_info(functional, lsd, reference, shortform, &
653 needs, max_deriv, print_warn)
654 TYPE(section_vals_type), POINTER :: functional
655 LOGICAL, INTENT(in) :: lsd
656 CHARACTER(LEN=*), INTENT(OUT), OPTIONAL :: reference, shortform
657 TYPE(xc_rho_cflags_type), INTENT(inout), OPTIONAL :: needs
658 INTEGER, INTENT(out), OPTIONAL :: max_deriv
659 LOGICAL, INTENT(IN), OPTIONAL :: print_warn
660
661 CHARACTER(LEN=default_string_length) :: libxc_names(2), xc_fun_name
662 INTEGER :: ifunc, max_deriv_i, max_deriv_min, nfunc
663
664 CALL gauxc_model_none_libxc_names(functional, xc_fun_name, libxc_names, nfunc)
665 max_deriv_min = huge(max_deriv_min)
666 DO ifunc = 1, nfunc
667 IF (lsd) THEN
668 CALL libxc_spin_polarized_info(functional, needs=needs, max_deriv=max_deriv_i, &
669 print_warn=print_warn, &
670 func_name_override=trim(libxc_names(ifunc)))
671 ELSE
672 CALL libxc_spin_unpolarized_info(functional, needs=needs, max_deriv=max_deriv_i, &
673 print_warn=print_warn, &
674 func_name_override=trim(libxc_names(ifunc)))
675 END IF
676 max_deriv_min = min(max_deriv_min, max_deriv_i)
677 END DO
678 IF (PRESENT(max_deriv)) max_deriv = max_deriv_min
679 IF (PRESENT(reference)) THEN
680 reference = "Functional computed by GauXC (underlying: "//trim(xc_fun_name)//")"
681 END IF
682 IF (PRESENT(shortform)) shortform = "GAUXC ("//trim(xc_fun_name)//")"
683 END SUBROUTINE gauxc_model_none_xc_info
684
685! **************************************************************************************************
686!> \brief one-center GAPW correction evaluation for GAUXC MODEL NONE
687!> \param functional the GAUXC section
688!> \param lsd whether spin-polarized derivatives are evaluated
689!> \param rho_set density ingredients
690!> \param deriv_set derivative accumulator
691!> \param deriv_order derivative order to evaluate
692! **************************************************************************************************
693 SUBROUTINE gauxc_model_none_xc_eval(functional, lsd, rho_set, deriv_set, deriv_order)
694 TYPE(section_vals_type), POINTER :: functional
695 LOGICAL, INTENT(in) :: lsd
696 TYPE(xc_rho_set_type), INTENT(IN) :: rho_set
697 TYPE(xc_derivative_set_type), INTENT(IN) :: deriv_set
698 INTEGER, INTENT(IN) :: deriv_order
699
700 CHARACTER(LEN=default_string_length) :: libxc_names(2), xc_fun_name
701 INTEGER :: ifunc, nfunc
702
703 CALL gauxc_model_none_libxc_names(functional, xc_fun_name, libxc_names, nfunc)
704 DO ifunc = 1, nfunc
705 IF (lsd) THEN
706 CALL libxc_spin_polarized_eval(rho_set, deriv_set, deriv_order, functional, &
707 func_name_override=trim(libxc_names(ifunc)))
708 ELSE
709 CALL libxc_spin_unpolarized_eval(rho_set, deriv_set, deriv_order, functional, &
710 func_name_override=trim(libxc_names(ifunc)))
711 END IF
712 END DO
713 END SUBROUTINE gauxc_model_none_xc_eval
714
715! **************************************************************************************************
716!> \brief ...
717!> \param functionals a section containing the functional combination to be
718!> applied
719!> \param lsd if a local spin desnity is performed
720!> \param rho_set a rho set where all the arguments needed by this functional
721!> should be valid (which argument are needed can be found with
722!> xc_functional_get_info)
723!> \param deriv_set place where to store the functional derivatives (they are
724!> added to the derivatives)
725!> \param deriv_order degree of the derivative that should be evaluated,
726!> if positive all the derivatives up to the given degree are evaluated,
727!> if negative only the given degree is requested (but to simplify
728!> the code all the derivatives might be calculated, you should ignore
729!> them when adding derivatives of various functionals they might contain
730!> the derivative of just one functional)
731!> \author fawzi
732! **************************************************************************************************
733 SUBROUTINE xc_functionals_eval(functionals, lsd, rho_set, deriv_set, &
734 deriv_order)
735 TYPE(section_vals_type), POINTER :: functionals
736 LOGICAL, INTENT(in) :: lsd
737 TYPE(xc_rho_set_type), INTENT(IN) :: rho_set
738 TYPE(xc_derivative_set_type), INTENT(IN) :: deriv_set
739 INTEGER, INTENT(in) :: deriv_order
740
741 INTEGER :: ifun
742 TYPE(section_vals_type), POINTER :: xc_fun
743
744 cpassert(ASSOCIATED(functionals))
745 ifun = 0
746 DO
747 ifun = ifun + 1
748 xc_fun => section_vals_get_subs_vals2(functionals, i_section=ifun)
749 IF (.NOT. ASSOCIATED(xc_fun)) EXIT
750 CALL xc_functional_eval(xc_fun, &
751 lsd=lsd, &
752 rho_set=rho_set, &
753 deriv_set=deriv_set, &
754 deriv_order=deriv_order)
755 END DO
756 END SUBROUTINE xc_functionals_eval
757
758! **************************************************************************************************
759!> \brief ...
760!> \param functionals a section containing the functional combination to be
761!> applied
762!> \param lsd if a local spin desnity is performed
763!> \param calc_potential set, if potential calculation will be carried out later.
764!> helps to save memory and flops. defaults to false.
765!> \return ...
766!> \author fawzi
767! **************************************************************************************************
768 FUNCTION xc_functionals_get_needs(functionals, lsd, calc_potential) &
769 result(needs)
770 TYPE(section_vals_type), POINTER :: functionals
771 LOGICAL, INTENT(in) :: lsd
772 LOGICAL, INTENT(in), OPTIONAL :: calc_potential
773 TYPE(xc_rho_cflags_type) :: needs
774
775 INTEGER :: ifun
776 LOGICAL :: my_calc_potential
777 TYPE(section_vals_type), POINTER :: xc_fun
778
779 my_calc_potential = .false.
780 IF (PRESENT(calc_potential)) my_calc_potential = calc_potential
781
782 cpassert(ASSOCIATED(functionals))
783 CALL xc_rho_cflags_setall(needs, .false.)
784
785 ifun = 0
786 DO
787 ifun = ifun + 1
788 xc_fun => section_vals_get_subs_vals2(functionals, i_section=ifun)
789 IF (.NOT. ASSOCIATED(xc_fun)) EXIT
790 CALL xc_functional_get_info(xc_fun, lsd=lsd, needs=needs)
791 END DO
792
793 IF (my_calc_potential) THEN
794 IF (lsd) THEN
795 needs%rho_spin = .true.
796 needs%tau_spin = needs%tau_spin .OR. needs%tau
797 ELSE
798 needs%rho = .true.
799 END IF
800 IF (needs%norm_drho .OR. needs%norm_drho_spin) THEN
801 IF (lsd) THEN
802 needs%drho_spin = .true.
803 ELSE
804 needs%drho = .true.
805 END IF
806 END IF
807 END IF
808 END FUNCTION xc_functionals_get_needs
809
810END MODULE xc_derivatives
objects that represent the structure of input sections and the data contained in an input section
type(section_vals_type) function, pointer, public section_vals_get_subs_vals2(section_vals, i_section, i_rep_section)
returns the values of the n-th non default subsection (null if no such section exists (not so many no...
subroutine, public section_vals_val_get(section_vals, keyword_name, i_rep_section, i_rep_val, n_rep_val, val, l_val, i_val, r_val, c_val, l_vals, i_vals, r_vals, c_vals, explicit)
returns the requested value
Defines the basic variable types.
Definition kinds.F:23
integer, parameter, public dp
Definition kinds.F:34
integer, parameter, public default_string_length
Definition kinds.F:57
Utilities for string manipulations.
elemental subroutine, public uppercase(string)
Convert all lower case characters in a string to upper case.
calculates the b97 correlation functional
Definition xc_b97.F:24
subroutine, public b97_lda_info(b97_params, reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_b97.F:187
subroutine, public b97_lda_eval(rho_set, deriv_set, grad_deriv, b97_params)
evaluates the b97 correlation functional for lda
Definition xc_b97.F:252
subroutine, public b97_lsd_info(b97_params, reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_b97.F:219
subroutine, public b97_lsd_eval(rho_set, deriv_set, grad_deriv, b97_params)
evaluates the b 97 xc functional for lsd
Definition xc_b97.F:364
Calculate the CS1 Functional (Handy s improved LYP functional)
Definition xc_cs1.F:15
subroutine, public cs1_lda_eval(rho_set, deriv_set, order)
...
Definition xc_cs1.F:149
subroutine, public cs1_lsd_eval(rho_set, deriv_set, order)
...
Definition xc_cs1.F:238
subroutine, public cs1_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_cs1.F:100
subroutine, public cs1_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_cs1.F:72
represent a group ofunctional derivatives
type(xc_rho_cflags_type) function, public xc_functionals_get_needs(functionals, lsd, calc_potential)
...
subroutine, public xc_functional_get_info(functional, lsd, reference, shortform, needs, max_deriv, print_warn)
get the information about the given functional
subroutine, public xc_functionals_eval(functionals, lsd, rho_set, deriv_set, deriv_order)
...
Calculate several different exchange energy functionals with a GGA form.
subroutine, public xgga_eval(functional, lsd, rho_set, deriv_set, order)
evaluates different exchange gga
subroutine, public xgga_info(functional, lsd, reference, shortform, needs, max_deriv)
return various information on the xgga functionals
subroutine, public skala_info(functional, lsd, reference, shortform, needs, max_deriv)
Return information about the Skala functional.
calculate the Hamprecht, Cohen, Tozer, and Handy (HCTH) exchange functional
Definition xc_hcth.F:13
subroutine, public hcth_lda_info(iparset, reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_hcth.F:49
subroutine, public hcth_lda_eval(iparset, rho_set, deriv_set, grad_deriv)
evaluates the hcth functional for lda
Definition xc_hcth.F:118
Calculate the several different kinetic energy functionals with a GGA form.
Definition xc_ke_gga.F:16
subroutine, public ke_gga_lsd_eval(functional, rho_set, deriv_set, order)
...
Definition xc_ke_gga.F:313
subroutine, public ke_gga_info(functional, lsd, reference, shortform, needs, max_deriv)
...
Definition xc_ke_gga.F:97
subroutine, public ke_gga_lda_eval(functional, rho_set, deriv_set, order)
...
Definition xc_ke_gga.F:178
calculates a functional from libxc and its derivatives
Definition xc_libxc.F:28
subroutine, public libxc_spin_unpolarized_info(libxc_params, reference, shortform, needs, max_deriv, print_warn, func_name_override)
info about the functional from libxc
Definition xc_libxc.F:316
subroutine, public libxc_spin_unpolarized_eval(rho_set, deriv_set, grad_deriv, libxc_params, func_name_override)
evaluates the functional from libxc
Definition xc_libxc.F:568
subroutine, public libxc_spin_polarized_info(libxc_params, reference, shortform, needs, max_deriv, print_warn, func_name_override)
info about the functional from libxc
Definition xc_libxc.F:433
subroutine, public libxc_spin_polarized_eval(rho_set, deriv_set, grad_deriv, libxc_params, func_name_override)
evaluates the functional from libxc
Definition xc_libxc.F:814
Calculates the density_scaled Lyp functional when used in adiabatic hybrids. The energy is given as.
subroutine, public lyp_adiabatic_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
subroutine, public lyp_adiabatic_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
subroutine, public lyp_adiabatic_lda_eval(rho_set, deriv_set, grad_deriv, lyp_adiabatic_params)
...
subroutine, public lyp_adiabatic_lsd_eval(rho_set, deriv_set, grad_deriv, lyp_adiabatic_params)
...
calculates the lyp correlation functional
Definition xc_lyp.F:14
subroutine, public lyp_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_lyp.F:59
subroutine, public lyp_lsd_eval(rho_set, deriv_set, grad_deriv, lyp_params)
evaluates the becke 88 exchange functional for lsd
Definition xc_lyp.F:727
subroutine, public lyp_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_lyp.F:90
subroutine, public lyp_lda_eval(rho_set, deriv_set, grad_deriv, lyp_params)
evaluates the lyp correlation functional for lda
Definition xc_lyp.F:124
calculate optx
Definition xc_optx.F:14
subroutine, public optx_lda_info(reference, shortform, needs, max_deriv)
info about the optx functional
Definition xc_optx.F:52
subroutine, public optx_lsd_eval(rho_set, deriv_set, grad_deriv, optx_params)
evaluates the optx functional for lsd
Definition xc_optx.F:169
subroutine, public optx_lda_eval(rho_set, deriv_set, grad_deriv, optx_params)
evaluates the optx functional for lda
Definition xc_optx.F:110
subroutine, public optx_lsd_info(reference, shortform, needs, max_deriv)
info about the optx functional (LSD)
Definition xc_optx.F:79
Calculate the LDA functional in the Pade approximation Literature: S. Goedecker, M....
Definition xc_pade.F:19
subroutine, public pade_init(cutoff, debug)
...
Definition xc_pade.F:80
subroutine, public pade_lsd_pw_eval(deriv_set, rho_set, order)
...
Definition xc_pade.F:205
subroutine, public pade_info(reference, shortform, lsd, needs, max_deriv)
...
Definition xc_pade.F:106
subroutine, public pade_lda_pw_eval(deriv_set, rho_set, order)
...
Definition xc_pade.F:142
calculates the pbe correlation functional
Definition xc_pbe.F:21
subroutine, public pbe_lda_eval(rho_set, deriv_set, grad_deriv, pbe_params)
evaluates the pbe correlation functional for lda
Definition xc_pbe.F:280
subroutine, public pbe_lsd_info(pbe_params, reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_pbe.F:174
subroutine, public pbe_lsd_eval(rho_set, deriv_set, grad_deriv, pbe_params)
evaluates the becke 88 exchange functional for lsd
Definition xc_pbe.F:1326
subroutine, public pbe_lda_info(pbe_params, reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_pbe.F:70
Calculate the Perdew Correlation from 1986.
Definition xc_perdew86.F:15
subroutine, public p86_lda_info(reference, shortform, needs, max_deriv)
...
Definition xc_perdew86.F:92
subroutine, public p86_lda_eval(rho_set, deriv_set, order, p86_params)
...
Calculate the Perdew-Wang correlation potential and energy density and ist derivatives with respect t...
subroutine, public perdew_wang_lda_eval(method, rho_set, deriv_set, order, scale)
Calculate the correlation energy and its derivatives wrt to rho (the electron density) up to 3rd orde...
subroutine, public perdew_wang_info(method, lsd, reference, shortform, needs, max_deriv, scale)
Return some info on the functionals.
subroutine, public perdew_wang_lsd_eval(method, rho_set, deriv_set, order, scale)
Calculate the correlation energy and its derivatives wrt to rho (the electron density) up to 3rd orde...
Calculate the Perdew-Zunger correlation potential and energy density and ist derivatives with respect...
subroutine, public pz_lda_eval(method, rho_set, deriv_set, order, pz_params)
Calculate the correlation energy and its derivatives wrt to rho (the electron density) up to 3rd orde...
subroutine, public pz_lsd_eval(method, rho_set, deriv_set, order, pz_params)
Calculate the correlation energy and its derivatives wrt to rho (the electron density) up to 3rd orde...
subroutine, public pz_info(method, lsd, reference, shortform, needs, max_deriv)
Return some info on the functionals.
contains the structure
elemental subroutine, public xc_rho_cflags_setall(cflags, value)
sets all the flags to the given value
contains the structure
subroutine, public xc_rho_set_get(rho_set, can_return_null, rho, drho, norm_drho, rhoa, rhob, norm_drhoa, norm_drhob, rho_1_3, rhoa_1_3, rhob_1_3, laplace_rho, laplace_rhoa, laplace_rhob, drhoa, drhob, rho_cutoff, drho_cutoff, tau_cutoff, tau, tau_a, tau_b, local_bounds)
returns the various attributes of rho_set
Calculate the Thomas-Fermi kinetic energy functional plus the von Weizsaecker term.
Definition xc_tfw.F:16
subroutine, public tfw_lda_info(reference, shortform, needs, max_deriv)
...
Definition xc_tfw.F:80
subroutine, public tfw_lda_eval(rho_set, deriv_set, order)
...
Definition xc_tfw.F:133
subroutine, public tfw_lsd_info(reference, shortform, needs, max_deriv)
...
Definition xc_tfw.F:107
subroutine, public tfw_lsd_eval(rho_set, deriv_set, order)
...
Definition xc_tfw.F:243
Calculate the Thomas-Fermi kinetic energy functional.
subroutine, public thomas_fermi_lsd_eval(rho_set, deriv_set, order)
...
subroutine, public thomas_fermi_lda_eval(rho_set, deriv_set, order)
...
subroutine, public thomas_fermi_info(lsd, reference, shortform, needs, max_deriv)
...
Calculates the tpss functional.
Definition xc_tpss.F:17
subroutine, public tpss_lda_eval(rho_set, deriv_set, grad_deriv, tpss_params)
evaluates the tpss functional in the spin unpolarized (lda) case
Definition xc_tpss.F:109
subroutine, public tpss_lda_info(tpss_params, reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_tpss.F:60
Calculate the LDA functional according to Vosk, Wilk and Nusair Literature: S. H. Vosko,...
Definition xc_vwn.F:21
subroutine, public vwn_lda_info(reference, shortform, needs, max_deriv)
...
Definition xc_vwn.F:115
subroutine, public vwn_lda_eval(rho_set, deriv_set, order, vwn_params)
...
Definition xc_vwn.F:167
subroutine, public vwn_lsd_eval(rho_set, deriv_set, order, vwn_params)
...
Definition xc_vwn.F:525
subroutine, public vwn_lsd_info(reference, shortform, needs, max_deriv)
...
Definition xc_vwn.F:141
Calculate the local exchange functional.
Definition xc_xalpha.F:19
subroutine, public xalpha_lda_eval(rho_set, deriv_set, order, xa_params, xa_parameter)
...
Definition xc_xalpha.F:152
subroutine, public xalpha_info(lsd, reference, shortform, needs, max_deriv, xa_parameter, scaling)
...
Definition xc_xalpha.F:91
subroutine, public xalpha_lsd_eval(rho_set, deriv_set, order, xa_params, xa_parameter)
...
Definition xc_xalpha.F:222
calculates the longrange part of Becke 88 exchange functional
subroutine, public xb88_lr_lda_eval(rho_set, deriv_set, grad_deriv, xb88_lr_params)
evaluates the becke 88 longrange exchange functional for lda
subroutine, public xb88_lr_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
subroutine, public xb88_lr_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
subroutine, public xb88_lr_lsd_eval(rho_set, deriv_set, grad_deriv, xb88_lr_params)
evaluates the becke 88 longrange exchange functional for lsd
Calculates the density_scaled BECKE88 long-range functional when used in adiabatic hybrids....
subroutine, public xb88_lr_adiabatic_lda_eval(rho_set, deriv_set, grad_deriv, xb88_lr_ad_params)
evaluates the becke 88 longrange exchange functional for lda
subroutine, public xb88_lr_adiabatic_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
subroutine, public xb88_lr_adiabatic_lsd_eval(rho_set, deriv_set, grad_deriv, xb88_lr_ad_params)
evaluates the becke 88 longrange exchange functional for lsd
subroutine, public xb88_lr_adiabatic_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
calculates the Becke 88 exchange functional
Definition xc_xbecke88.F:14
subroutine, public xb88_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_xbecke88.F:90
subroutine, public xb88_lda_eval(rho_set, deriv_set, grad_deriv, xb88_params)
evaluates the becke 88 exchange functional for lda
subroutine, public xb88_lsd_eval(rho_set, deriv_set, grad_deriv, xb88_params)
evaluates the becke 88 exchange functional for lsd
subroutine, public xb88_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_xbecke88.F:59
Calculates the exchange energy based on the Becke-Roussel exchange hole. Takes advantage of an analyt...
subroutine, public xbecke_roussel_lsd_eval(rho_set, deriv_set, grad_deriv, br_params)
evaluates the Becke Roussel exchange functional for lda
subroutine, public xbecke_roussel_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
subroutine, public xbecke_roussel_lda_eval(rho_set, deriv_set, grad_deriv, br_params)
evaluates the Becke Roussel exchange functional for lda
subroutine, public xbecke_roussel_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
calculates the Exchange contribution in the BEEF-vdW functional
Definition xc_xbeef.F:15
subroutine, public xbeef_lda_eval(rho_set, deriv_set, grad_deriv, xbeef_params)
evaluates the beef exchange functional for lda
Definition xc_xbeef.F:137
subroutine, public xbeef_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_xbeef.F:104
subroutine, public xbeef_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_xbeef.F:73
subroutine, public xbeef_lsd_eval(rho_set, deriv_set, grad_deriv, xbeef_params)
evaluates the beef 88 exchange functional for lsd
Definition xc_xbeef.F:311
This functional is a combination of three different exchange hole models. The ingredients are:
subroutine, public xbr_pbe_lda_hole_tc_lr_lsd_eval(rho_set, deriv_set, grad_deriv, params)
Intermediate routine that gets grids, derivatives and some params.
subroutine, public xbr_pbe_lda_hole_tc_lr_lda_eval(rho_set, deriv_set, grad_deriv, params)
Intermediate routine that gets grids, derivatives and some params.
subroutine, public xbr_pbe_lda_hole_tc_lr_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
subroutine, public xbr_pbe_lda_hole_tc_lr_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
Calculates the lda exchange hole in a truncated coulomb potential. Can be used as longrange correctio...
subroutine, public xlda_hole_t_c_lr_lda_eval(rho_set, deriv_set, order, params)
evaluates the truncated lda exchange hole
subroutine, public xlda_hole_t_c_lr_lda_info(reference, shortform, needs, max_deriv)
returns various information on the functional
subroutine, public xlda_hole_t_c_lr_lsd_eval(rho_set, deriv_set, order, params)
evaluates the truncated lsd exchange hole. Calls the lda routine and applies spin scaling relation
subroutine, public xlda_hole_t_c_lr_lsd_info(reference, shortform, needs, max_deriv)
returns various information on the functional
Calculates the exchange energy for the pbe hole model in a truncated coulomb potential,...
subroutine, public xpbe_hole_t_c_lr_lda_info(reference, shortform, needs, max_deriv)
returns various information on the functional
subroutine, public xpbe_hole_t_c_lr_lda_eval(rho_set, deriv_set, order, params)
evaluates the pbe-hole exchange in a truncated coulomb potential
subroutine, public xpbe_hole_t_c_lr_lsd_eval(rho_set, deriv_set, order, params)
evaluates the pbe-hole exchange in a truncated coulomb potential
subroutine, public xpbe_hole_t_c_lr_lsd_info(reference, shortform, needs, max_deriv)
returns various information on the functional
Calculates short range exchange part for wPBE functional and averaged PBE exchange-hole functional (o...
Definition xc_xwpbe.F:15
subroutine, public xwpbe_lda_eval(rho_set, deriv_set, order, xwpbe_params)
evaluates the screened hole averaged PBE exchange functional for lda
Definition xc_xwpbe.F:150
subroutine, public xwpbe_lsd_eval(rho_set, deriv_set, order, xwpbe_params)
evaluates the screened hole averaged PBE exchange functional for lsd
Definition xc_xwpbe.F:5255
subroutine, public xwpbe_lda_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_xwpbe.F:113
subroutine, public xwpbe_lsd_info(reference, shortform, needs, max_deriv)
return various information on the functional
Definition xc_xwpbe.F:5220
A derivative set contains the different derivatives of a xc-functional in form of a linked list.
contains a flag for each component of xc_rho_set, so that you can use it to tell which components you...
represent a density, with all the representation and data needed to perform a functional evaluation