mirror of
https://github.com/QuantumPackage/qp2.git
synced 2024-11-19 04:22:32 +01:00
Merge branch 'dev-stable' of github.com:QuantumPackage/qp2 into dev-stable
This commit is contained in:
commit
af120b30c5
2
external/qp2-dependencies
vendored
2
external/qp2-dependencies
vendored
@ -1 +1 @@
|
|||||||
Subproject commit b8cd5815bce14c9b880e3c5ea3d5fc2652f5955c
|
Subproject commit f40bde0925808bbec0424b57bfcef1b26473a1c8
|
@ -66,10 +66,27 @@ subroutine v_rho_oc_to_v_rho_ab(v_rho_o,v_rho_c,v_rho_a,v_rho_b)
|
|||||||
END_DOC
|
END_DOC
|
||||||
double precision, intent(in) :: v_rho_o,v_rho_c
|
double precision, intent(in) :: v_rho_o,v_rho_c
|
||||||
double precision, intent(out) :: v_rho_a,v_rho_b
|
double precision, intent(out) :: v_rho_a,v_rho_b
|
||||||
|
! print*,'in v_rho_oc_to_v_rho_ab'
|
||||||
|
! print*, v_rho_c , v_rho_o
|
||||||
v_rho_a = v_rho_c + v_rho_o
|
v_rho_a = v_rho_c + v_rho_o
|
||||||
v_rho_b = v_rho_c - v_rho_o
|
v_rho_b = v_rho_c - v_rho_o
|
||||||
end
|
end
|
||||||
|
|
||||||
|
subroutine v_grad_rho_ab_to_v_grad_rho_oc(v_grad_rho_a_2,v_grad_rho_b_2,v_grad_rho_a_b,v_grad_rho_o_2,v_grad_rho_c_2,v_grad_rho_o_c)
|
||||||
|
implicit none
|
||||||
|
double precision, intent(in) :: v_grad_rho_a_2,v_grad_rho_b_2,v_grad_rho_a_b
|
||||||
|
double precision, intent(out) :: v_grad_rho_o_2,v_grad_rho_c_2,v_grad_rho_o_c
|
||||||
|
BEGIN_DOC
|
||||||
|
! convert (v_grad_rho_a_2, v_grad_rho_b_2, v_grad_rho_a.grad_rho_b)
|
||||||
|
!
|
||||||
|
! to (v_grad_rho_c_2, v_grad_rho_o_2, v_grad_rho_o.grad_rho_c)
|
||||||
|
!
|
||||||
|
! rho_c = total density, rho_o spin density
|
||||||
|
END_DOC
|
||||||
|
v_grad_rho_c_2 = 0.25d0 * (v_grad_rho_a_2 + v_grad_rho_b_2 + v_grad_rho_a_b)
|
||||||
|
v_grad_rho_o_2 = 0.25d0 * (v_grad_rho_a_2 + v_grad_rho_b_2 - v_grad_rho_a_b)
|
||||||
|
v_grad_rho_o_c = 0.25d0 * (2d0 * v_grad_rho_a_2 - 2d0 * v_grad_rho_b_2 )
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
subroutine v_grad_rho_oc_to_v_grad_rho_ab(v_grad_rho_o_2,v_grad_rho_c_2,v_grad_rho_o_c,v_grad_rho_a_2,v_grad_rho_b_2,v_grad_rho_a_b)
|
subroutine v_grad_rho_oc_to_v_grad_rho_ab(v_grad_rho_o_2,v_grad_rho_c_2,v_grad_rho_o_c,v_grad_rho_a_2,v_grad_rho_b_2,v_grad_rho_a_b)
|
||||||
@ -88,21 +105,3 @@ subroutine v_grad_rho_oc_to_v_grad_rho_ab(v_grad_rho_o_2,v_grad_rho_c_2,v_grad_r
|
|||||||
v_grad_rho_a_b = -2d0 * v_grad_rho_o_2 + 2d0 * v_grad_rho_c_2
|
v_grad_rho_a_b = -2d0 * v_grad_rho_o_2 + 2d0 * v_grad_rho_c_2
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -45,6 +45,8 @@
|
|||||||
call density_and_grad_alpha_beta_and_all_aos_and_grad_aos_at_r(r,dm_a,dm_b, dm_a_grad, dm_b_grad, aos_array, grad_aos_array)
|
call density_and_grad_alpha_beta_and_all_aos_and_grad_aos_at_r(r,dm_a,dm_b, dm_a_grad, dm_b_grad, aos_array, grad_aos_array)
|
||||||
|
|
||||||
! alpha/beta density
|
! alpha/beta density
|
||||||
|
dm_a(istate) = max(dm_a(istate),1.d-12)
|
||||||
|
dm_b(istate) = max(dm_b(istate),1.d-12)
|
||||||
one_e_dm_and_grad_alpha_in_r(4,i,istate) = dm_a(istate)
|
one_e_dm_and_grad_alpha_in_r(4,i,istate) = dm_a(istate)
|
||||||
one_e_dm_and_grad_beta_in_r(4,i,istate) = dm_b(istate)
|
one_e_dm_and_grad_beta_in_r(4,i,istate) = dm_b(istate)
|
||||||
|
|
||||||
@ -80,6 +82,7 @@
|
|||||||
enddo
|
enddo
|
||||||
enddo
|
enddo
|
||||||
!$OMP END PARALLEL DO
|
!$OMP END PARALLEL DO
|
||||||
|
print*,'density and gradients provided'
|
||||||
|
|
||||||
END_PROVIDER
|
END_PROVIDER
|
||||||
|
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
else
|
else
|
||||||
ref_tc_energy_3e = 0.d0
|
ref_tc_energy_3e = 0.d0
|
||||||
endif
|
endif
|
||||||
ref_tc_energy_tot = ref_tc_energy_1e + ref_tc_energy_2e + ref_tc_energy_3e
|
ref_tc_energy_tot = ref_tc_energy_1e + ref_tc_energy_2e + ref_tc_energy_3e + nuclear_repulsion
|
||||||
END_PROVIDER
|
END_PROVIDER
|
||||||
|
|
||||||
subroutine diag_htilde_mu_mat_fock_bi_ortho(Nint, det_in, hmono, htwoe, hthree, htot)
|
subroutine diag_htilde_mu_mat_fock_bi_ortho(Nint, det_in, hmono, htwoe, hthree, htot)
|
||||||
|
@ -17,6 +17,7 @@ subroutine routine_active_only
|
|||||||
double precision :: wee_ab_st_av, rdm_ab_st_av
|
double precision :: wee_ab_st_av, rdm_ab_st_av
|
||||||
double precision :: wee_tot_st_av, rdm_tot_st_av,spin_trace
|
double precision :: wee_tot_st_av, rdm_tot_st_av,spin_trace
|
||||||
double precision :: wee_aa_st_av_2,wee_ab_st_av_2,wee_bb_st_av_2,wee_tot_st_av_2,wee_tot_st_av_3
|
double precision :: wee_aa_st_av_2,wee_ab_st_av_2,wee_bb_st_av_2,wee_tot_st_av_2,wee_tot_st_av_3
|
||||||
|
double precision :: accu_aa, accu_bb, accu_ab, accu_tot
|
||||||
|
|
||||||
wee_ab = 0.d0
|
wee_ab = 0.d0
|
||||||
wee_bb = 0.d0
|
wee_bb = 0.d0
|
||||||
@ -64,14 +65,23 @@ subroutine routine_active_only
|
|||||||
do istate = 1, N_states
|
do istate = 1, N_states
|
||||||
!! PURE ACTIVE PART
|
!! PURE ACTIVE PART
|
||||||
!!
|
!!
|
||||||
|
accu_aa = 0.d0
|
||||||
|
accu_bb = 0.d0
|
||||||
|
accu_ab = 0.d0
|
||||||
|
accu_tot = 0.d0
|
||||||
do i = 1, n_act_orb
|
do i = 1, n_act_orb
|
||||||
iorb = list_act(i)
|
iorb = list_act(i)
|
||||||
do j = 1, n_act_orb
|
do j = 1, n_act_orb
|
||||||
jorb = list_act(j)
|
jorb = list_act(j)
|
||||||
|
accu_bb += act_2_rdm_bb_mo(j,i,j,i,1)
|
||||||
|
accu_aa += act_2_rdm_aa_mo(j,i,j,i,1)
|
||||||
|
accu_ab += act_2_rdm_ab_mo(j,i,j,i,1)
|
||||||
|
accu_tot += act_2_rdm_spin_trace_mo(j,i,j,i,1)
|
||||||
do k = 1, n_act_orb
|
do k = 1, n_act_orb
|
||||||
korb = list_act(k)
|
korb = list_act(k)
|
||||||
do l = 1, n_act_orb
|
do l = 1, n_act_orb
|
||||||
lorb = list_act(l)
|
lorb = list_act(l)
|
||||||
|
! 1 2 1 2 2 1 2 1
|
||||||
if(dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(j,i,l,k,istate)).gt.1.d-10)then
|
if(dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(j,i,l,k,istate)).gt.1.d-10)then
|
||||||
print*,'Error in act_2_rdm_spin_trace_mo'
|
print*,'Error in act_2_rdm_spin_trace_mo'
|
||||||
print*,"dabs(act_2_rdm_spin_trace_mo(i,j,k,l) - act_2_rdm_spin_trace_mo(j,i,l,k)).gt.1.d-10"
|
print*,"dabs(act_2_rdm_spin_trace_mo(i,j,k,l) - act_2_rdm_spin_trace_mo(j,i,l,k)).gt.1.d-10"
|
||||||
@ -79,6 +89,7 @@ subroutine routine_active_only
|
|||||||
print*,act_2_rdm_spin_trace_mo(i,j,k,l,istate),act_2_rdm_spin_trace_mo(j,i,l,k,istate),dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(j,i,l,k,istate))
|
print*,act_2_rdm_spin_trace_mo(i,j,k,l,istate),act_2_rdm_spin_trace_mo(j,i,l,k,istate),dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(j,i,l,k,istate))
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
! 1 2 1 2 1 2 1 2
|
||||||
if(dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(k,l,i,j,istate)).gt.1.d-10)then
|
if(dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(k,l,i,j,istate)).gt.1.d-10)then
|
||||||
print*,'Error in act_2_rdm_spin_trace_mo'
|
print*,'Error in act_2_rdm_spin_trace_mo'
|
||||||
print*,"dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(k,l,i,j,istate),istate).gt.1.d-10"
|
print*,"dabs(act_2_rdm_spin_trace_mo(i,j,k,l,istate) - act_2_rdm_spin_trace_mo(k,l,i,j,istate),istate).gt.1.d-10"
|
||||||
@ -131,6 +142,15 @@ subroutine routine_active_only
|
|||||||
print*,'wee_tot = ',wee_tot(istate)
|
print*,'wee_tot = ',wee_tot(istate)
|
||||||
print*,'Full energy '
|
print*,'Full energy '
|
||||||
print*,'psi_energy_two_e(istate)= ',psi_energy_two_e(istate)
|
print*,'psi_energy_two_e(istate)= ',psi_energy_two_e(istate)
|
||||||
|
print*,'--------------------------'
|
||||||
|
print*,'accu_aa = ',accu_aa
|
||||||
|
print*,'N_a (N_a-1)/2 = ', elec_alpha_num*(elec_alpha_num-1)*0.5
|
||||||
|
print*,'accu_bb = ',accu_bb
|
||||||
|
print*,'N_b (N_b-1)/2 = ', elec_beta_num*(elec_beta_num-1)*0.5
|
||||||
|
print*,'accu_ab = ',accu_ab
|
||||||
|
print*,'N_a N_b = ', elec_beta_num*elec_alpha_num
|
||||||
|
print*,'accu_tot = ',accu_tot
|
||||||
|
print*,'Ne(Ne-1)/2 = ',(elec_num-1)*elec_num * 0.5
|
||||||
enddo
|
enddo
|
||||||
wee_aa_st_av = 0.d0
|
wee_aa_st_av = 0.d0
|
||||||
wee_bb_st_av = 0.d0
|
wee_bb_st_av = 0.d0
|
||||||
|
Loading…
Reference in New Issue
Block a user