Skip to content

Commit

Permalink
xTB Halogen correction term
Browse files Browse the repository at this point in the history
  • Loading branch information
juerghutter committed Mar 19, 2019
1 parent 501656d commit 48e8a07
Show file tree
Hide file tree
Showing 8 changed files with 262 additions and 53 deletions.
21 changes: 20 additions & 1 deletion src/common/bibliography.F
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ MODULE bibliography
Becke1988b, Migliore2009, Mavros2015, Holmberg2017, Marek2014, &
Stoychev2016, Futera2017, Bailey2006, Papior2017, Lehtola2018, &
Brieuc2016, Barca2018, Scheiber2018, Huang2011, Heaton_Burgess2007, &
Schuett2018, Holmberg2018, Togo2018, Staub2019
Schuett2018, Holmberg2018, Togo2018, Staub2019, Grimme2017

CONTAINS

Expand Down Expand Up @@ -1806,6 +1806,25 @@ SUBROUTINE add_all_references()
"ER"), &
DOI="10.1002/jcc.21759")

CALL add_reference(key=Grimme2017, ISI_record=s2a( &
"PT J", &
"AU Grimme, S", &
" Bannwarth, C", &
" Shushkov, P", &
"AF Grimme, Stefan", &
" Bannwarth, Christoph", &
" Shushkov, Philip", &
"TI A Robust and Accurate Tight-Binding Quantum Chemical Method for", &
" Structures, Vibrational Frequencies, and Noncovalent Interactions of", &
" Large Molecular Systems Parametrized for All spd-Block Elements (Z = 1-86) ", &
"SO Journal of Chemical Theory and Computation", &
"PY 2017", &
"VL 13", &
"BP 1989", &
"DI 10.1021/acs.jctc.7b00118", &
"ER"), &
DOI="10.1021/acs.jctc.7b00118")

CALL add_reference(key=Branduardi2007, ISI_record=s2a( &
"PT J", &
"AU Branduardi, D", &
Expand Down
1 change: 1 addition & 0 deletions src/cp_control_types.F
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,7 @@ MODULE cp_control_types
REAL(KIND=dp) :: ken
REAL(KIND=dp) :: kxr, kx2
!
LOGICAL :: xb_interaction
REAL(KIND=dp) :: xb_radius
!
CHARACTER(LEN=default_string_length), &
Expand Down
7 changes: 5 additions & 2 deletions src/cp_control_utils.F
Original file line number Diff line number Diff line change
Expand Up @@ -1079,13 +1079,16 @@ SUBROUTINE read_qs_section(qs_control, qs_section)
qs_control%xtb_control%kcnd = scal(3)
CALL section_vals_val_get(xtb_parameter, "EN_CONSTANT", r_vals=scal)
qs_control%xtb_control%ken = scal(1)
! XB
CALL section_vals_val_get(xtb_section, "USE_HALOGEN_CORRECTION", &
l_val=qs_control%xtb_control%xb_interaction)
CALL section_vals_val_get(xtb_parameter, "HALOGEN_BINDING", r_vals=scal)
qs_control%xtb_control%kxr = scal(1)
qs_control%xtb_control%kx2 = scal(2)
! Kab
CALL section_vals_val_get(xtb_parameter, "KAB_PARAM", n_rep_val=n_rep)
! XB_radius
CALL section_vals_val_get(xtb_parameter, "XB_RADIUS", r_val=qs_control%xtb_control%xb_radius)
! Kab
CALL section_vals_val_get(xtb_parameter, "KAB_PARAM", n_rep_val=n_rep)
IF (n_rep > 0) THEN
ALLOCATE (qs_control%xtb_control%kab_param(3, n_rep))
DO j = 1, n_rep
Expand Down
12 changes: 9 additions & 3 deletions src/input_cp2k_tb.F
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ MODULE input_cp2k_tb
!qxtb citation
USE bibliography, ONLY: Elstner1998,&
Hu2007,&
Grimme2017,&
Porezag1995,&
Seifert1996,&
Zhechkov2005
Expand Down Expand Up @@ -133,9 +134,8 @@ SUBROUTINE create_xtb_control_section(section)
CPASSERT(.NOT. ASSOCIATED(section))
CALL section_create(section, "xTB", &
description="Parameters needed to set up the xTB methods", &
n_keywords=1, n_subsections=1, repeats=.FALSE.)
!qxtb n_keywords=1, n_subsections=1, repeats=.FALSE., &
!qxtb citations=(/GRIMME2017/))
n_keywords=1, n_subsections=1, repeats=.FALSE., &
citations=(/GRIMME2017/))

NULLIFY (subsection)
CALL create_xtb_parameter_section(subsection)
Expand All @@ -159,6 +159,12 @@ SUBROUTINE create_xtb_control_section(section)
CALL section_add_keyword(section, keyword)
CALL keyword_release(keyword)

CALL keyword_create(keyword, name="USE_HALOGEN_CORRECTION", &
description="Use XB interaction term", &
usage="USE_HALOGEN_CORRECTION", default_l_val=.TRUE.)
CALL section_add_keyword(section, keyword)
CALL keyword_release(keyword)

END SUBROUTINE create_xtb_control_section

! **************************************************************************************************
Expand Down
2 changes: 1 addition & 1 deletion src/qs_neighbor_lists.F
Original file line number Diff line number Diff line change
Expand Up @@ -797,7 +797,7 @@ SUBROUTINE build_qs_neighbor_lists(qs_env, para_env, molecular, force_env_sectio
END DO
CALL pair_radius_setup(xb1_atom, xb2_atom, c_radius, c_radius, pair_radius)
CALL build_neighbor_lists(sab_xb, particle_set, atom2d, cell, pair_radius, &
subcells=subcells, operator_type="PP", nlname="sab_xb")
symmetric=.FALSE., subcells=subcells, operator_type="PP", nlname="sab_xb")
CALL set_ks_env(ks_env=ks_env, sab_xb=sab_xb)
END IF

Expand Down

0 comments on commit 48e8a07

Please sign in to comment.