Question about reverse_comm_fix

Dear all,

I have some questions about comm->reverse_comm_fix, especially the one in comm_brick.cpp. My understanding of the function is that this function is used to send information stored in the ghost atoms back to the process owning the same id atom as local atom. If my understanding is correct, I think the number stored in sendlist[iswap], which is an argument for unpack_reverse_comm, should always be smaller than atom->nlocal. However, when I printed out the numbers, I found some of them are larger than nlocal. Is my understanding wrong? Thank you!

Dear all,

I have some questions about comm->reverse_comm_fix, especially the one in
comm_brick.cpp. My understanding of the function is that this function is
used to send information stored in the ghost atoms back to the process
owning the same id atom as local atom. If my understanding is correct, I
think the number stored in sendlist[iswap], which is an argument for
unpack_reverse_comm, should always be smaller than atom->nlocal. However,
when I printed out the numbers, I found some of them are larger than nlocal.
Is my understanding wrong? Thank you!

please note that "atom->nlocal" is usually different on different MPI ranks.

axel.

All ghost atoms have local IDs >= than nlocal, and

that’s what you are sending in a reverse_comm.

At intermediate stages of the comm, the values are summed

to existing ghost atoms (which are then sent to owned atoms

in subsequent stages).

Steve