83 SUBROUTINE build_core_ae(matrix_h, matrix_p, force, virial, calculate_forces, use_virial, nder, &
84 qs_kind_set, atomic_kind_set, particle_set, sab_orb, sac_ae, &
85 nimages, cell_to_index, atcore)
87 TYPE(
dbcsr_p_type),
DIMENSION(:, :),
POINTER :: matrix_h, matrix_p
90 LOGICAL,
INTENT(IN) :: calculate_forces
97 POINTER :: sab_orb, sac_ae
98 INTEGER,
INTENT(IN) :: nimages
99 INTEGER,
DIMENSION(:, :, :),
POINTER :: cell_to_index
100 REAL(kind=
dp),
DIMENSION(:),
INTENT(INOUT), &
103 CHARACTER(LEN=*),
PARAMETER :: routinen =
'build_core_ae'
105 INTEGER :: atom_a, handle, iatom, icol, ikind, img, irow, iset, jatom, jkind, jset, katom, &
106 kkind, ldai, ldsab, maxco, maxl, maxnset, maxsgf, mepos, na_plus, natom, nb_plus, ncoa, &
107 ncob, nij, nkind, nseta, nsetb, nthread, sgfa, sgfb, slot
108 INTEGER,
ALLOCATABLE,
DIMENSION(:) :: atom_of_kind, kind_of
109 INTEGER,
DIMENSION(3) :: cellind
110 INTEGER,
DIMENSION(:),
POINTER :: la_max, la_min, lb_max, lb_min, npgfa, &
112 INTEGER,
DIMENSION(:, :),
POINTER :: first_sgfa, first_sgfb
113 LOGICAL :: doat, dokp, found
114 REAL(kind=
dp) :: alpha_c, atk0, atk1, core_charge, &
115 core_radius, dab, dac, dbc, f0, rab2, &
117 REAL(kind=
dp),
ALLOCATABLE,
DIMENSION(:) :: ff
118 REAL(kind=
dp),
ALLOCATABLE,
DIMENSION(:, :) :: habd, work
119 REAL(kind=
dp),
ALLOCATABLE,
DIMENSION(:, :, :) :: hab, pab, verf, vnuc
120 REAL(kind=
dp),
DIMENSION(3) :: force_a, force_b, rab, rac, rbc
121 REAL(kind=
dp),
DIMENSION(3, 3) :: pv_thread
123 DIMENSION(:),
POINTER :: ap_iterator
127 REAL(kind=
dp),
DIMENSION(SIZE(particle_set)) :: at_thread
128 REAL(kind=
dp),
DIMENSION(:, :),
POINTER :: h_block, p_block, rpgfa, rpgfb, sphi_a, &
130 REAL(kind=
dp),
DIMENSION(:),
POINTER :: set_radius_a, set_radius_b
131 REAL(kind=
dp),
DIMENSION(3, SIZE(particle_set)) :: force_thread
142 IF (calculate_forces)
THEN
143 CALL timeset(routinen//
"_forces", handle)
145 CALL timeset(routinen, handle)
148 nkind =
SIZE(atomic_kind_set)
149 natom =
SIZE(particle_set)
151 doat =
PRESENT(atcore)
154 IF (calculate_forces .OR. doat)
THEN
155 IF (
SIZE(matrix_p, 1) == 2)
THEN
157 CALL dbcsr_add(matrix_p(1, img)%matrix, matrix_p(2, img)%matrix, &
158 alpha_scalar=1.0_dp, beta_scalar=1.0_dp)
159 CALL dbcsr_add(matrix_p(2, img)%matrix, matrix_p(1, img)%matrix, &
160 alpha_scalar=-2.0_dp, beta_scalar=1.0_dp)
165 force_thread = 0.0_dp
169 ALLOCATE (basis_set_list(nkind))
171 CALL get_qs_kind(qs_kind_set(ikind), basis_set=basis_set_a)
172 IF (
ASSOCIATED(basis_set_a))
THEN
173 basis_set_list(ikind)%gto_basis_set => basis_set_a
175 NULLIFY (basis_set_list(ikind)%gto_basis_set)
180 maxco=maxco, maxlgto=maxl, maxsgf=maxsgf, maxnset=maxnset)
182 ldsab = max(maxco, maxsgf)
183 ldai =
ncoset(maxl + nder + 1)
221 ALLOCATE (hab(ldsab, ldsab, maxnset*maxnset), work(ldsab, ldsab))
222 ALLOCATE (verf(ldai, ldai, 2*maxl + nder + 1), vnuc(ldai, ldai, 2*maxl + nder + 1), ff(0:2*maxl + nder))
223 IF (calculate_forces .OR. doat)
THEN
224 ALLOCATE (pab(maxco, maxco, maxnset*maxnset))
228 DO slot = 1, sab_orb(1)%nl_size
230 ikind = sab_orb(1)%nlist_task(slot)%ikind
231 jkind = sab_orb(1)%nlist_task(slot)%jkind
232 iatom = sab_orb(1)%nlist_task(slot)%iatom
233 jatom = sab_orb(1)%nlist_task(slot)%jatom
234 cellind(:) = sab_orb(1)%nlist_task(slot)%cell(:)
235 rab(1:3) = sab_orb(1)%nlist_task(slot)%r(1:3)
237 basis_set_a => basis_set_list(ikind)%gto_basis_set
238 IF (.NOT.
ASSOCIATED(basis_set_a)) cycle
239 basis_set_b => basis_set_list(jkind)%gto_basis_set
240 IF (.NOT.
ASSOCIATED(basis_set_b)) cycle
244 first_sgfa => basis_set_a%first_sgf
245 la_max => basis_set_a%lmax
246 la_min => basis_set_a%lmin
247 npgfa => basis_set_a%npgf
248 nseta = basis_set_a%nset
249 nsgfa => basis_set_a%nsgf_set
250 rpgfa => basis_set_a%pgf_radius
251 set_radius_a => basis_set_a%set_radius
252 sphi_a => basis_set_a%sphi
253 zeta => basis_set_a%zet
255 first_sgfb => basis_set_b%first_sgf
256 lb_max => basis_set_b%lmax
257 lb_min => basis_set_b%lmin
258 npgfb => basis_set_b%npgf
259 nsetb = basis_set_b%nset
260 nsgfb => basis_set_b%nsgf_set
261 rpgfb => basis_set_b%pgf_radius
262 set_radius_b => basis_set_b%set_radius
263 sphi_b => basis_set_b%sphi
264 zetb => basis_set_b%zet
266 dab = sqrt(sum(rab*rab))
269 img = cell_to_index(cellind(1), cellind(2), cellind(3))
275 IF (iatom == jatom)
THEN
282 IF (iatom <= jatom)
THEN
291 row=irow, col=icol, block=h_block, found=found)
292 IF (calculate_forces .OR. doat)
THEN
295 row=irow, col=icol, block=p_block, found=found)
296 cpassert(
ASSOCIATED(p_block))
299 ncoa = npgfa(iset)*
ncoset(la_max(iset))
300 sgfa = first_sgfa(1, iset)
302 ncob = npgfb(jset)*
ncoset(lb_max(jset))
303 sgfb = first_sgfb(1, jset)
304 nij = jset + (iset - 1)*maxnset
306 IF (iatom <= jatom)
THEN
307 work(1:ncoa, 1:nsgfb(jset)) = matmul(sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1), &
308 p_block(sgfa:sgfa + nsgfa(iset) - 1, sgfb:sgfb + nsgfb(jset) - 1))
310 work(1:ncoa, 1:nsgfb(jset)) = matmul(sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1), &
311 transpose(p_block(sgfb:sgfb + nsgfb(jset) - 1, sgfa:sgfa + nsgfa(iset) - 1)))
313 pab(1:ncoa, 1:ncob, nij) = matmul(work(1:ncoa, 1:nsgfb(jset)), &
314 transpose(sphi_b(1:ncob, sgfb:sgfb + nsgfb(jset) - 1)))
322 CALL get_qs_kind(qs_kind_set(kkind), all_potential=all_potential, &
323 sgp_potential=sgp_potential)
324 IF (
ASSOCIATED(all_potential))
THEN
326 alpha_core_charge=alpha_c, zeff=zeta_c, &
327 ccore_charge=core_charge, core_charge_radius=core_radius)
328 ELSE IF (
ASSOCIATED(sgp_potential))
THEN
330 alpha_core_charge=alpha_c, zeff=zeta_c, &
331 ccore_charge=core_charge, core_charge_radius=core_radius)
341 dac = sqrt(sum(rac*rac))
342 rbc(:) = rac(:) - rab(:)
343 dbc = sqrt(sum(rbc*rbc))
344 IF ((maxval(set_radius_a(:)) + core_radius < dac) .OR. &
345 (maxval(set_radius_b(:)) + core_radius < dbc))
THEN
350 IF (set_radius_a(iset) + core_radius < dac) cycle
351 ncoa = npgfa(iset)*
ncoset(la_max(iset))
352 sgfa = first_sgfa(1, iset)
354 IF (set_radius_b(jset) + core_radius < dbc) cycle
355 ncob = npgfb(jset)*
ncoset(lb_max(jset))
356 sgfb = first_sgfb(1, jset)
357 IF (set_radius_a(iset) + set_radius_b(jset) < dab) cycle
361 nij = jset + (iset - 1)*maxnset
364 atk0 = f0*sum(hab(1:ncoa, 1:ncob, nij)*pab(1:ncoa, 1:ncob, nij))
366 IF (calculate_forces)
THEN
367 na_plus = npgfa(iset)*
ncoset(la_max(iset) + nder)
368 nb_plus = npgfb(jset)*
ncoset(lb_max(jset))
369 ALLOCATE (habd(na_plus, nb_plus))
372 la_max(iset) + nder, npgfa(iset), zeta(:, iset), rpgfa(:, iset), la_min(iset), &
373 lb_max(jset), npgfb(jset), zetb(:, jset), rpgfb(:, jset), lb_min(jset), &
374 alpha_c, core_radius, zeta_c, core_charge, &
375 rab, rab2, rac, rac2, rbc2, hab(:, :, nij), verf, vnuc, ff(0:), &
381 CALL verfc_force(habd, pab(:, :, nij), force_a, force_b, nder, &
382 la_max(iset), la_min(iset), npgfa(iset), zeta(:, iset), &
383 lb_max(jset), lb_min(jset), npgfb(jset), zetb(:, jset), rab)
387 force_thread(1, iatom) = force_thread(1, iatom) + f0*force_a(1)
388 force_thread(2, iatom) = force_thread(2, iatom) + f0*force_a(2)
389 force_thread(3, iatom) = force_thread(3, iatom) + f0*force_a(3)
391 force_thread(1, jatom) = force_thread(1, jatom) + f0*force_b(1)
392 force_thread(2, jatom) = force_thread(2, jatom) + f0*force_b(2)
393 force_thread(3, jatom) = force_thread(3, jatom) + f0*force_b(3)
395 force_thread(1, katom) = force_thread(1, katom) - f0*force_a(1) - f0*force_b(1)
396 force_thread(2, katom) = force_thread(2, katom) - f0*force_a(2) - f0*force_b(2)
397 force_thread(3, katom) = force_thread(3, katom) - f0*force_a(3) - f0*force_b(3)
405 la_max(iset), npgfa(iset), zeta(:, iset), rpgfa(:, iset), la_min(iset), &
406 lb_max(jset), npgfb(jset), zetb(:, jset), rpgfb(:, jset), lb_min(jset), &
407 alpha_c, core_radius, zeta_c, core_charge, &
408 rab, rab2, rac, rac2, rbc2, hab(:, :, nij), verf, vnuc, ff(0:))
412 atk1 = f0*sum(hab(1:ncoa, 1:ncob, nij)*pab(1:ncoa, 1:ncob, nij))
413 at_thread(katom) = at_thread(katom) + (atk1 - atk0)
421 ncoa = npgfa(iset)*
ncoset(la_max(iset))
422 sgfa = first_sgfa(1, iset)
424 ncob = npgfb(jset)*
ncoset(lb_max(jset))
425 sgfb = first_sgfb(1, jset)
426 nij = jset + (iset - 1)*maxnset
429 work(1:ncoa, 1:nsgfb(jset)) = matmul(hab(1:ncoa, 1:ncob, nij), &
430 sphi_b(1:ncob, sgfb:sgfb + nsgfb(jset) - 1))
432 IF (iatom <= jatom)
THEN
433 h_block(sgfa:sgfa + nsgfa(iset) - 1, sgfb:sgfb + nsgfb(jset) - 1) = &
434 h_block(sgfa:sgfa + nsgfa(iset) - 1, sgfb:sgfb + nsgfb(jset) - 1) + &
435 matmul(transpose(sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1)), work(1:ncoa, 1:nsgfb(jset)))
437 h_block(sgfb:sgfb + nsgfb(jset) - 1, sgfa:sgfa + nsgfa(iset) - 1) = &
438 h_block(sgfb:sgfb + nsgfb(jset) - 1, sgfa:sgfa + nsgfa(iset) - 1) + &
439 matmul(transpose(work(1:ncoa, 1:nsgfb(jset))), sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1))
447 DEALLOCATE (hab, work, verf, vnuc, ff)
448 IF (calculate_forces .OR. doat)
THEN
466 DEALLOCATE (basis_set_list)
468 IF (calculate_forces .OR. doat)
THEN
471 IF (
SIZE(matrix_p, 1) == 2)
THEN
473 CALL dbcsr_add(matrix_p(1, img)%matrix, matrix_p(2, img)%matrix, &
474 alpha_scalar=0.5_dp, beta_scalar=0.5_dp)
475 CALL dbcsr_add(matrix_p(2, img)%matrix, matrix_p(1, img)%matrix, &
476 alpha_scalar=-1.0_dp, beta_scalar=1.0_dp)
481 IF (calculate_forces)
THEN
485 atom_a = atom_of_kind(iatom)
486 ikind = kind_of(iatom)
487 force(ikind)%all_potential(:, atom_a) = force(ikind)%all_potential(:, atom_a) + force_thread(:, iatom)
492 atcore(1:natom) = atcore(1:natom) + at_thread(1:natom)
495 IF (calculate_forces .AND. use_virial)
THEN
496 virial%pv_ppl = virial%pv_ppl + pv_thread
497 virial%pv_virial = virial%pv_virial + pv_thread
500 CALL timestop(handle)
605 SUBROUTINE build_erfc(matrix_h, matrix_p, qs_kind_set, atomic_kind_set, particle_set, &
606 calpha, ccore, eps_core_charge, sab_orb, sac_ae, atcore)
610 TYPE(
qs_kind_type),
DIMENSION(:),
POINTER :: qs_kind_set
613 REAL(kind=
dp),
DIMENSION(:),
INTENT(IN) :: calpha, ccore
614 REAL(kind=
dp),
INTENT(IN) :: eps_core_charge
616 POINTER :: sab_orb, sac_ae
617 REAL(kind=
dp),
DIMENSION(:),
INTENT(INOUT), &
620 CHARACTER(LEN=*),
PARAMETER :: routinen =
'build_erfc'
622 INTEGER :: handle, iatom, icol, ikind, img, irow, iset, jatom, jkind, jset, katom, kkind, &
623 ldai, ldsab, maxco, maxl, maxnset, maxsgf, mepos, na_plus, natom, nb_plus, ncoa, ncob, &
624 nij, nkind, nseta, nsetb, nthread, sgfa, sgfb, slot
625 INTEGER,
DIMENSION(3) :: cellind
626 INTEGER,
DIMENSION(:),
POINTER :: la_max, la_min, lb_max, lb_min, npgfa, &
628 INTEGER,
DIMENSION(:, :),
POINTER :: first_sgfa, first_sgfb
629 LOGICAL :: doat, found
630 REAL(kind=
dp) :: alpha_c, atk0, atk1, core_charge, &
631 core_radius, dab, dac, dbc, f0, rab2, &
633 REAL(kind=
dp),
ALLOCATABLE,
DIMENSION(:) :: ff
634 REAL(kind=
dp),
ALLOCATABLE,
DIMENSION(:, :) :: habd, work
635 REAL(kind=
dp),
ALLOCATABLE,
DIMENSION(:, :, :) :: hab, pab, verf, vnuc
636 REAL(kind=
dp),
DIMENSION(3) :: rab, rac, rbc
637 REAL(kind=
dp),
DIMENSION(:),
POINTER :: set_radius_a, set_radius_b
638 REAL(kind=
dp),
DIMENSION(:, :),
POINTER :: h_block, p_block, rpgfa, rpgfb, sphi_a, &
641 DIMENSION(:),
POINTER :: ap_iterator
645 REAL(kind=
dp),
DIMENSION(SIZE(particle_set)) :: at_thread
656 CALL timeset(routinen, handle)
658 nkind =
SIZE(atomic_kind_set)
659 natom =
SIZE(particle_set)
661 doat =
PRESENT(atcore)
664 IF (
SIZE(matrix_p, 1) == 2)
THEN
665 CALL dbcsr_add(matrix_p(1)%matrix, matrix_p(2)%matrix, &
666 alpha_scalar=1.0_dp, beta_scalar=1.0_dp)
667 CALL dbcsr_add(matrix_p(2)%matrix, matrix_p(1)%matrix, &
668 alpha_scalar=-2.0_dp, beta_scalar=1.0_dp)
674 ALLOCATE (basis_set_list(nkind))
676 CALL get_qs_kind(qs_kind_set(ikind), basis_set=basis_set_a)
677 IF (
ASSOCIATED(basis_set_a))
THEN
678 basis_set_list(ikind)%gto_basis_set => basis_set_a
680 NULLIFY (basis_set_list(ikind)%gto_basis_set)
685 maxco=maxco, maxlgto=maxl, maxsgf=maxsgf, maxnset=maxnset)
687 ldsab = max(maxco, maxsgf)
726 ALLOCATE (hab(ldsab, ldsab, maxnset*maxnset), work(ldsab, ldsab))
727 ALLOCATE (verf(ldai, ldai, 2*maxl + 1), vnuc(ldai, ldai, 2*maxl + 1), ff(0:2*maxl))
729 ALLOCATE (pab(maxco, maxco, maxnset*maxnset))
733 DO slot = 1, sab_orb(1)%nl_size
735 ikind = sab_orb(1)%nlist_task(slot)%ikind
736 jkind = sab_orb(1)%nlist_task(slot)%jkind
737 iatom = sab_orb(1)%nlist_task(slot)%iatom
738 jatom = sab_orb(1)%nlist_task(slot)%jatom
739 cellind(:) = sab_orb(1)%nlist_task(slot)%cell(:)
740 rab(1:3) = sab_orb(1)%nlist_task(slot)%r(1:3)
742 basis_set_a => basis_set_list(ikind)%gto_basis_set
743 IF (.NOT.
ASSOCIATED(basis_set_a)) cycle
744 basis_set_b => basis_set_list(jkind)%gto_basis_set
745 IF (.NOT.
ASSOCIATED(basis_set_b)) cycle
749 first_sgfa => basis_set_a%first_sgf
750 la_max => basis_set_a%lmax
751 la_min => basis_set_a%lmin
752 npgfa => basis_set_a%npgf
753 nseta = basis_set_a%nset
754 nsgfa => basis_set_a%nsgf_set
755 rpgfa => basis_set_a%pgf_radius
756 set_radius_a => basis_set_a%set_radius
757 sphi_a => basis_set_a%sphi
758 zeta => basis_set_a%zet
760 first_sgfb => basis_set_b%first_sgf
761 lb_max => basis_set_b%lmax
762 lb_min => basis_set_b%lmin
763 npgfb => basis_set_b%npgf
764 nsetb = basis_set_b%nset
765 nsgfb => basis_set_b%nsgf_set
766 rpgfb => basis_set_b%pgf_radius
767 set_radius_b => basis_set_b%set_radius
768 sphi_b => basis_set_b%sphi
769 zetb => basis_set_b%zet
771 dab = sqrt(sum(rab*rab))
775 IF (iatom == jatom)
THEN
782 IF (iatom <= jatom)
THEN
791 row=irow, col=icol, block=h_block, found=found)
795 row=irow, col=icol, block=p_block, found=found)
796 cpassert(
ASSOCIATED(p_block))
799 ncoa = npgfa(iset)*
ncoset(la_max(iset))
800 sgfa = first_sgfa(1, iset)
802 ncob = npgfb(jset)*
ncoset(lb_max(jset))
803 sgfb = first_sgfb(1, jset)
804 nij = jset + (iset - 1)*maxnset
806 IF (iatom <= jatom)
THEN
807 work(1:ncoa, 1:nsgfb(jset)) = matmul(sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1), &
808 p_block(sgfa:sgfa + nsgfa(iset) - 1, sgfb:sgfb + nsgfb(jset) - 1))
810 work(1:ncoa, 1:nsgfb(jset)) = matmul(sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1), &
811 transpose(p_block(sgfb:sgfb + nsgfb(jset) - 1, sgfa:sgfa + nsgfa(iset) - 1)))
813 pab(1:ncoa, 1:ncob, nij) = matmul(work(1:ncoa, 1:nsgfb(jset)), &
814 transpose(sphi_b(1:ncob, sgfb:sgfb + nsgfb(jset) - 1)))
823 alpha_c = calpha(kkind)
824 core_charge = ccore(kkind)
825 core_radius =
exp_radius(0, alpha_c, eps_core_charge, core_charge)
826 core_radius = max(core_radius, 10.0_dp)
833 dac = sqrt(sum(rac*rac))
834 rbc(:) = rac(:) - rab(:)
835 dbc = sqrt(sum(rbc*rbc))
836 IF ((maxval(set_radius_a(:)) + core_radius < dac) .OR. &
837 (maxval(set_radius_b(:)) + core_radius < dbc))
THEN
842 IF (set_radius_a(iset) + core_radius < dac) cycle
843 ncoa = npgfa(iset)*
ncoset(la_max(iset))
844 sgfa = first_sgfa(1, iset)
846 IF (set_radius_b(jset) + core_radius < dbc) cycle
847 ncob = npgfb(jset)*
ncoset(lb_max(jset))
848 sgfb = first_sgfb(1, jset)
849 IF (set_radius_a(iset) + set_radius_b(jset) < dab) cycle
853 nij = jset + (iset - 1)*maxnset
855 atk0 = f0*sum(hab(1:ncoa, 1:ncob, nij)*pab(1:ncoa, 1:ncob, nij))
859 la_max(iset), npgfa(iset), zeta(:, iset), rpgfa(:, iset), la_min(iset), &
860 lb_max(jset), npgfb(jset), zetb(:, jset), rpgfb(:, jset), lb_min(jset), &
861 alpha_c, core_radius, zeta_c, core_charge, &
862 rab, rab2, rac, rac2, rbc2, hab(:, :, nij), verf, vnuc, ff(0:))
865 atk1 = f0*sum(hab(1:ncoa, 1:ncob, nij)*pab(1:ncoa, 1:ncob, nij))
866 at_thread(katom) = at_thread(katom) + (atk1 - atk0)
874 ncoa = npgfa(iset)*
ncoset(la_max(iset))
875 sgfa = first_sgfa(1, iset)
877 ncob = npgfb(jset)*
ncoset(lb_max(jset))
878 sgfb = first_sgfb(1, jset)
879 nij = jset + (iset - 1)*maxnset
882 work(1:ncoa, 1:nsgfb(jset)) = matmul(hab(1:ncoa, 1:ncob, nij), &
883 sphi_b(1:ncob, sgfb:sgfb + nsgfb(jset) - 1))
885 IF (iatom <= jatom)
THEN
886 h_block(sgfa:sgfa + nsgfa(iset) - 1, sgfb:sgfb + nsgfb(jset) - 1) = &
887 h_block(sgfa:sgfa + nsgfa(iset) - 1, sgfb:sgfb + nsgfb(jset) - 1) + &
888 matmul(transpose(sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1)), work(1:ncoa, 1:nsgfb(jset)))
890 h_block(sgfb:sgfb + nsgfb(jset) - 1, sgfa:sgfa + nsgfa(iset) - 1) = &
891 h_block(sgfb:sgfb + nsgfb(jset) - 1, sgfa:sgfa + nsgfa(iset) - 1) + &
892 matmul(transpose(work(1:ncoa, 1:nsgfb(jset))), sphi_a(1:ncoa, sgfa:sgfa + nsgfa(iset) - 1))
900 DEALLOCATE (hab, work, verf, vnuc, ff)
916 DEALLOCATE (basis_set_list)
921 IF (
SIZE(matrix_p, 1) == 2)
THEN
922 CALL dbcsr_add(matrix_p(1)%matrix, matrix_p(2)%matrix, &
923 alpha_scalar=0.5_dp, beta_scalar=0.5_dp)
924 CALL dbcsr_add(matrix_p(2)%matrix, matrix_p(1)%matrix, &
925 alpha_scalar=-1.0_dp, beta_scalar=1.0_dp)
930 atcore(1:natom) = atcore(1:natom) + at_thread(1:natom)
933 CALL timestop(handle)
subroutine, public get_qs_kind(qs_kind, basis_set, basis_type, ncgf, nsgf, all_potential, tnadd_potential, gth_potential, sgp_potential, upf_potential, se_parameter, dftb_parameter, xtb_parameter, dftb3_param, zatom, zeff, elec_conf, mao, lmax_dftb, alpha_core_charge, ccore_charge, core_charge, core_charge_radius, paw_proj_set, paw_atom, hard_radius, hard0_radius, max_rad_local, covalent_radius, vdw_radius, gpw_type_forced, harmonics, max_iso_not0, max_s_harm, grid_atom, ngrid_ang, ngrid_rad, lmax_rho0, dft_plus_u_atom, l_of_dft_plus_u, n_of_dft_plus_u, u_minus_j, u_of_dft_plus_u, j_of_dft_plus_u, alpha_of_dft_plus_u, beta_of_dft_plus_u, j0_of_dft_plus_u, occupation_of_dft_plus_u, dispersion, bs_occupation, magnetization, no_optimize, addel, laddel, naddel, orbitals, max_scf, eps_scf, smear, u_ramping, u_minus_j_target, eps_u_ramping, init_u_ramping_each_scf, reltmat, ghost, floating, name, element_symbol, pao_basis_size, pao_model_file, pao_potentials, pao_descriptors, nelec)
Get attributes of an atomic kind.