9
1
mirror of https://github.com/QuantumPackage/qp2.git synced 2024-12-21 11:03:29 +01:00

Changed banned

This commit is contained in:
Anthony Scemama 2021-01-24 23:09:37 +01:00
parent 6553b53d1d
commit 7fa1637b91
3 changed files with 7 additions and 4 deletions

View File

@ -428,7 +428,7 @@ subroutine H_S2_u_0_nstates_zmq(v_0,s_0,u_0,N_st,sze)
integer :: istep, imin, imax, ishift, ipos integer :: istep, imin, imax, ishift, ipos
integer, external :: add_task_to_taskserver integer, external :: add_task_to_taskserver
integer, parameter :: tasksize=10000 integer, parameter :: tasksize=20000
character*(100000) :: task character*(100000) :: task
istep=1 istep=1
ishift=0 ishift=0

View File

@ -270,16 +270,19 @@ compute_singles=.True.
! Check if u has multiple zeros ! Check if u has multiple zeros
kk=1 ! Avoid division by zero kk=1 ! Avoid division by zero
!$OMP DO
do k=1,N_det do k=1,N_det
umax = 0.d0 umax = 0.d0
do l=1,N_st do l=1,N_st
umax = max(umax, dabs(u_t(l,k))) umax = max(umax, dabs(u_t(l,k)))
enddo enddo
if (umax < 1.d-20) then if (umax < 1.d-20) then
!$OMP ATOMIC
kk = kk+1 kk = kk+1
endif endif
enddo enddo
u_is_sparse = N_det / kk < 10 !$OMP END DO
u_is_sparse = N_det / kk < 20 ! 5%
ASSERT (iend <= N_det) ASSERT (iend <= N_det)
ASSERT (istart > 0) ASSERT (istart > 0)

View File

@ -308,10 +308,10 @@ end
call map_get(mo_integrals_map,idx,tmp) call map_get(mo_integrals_map,idx,tmp)
banned_excitation(i,j) = dabs(tmp) < 1.d-14 banned_excitation(i,j) = dabs(tmp) < 1.d-14
banned_excitation(j,i) = banned_excitation(i,j) banned_excitation(j,i) = banned_excitation(i,j)
if (banned_excitation(i,j)) icount = icount+1 if (banned_excitation(i,j)) icount = icount+2
enddo enddo
enddo enddo
use_banned_excitation = (mo_num*mo_num) / icount <= 10 use_banned_excitation = (mo_num*mo_num) / icount <= 100 !1%
if (use_banned_excitation) then if (use_banned_excitation) then
print *, 'Using sparsity of exchange integrals' print *, 'Using sparsity of exchange integrals'
endif endif