diff --git a/src/FCI/FCI.irp.f b/src/FCI/FCI.irp.f index 1142e857..1a08adfe 100644 --- a/src/FCI/FCI.irp.f +++ b/src/FCI/FCI.irp.f @@ -17,7 +17,7 @@ program fci_zmq pt2 = -huge(1.e0) norm = 0.d0 - variance = huge(1.e0) + variance = 0.d0 threshold_davidson_in = threshold_davidson threshold_davidson = threshold_davidson_in * 100.d0 SOFT_TOUCH threshold_davidson @@ -131,6 +131,8 @@ program fci_zmq if (do_pt2) then pt2 = 0.d0 + variance = 0.d0 + norm = 0.d0 threshold_selectors = 1.d0 threshold_generators = 1d0 SOFT_TOUCH threshold_selectors threshold_generators diff --git a/src/FCI/pt2_stoch_routines.irp.f b/src/FCI/pt2_stoch_routines.irp.f index f2491b8a..03b3e175 100644 --- a/src/FCI/pt2_stoch_routines.irp.f +++ b/src/FCI/pt2_stoch_routines.irp.f @@ -373,7 +373,7 @@ subroutine pt2_collector(zmq_socket_pull, E, relative_error, pt2, error, varianc do_exit = .true. endif pt2(pt2_stoch_istate) = avg - variance(pt2_stoch_istate) = avg2 !- avg*avg + variance(pt2_stoch_istate) = avg2 norm(pt2_stoch_istate) = avg3 ! 1/(N-1.5) : see Brugger, The American Statistician (23) 4 p. 32 (1969) if(c > 2) then diff --git a/src/FCI/zmq_selection.irp.f b/src/FCI/zmq_selection.irp.f index 8f494ba6..2a06564d 100644 --- a/src/FCI/zmq_selection.irp.f +++ b/src/FCI/zmq_selection.irp.f @@ -179,10 +179,12 @@ subroutine selection_collector(zmq_socket_pull, b, N, pt2, variance, norm) call create_selection_buffer(N, N*2, b2) allocate(task_id(N_det_generators)) more = 1 - pt2(:) = 0d0 - pt2_mwen(:) = 0.d0 - variance_mwen = 0.d0 - norm_mwen = 0.d0 + pt2(:) = 0d0 + variance(:) = 0.d0 + norm(:) = 0.d0 + pt2_mwen(:) = 0.d0 + variance_mwen(:) = 0.d0 + norm_mwen(:) = 0.d0 do while (more == 1) call pull_selection_results(zmq_socket_pull, pt2_mwen, variance_mwen, norm_mwen, b2%val(1), b2%det(1,1,1), b2%cur, task_id, ntask)