Now I am trying to use MPI_Sendand MPI_Recv to pass best found solutions among several processes. The best solutions found in each process are supposed to pass to the control process what stores all best solutions and send to other processes when required. My question is how to implement it? For example, once process 1 find a new best, it can call MPI_Send and send it to the control process. Is there a way for the control process to detect there is message to receive? Does each MPI_Send require a MPI_Recv? Looking forward to hearing advice from you experts. Thanks!
Thanks for your advice. What I am thinking to do is to let several working processes send messages to one control process. The working processes decide when to send. The control process has to detect when to receive. Can MPI_Proble do this?