diff --git a/plugins/MRCC_Utils/mrcc_dress.irp.f b/plugins/MRCC_Utils/mrcc_dress.irp.f index 59b20c5a..3a4717ed 100644 --- a/plugins/MRCC_Utils/mrcc_dress.irp.f +++ b/plugins/MRCC_Utils/mrcc_dress.irp.f @@ -58,109 +58,9 @@ subroutine create_minilist(key_mask, fullList, miniList, idx_miniList, N_fullLis idx_miniList(N_miniList) = i end if end do - -! if(N_miniList > 2) then -! call sort_detList(miniList, idx_miniList, N_miniList, Nint) -! end if -! -! shortcut(0) = 1 -! shortcut(1) = 1 -! do i=2,N_miniList -! do ni=1,nint -! if(miniList(ni,1,i) /= miniList(ni,1,i-1)) then -! shortcut(0) = shortcut(0) + 1 -! shortcut(shortcut(0)) = i -! exit -! end if -! end do -! end do - !print *, N_miniList_tot , " vers ", dik end subroutine -subroutine det_inf(res, key1, key2, Nint) - use bitmasks - implicit none - integer(bit_kind),intent(in) :: key1(Nint, 2), key2(Nint, 2) - integer,intent(in) :: Nint - integer :: i,j - logical,intent(out) :: res - - res = .false. - - do i=1,2 - do j=Nint,1,-1 - if(key1(j,i) < key2(j,i)) then - res = .true. - return - else if(key1(j,i) > key2(j,i)) then - return - end if - end do - end do -end function - - -subroutine tamiser(key, idx, no, n, Nint, N_key) - use bitmasks - - implicit none - integer(bit_kind),intent(inout) :: key(Nint, 2, N_key) - integer,intent(in) :: no, n, Nint, N_key - integer,intent(inout) :: idx(N_key) - integer :: k,j,tmpidx - integer(bit_kind) :: tmp(Nint, 2) - logical :: inf - - k = no - j = 2*k - do while(j <= n) - call det_inf(inf, key(:,:,j), key(:,:,j+1), Nint) - if(j < n .and. inf) then - j = j+1 - end if - call det_inf(inf, key(:,:,k), key(:,:,j), Nint) - if(inf) then - tmp(:,:) = key(:,:,k) - key(:,:,k) = key(:,:,j) - key(:,:,j) = tmp(:,:) - tmpidx = idx(k) - idx(k) = idx(j) - idx(j) = tmpidx - k = j - j = 2*k - else - return - end if - end do -end subroutine - - -subroutine sort_detList(key, idx, N_key, Nint) - use bitmasks - implicit none - - integer(bit_kind),intent(inout) :: key(Nint,2,N_key) - integer,intent(inout) :: idx(N_key) - integer, intent(in) :: Nint, N_key - integer(bit_kind) :: tmp(Nint, 2) - integer :: tmpidx,i - - do i=N_key/2,1,-1 - !call tamiser(key, idx, i, N_key, Nint, N_key) - end do - - do i=N_key,2,-1 - tmp(:,:) = key(:,:,i) - key(:,:,i) = key(:,:,1) - key(:,:,1) = tmp(:,:) - tmpidx = idx(i) - idx(i) = idx(1) - idx(1) = tmpidx - !call tamiser(key, idx, 1, i-1, Nint, N_key) - end do -end subroutine - subroutine mrcc_dress(delta_ij_, delta_ii_, Ndet_ref, Ndet_non_ref,i_generator,n_selected,det_buffer,Nint,iproc,key_mask) use bitmasks implicit none