I’m using the LAMMPS to simulate the compression of granular materials. A 2D model (only 9 balls) was considered in my test run. Compressive loads were applied via the fix volume/rescale command. I found that different results were given using different versions of LAMMPS (the most recent version and the 20 Oct 06 one). It seems that the old version gave the right answers. The problem (arised in the new version) may come from the last several lines in Comm::communicate() routine:
n = avec->pack_comm(sendnum[iswap],sendlist[iswap],
in which, the variable pbc_dist(iswap]), which relates to domain->prd, is only updated in the Comm::setup() in the first step of a whole run and does not change even if the simulation box changes. However, the old version codes use the domain-prd directly in the avec->pack_comm(…) subroutine, which can trace the box change due to fix volume/rescale operation.
I’m not sure that this problem is a bug or not. Has anybody else come across this or have an explanation?