10
0
mirror of https://github.com/LCPQ/quantum_package synced 2024-12-22 20:35:19 +01:00

experimental - reversed past and futur

This commit is contained in:
Yann Garniron 2016-07-21 15:28:22 +02:00
parent 418190168e
commit 03958d15a4
3 changed files with 20 additions and 2 deletions

View File

@ -128,7 +128,7 @@ subroutine ZMQ_selection(N, pt2)
integer :: i
integer, external :: omp_get_thread_num
double precision, intent(out) :: pt2(N_states)
call flip_generators()
call new_parallel_job(zmq_to_qp_run_socket,'selection')
call create_selection_buffer(N, N*2, b)
@ -149,6 +149,7 @@ subroutine ZMQ_selection(N, pt2)
endif
!$OMP END PARALLEL
call end_parallel_job(zmq_to_qp_run_socket, 'selection')
call flip_generators()
call fill_H_apply_buffer_no_selection(b%cur,b%det,N_int,0) !!! PAS DE ROBIN
call copy_H_apply_buffer_to_wf()
end subroutine

View File

@ -28,7 +28,6 @@ subroutine selection_slave(thread,iproc)
buf%N = 0
ctask = 1
pt2 = 0d0
do
call get_task_from_taskserver(zmq_to_qp_run_socket,worker_id, task_id(ctask), task)
done = task_id(ctask) == 0

View File

@ -330,6 +330,24 @@ END_PROVIDER
END_PROVIDER
subroutine flip_generators()
integer :: i,j,k
integer(bit_kind) :: detmp(N_int,2)
double precision :: tmp(N_states)
do i=1,N_det_generators/2
detmp(:,:) = psi_det_sorted(:,:,i)
tmp = psi_coef_sorted(i, :)
psi_det_sorted(:,:,i) = psi_det_sorted(:,:,N_det_generators+1-i)
psi_coef_sorted(i, :) = psi_coef_sorted(N_det_generators+1-i, :)
psi_det_sorted(:,:,N_det_generators+1-i) = detmp(:,:)
psi_coef_sorted(N_det_generators+1-i, :) = tmp
end do
TOUCH psi_det_sorted psi_coef_sorted psi_average_norm_contrib_sorted
end subroutine
BEGIN_PROVIDER [ integer(bit_kind), psi_det_sorted_bit, (N_int,2,psi_det_size) ]
&BEGIN_PROVIDER [ double precision, psi_coef_sorted_bit, (psi_det_size,N_states) ]
implicit none