2016-10-04 10:05:15 +02:00
|
|
|
program davidson_slave
|
|
|
|
use f77_zmq
|
|
|
|
implicit none
|
|
|
|
|
|
|
|
|
|
|
|
integer(ZMQ_PTR), external :: new_zmq_to_qp_run_socket
|
|
|
|
integer(ZMQ_PTR) :: zmq_to_qp_run_socket
|
|
|
|
double precision :: energy(N_states_diag)
|
|
|
|
character*(64) :: state
|
|
|
|
|
2016-10-06 16:39:34 +02:00
|
|
|
call provide_everything
|
2016-10-04 10:05:15 +02:00
|
|
|
call switch_qp_run_to_master
|
|
|
|
|
|
|
|
zmq_context = f77_zmq_ctx_new ()
|
|
|
|
zmq_state = 'davidson'
|
|
|
|
state = 'Waiting'
|
|
|
|
|
|
|
|
zmq_to_qp_run_socket = new_zmq_to_qp_run_socket()
|
|
|
|
do
|
|
|
|
call wait_for_state(zmq_state,state)
|
|
|
|
if(trim(state) /= "davidson") exit
|
|
|
|
integer :: rc, i
|
|
|
|
print *, 'Davidson slave running'
|
2016-10-10 14:48:49 +02:00
|
|
|
call davidson_slave_tcp(i)
|
2016-10-04 10:05:15 +02:00
|
|
|
end do
|
|
|
|
end
|
|
|
|
|
2016-10-06 16:39:34 +02:00
|
|
|
subroutine provide_everything
|
|
|
|
PROVIDE mo_bielec_integrals_in_map psi_det_sorted_bit N_states_diag zmq_context
|
|
|
|
end subroutine
|
2016-10-08 00:39:55 +02:00
|
|
|
|