9
1
mirror of https://github.com/QuantumPackage/qp2.git synced 2024-12-30 15:15:38 +01:00

Boys & Handy Jastrow: OK

This commit is contained in:
AbdAmmar 2024-02-16 16:45:54 +01:00
parent 9dc8c0653d
commit 6fa207a9fb
2 changed files with 8 additions and 19 deletions

View File

@ -113,10 +113,8 @@ subroutine get_grad1_u12_withsq_r1_seq(ipoint, n_grid2, resx, resy, resz, res)
PROVIDE jBH_size jBH_en jBH_ee jBH_m jBH_n jBH_o jBH_c PROVIDE jBH_size jBH_en jBH_ee jBH_m jBH_n jBH_o jBH_c
if(env_type .ne. "None") then if(env_type .eq. "None") then
call grad1_j12_r1_seq(r1, n_grid2, resx, resy, resz) call grad1_j12_r1_seq(r1, n_grid2, resx, resy, resz)
endif ! env_type endif ! env_type
else else

View File

@ -22,6 +22,9 @@ subroutine rh_tcscf_diis()
logical, external :: qp_stop logical, external :: qp_stop
PROVIDE level_shift_TCSCF
PROVIDE mo_l_coef mo_r_coef
it = 0 it = 0
e_save = 0.d0 e_save = 0.d0
dim_DIIS = 0 dim_DIIS = 0
@ -41,19 +44,6 @@ subroutine rh_tcscf_diis()
! --- ! ---
PROVIDE level_shift_TCSCF
PROVIDE mo_l_coef mo_r_coef
!write(6, '(A4,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A4, 1X, A8)') &
! '====', '================', '================', '================', '================', '================' &
! , '================', '================', '================', '====', '========'
!write(6, '(A4,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A4, 1X, A8)') &
! ' it ', ' SCF TC Energy ', ' E(1e) ', ' E(2e) ', ' E(3e) ', ' energy diff ' &
! , ' gradient ', ' DIIS error ', ' level shift ', 'DIIS', ' WT (m)'
!write(6, '(A4,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A4, 1X, A8)') &
! '====', '================', '================', '================', '================', '================' &
! , '================', '================', '================', '====', '========'
write(6, '(A4,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A4, 1X, A8)') & write(6, '(A4,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A16,1X, A4, 1X, A8)') &
'====', '================', '================', '================', '================', '================' & '====', '================', '================', '================', '================', '================' &
, '================', '================', '====', '========' , '================', '================', '====', '========'
@ -81,8 +71,6 @@ subroutine rh_tcscf_diis()
er_save = er_DIIS er_save = er_DIIS
call wall_time(t1) call wall_time(t1)
!write(6, '(I4,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, I4,1X, F8.2)') &
! it, etc_tot, etc_1e, etc_2e, etc_3e, e_delta, tc_grad, er_DIIS, level_shift_tcscf, dim_DIIS, (t1-t0)/60.d0
write(6, '(I4,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, I4,1X, F8.2)') & write(6, '(I4,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, F16.10,1X, I4,1X, F8.2)') &
it, etc_tot, etc_1e, etc_2e, etc_3e, e_delta, er_DIIS, level_shift_tcscf, dim_DIIS, (t1-t0)/60.d0 it, etc_tot, etc_1e, etc_2e, etc_3e, e_delta, er_DIIS, level_shift_tcscf, dim_DIIS, (t1-t0)/60.d0
@ -91,6 +79,8 @@ subroutine rh_tcscf_diis()
PROVIDE FQS_SQF_ao Fock_matrix_tc_ao_tot PROVIDE FQS_SQF_ao Fock_matrix_tc_ao_tot
converged = .false. converged = .false.
call ezfio_set_tc_scf_converged_tcscf(converged)
!do while((tc_grad .gt. dsqrt(thresh_tcscf)) .and. (er_DIIS .gt. dsqrt(thresh_tcscf))) !do while((tc_grad .gt. dsqrt(thresh_tcscf)) .and. (er_DIIS .gt. dsqrt(thresh_tcscf)))
do while(.not. converged) do while(.not. converged)
@ -253,8 +243,9 @@ subroutine rh_tcscf_diis()
endif endif
call lock_io call lock_io
if (converged) then if(converged) then
write(json_unit, json_true_fmtx) 'converged' write(json_unit, json_true_fmtx) 'converged'
call ezfio_set_tc_scf_converged_tcscf(converged)
else else
write(json_unit, json_false_fmtx) 'converged' write(json_unit, json_false_fmtx) 'converged'
endif endif